Class: Quark::MdkRuntime::FakeEnvVars

Inherits:
DatawireQuarkCore::QuarkObject show all
Extended by:
DatawireQuarkCore::Static
Defined in:
lib/mdk_runtime.rb

Overview

Testing fake for EnvironmentVariables.

Constant Summary

Constants included from DatawireQuarkCore::Static

DatawireQuarkCore::Static::Unassigned

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from DatawireQuarkCore::Static

_lazy_statics, static, unlazy_statics

Methods inherited from DatawireQuarkCore::QuarkObject

#to_s

Constructor Details

#initializeFakeEnvVars

Returns a new instance of FakeEnvVars.



2148
2149
2150
2151
2152
# File 'lib/mdk_runtime.rb', line 2148

def initialize()
    self.__init_fields__

    nil
end

Instance Attribute Details

#envObject

Returns the value of attribute env.



2141
2142
2143
# File 'lib/mdk_runtime.rb', line 2141

def env
  @env
end

Instance Method Details

#__init_fields__Object



2201
2202
2203
2204
2205
2206
# File 'lib/mdk_runtime.rb', line 2201

def __init_fields__()
    
    self.env = {}

    nil
end

#_getClassObject



2175
2176
2177
2178
2179
2180
# File 'lib/mdk_runtime.rb', line 2175

def _getClass()
    
    return "mdk_runtime.FakeEnvVars"

    nil
end

#_getField(name) ⇒ Object



2182
2183
2184
2185
2186
2187
2188
2189
2190
# File 'lib/mdk_runtime.rb', line 2182

def _getField(name)
    
    if ((name) == ("env"))
        return (self).env
    end
    return nil

    nil
end

#_setField(name, value) ⇒ Object



2192
2193
2194
2195
2196
2197
2198
2199
# File 'lib/mdk_runtime.rb', line 2192

def _setField(name, value)
    
    if ((name) == ("env"))
        (self).env = ::DatawireQuarkCore.cast(value) { ::Hash }
    end

    nil
end

#set(name, value) ⇒ Object



2157
2158
2159
2160
2161
2162
# File 'lib/mdk_runtime.rb', line 2157

def set(name, value)
    
    ((self).env)[name] = (value)

    nil
end

#var(name) ⇒ Object



2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
# File 'lib/mdk_runtime.rb', line 2164

def var(name)
    
    value = ::DatawireQuarkCore.cast(nil) { ::String }
    if (((self).env).key?(name))
        value = ((self).env)[name]
    end
    return ::Quark.mdk_runtime.EnvironmentVariable.new(name, value)

    nil
end