Class: MessagePack::IDL::IR::EnumValue

Inherits:
Value
  • Object
show all
Defined in:
lib/msgpack/idl/ir.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(enum, field) ⇒ EnumValue

Returns a new instance of EnumValue.



240
241
242
243
# File 'lib/msgpack/idl/ir.rb', line 240

def initialize(enum, field)
	@enum = enum
	@field = field
end

Instance Attribute Details

#enumObject (readonly)

Returns the value of attribute enum.



244
245
246
# File 'lib/msgpack/idl/ir.rb', line 244

def enum
  @enum
end

#fieldObject (readonly)

Returns the value of attribute field.



244
245
246
# File 'lib/msgpack/idl/ir.rb', line 244

def field
  @field
end

Instance Method Details

#==(o) ⇒ Object



246
247
248
249
# File 'lib/msgpack/idl/ir.rb', line 246

def ==(o)
	# TODO
	o.class == EnumValue && @enum.name == o.enum.name && @field.id == o.field.id
end