Class: IcAgent::Candid::NullClass
Instance Method Summary
collapse
#_build_type_table_impl, #check_type
Methods inherited from BaseType
_build_type_table_impl, #build_type_table, check_type, covariant, decode_value, #display, encode_type, encode_value
Constructor Details
Returns a new instance of NullClass.
178
179
180
|
# File 'lib/ic_agent/candid.rb', line 178
def initialize()
super
end
|
Instance Method Details
#covariant(x) ⇒ Object
182
183
184
|
# File 'lib/ic_agent/candid.rb', line 182
def covariant(x)
x == nil
end
|
#decode_value(b, t) ⇒ Object
194
195
196
197
|
# File 'lib/ic_agent/candid.rb', line 194
def decode_value(b, t)
check_type(t)
return nil
end
|
#encode_type(type_table = nil) ⇒ Object
190
191
192
|
# File 'lib/ic_agent/candid.rb', line 190
def encode_type(type_table = nil)
LEB128.encode_signed(TypeIds::Null).string
end
|
#encode_value(val) ⇒ Object
186
187
188
|
# File 'lib/ic_agent/candid.rb', line 186
def encode_value(val)
''
end
|
#id ⇒ Object
203
204
205
|
# File 'lib/ic_agent/candid.rb', line 203
def id
TypeIds::Null
end
|
#name ⇒ Object
199
200
201
|
# File 'lib/ic_agent/candid.rb', line 199
def name
'null'
end
|