class ProtobufDescriptor::EnumValueDescriptor
Describes an enum type.
See {EnumValueDescriptorProto
}
Attributes
enum_value_descriptor_proto[R]
The EnumValueDescriptorProto
this EnumValueDescriptor
is wrapping.
parent[R]
The containing {ProtobufDescriptor::EnumDescriptor} that this is a value for.
Public Class Methods
new(parent, enum_value_descriptor_proto)
click to toggle source
# File lib/protobuf_descriptor/enum_value_descriptor.rb, line 15 def initialize(parent, enum_value_descriptor_proto) @parent = parent @enum_value_descriptor_proto = enum_value_descriptor_proto end
Public Instance Methods
name()
click to toggle source
The name of the enum value
# File lib/protobuf_descriptor/enum_value_descriptor.rb, line 21 def name; enum_value_descriptor_proto.name; end
number()
click to toggle source
The number mapped to the enum value
# File lib/protobuf_descriptor/enum_value_descriptor.rb, line 24 def number; enum_value_descriptor_proto.number; end
options()
click to toggle source
The EnumValueOptions
defined for this enum
# File lib/protobuf_descriptor/enum_value_descriptor.rb, line 27 def options; enum_value_descriptor_proto.options; end