A collection to simplify retrieving the field accessor for a particular field.
Properties |
|
---|---|
this[int number]
|
Retrieves the descriptor for the field with the given number.
|
this[string name]
|
Retrieves the descriptor for the field with the given name.
|
Public functions |
|
---|---|
InDeclarationOrder()
|
IList< FieldDescriptor >
Returns the fields in the message as an immutable list, in the order in which they are declared in the source .proto file.
|
InFieldNumberOrder()
|
IList< FieldDescriptor >
Returns the fields in the message as an immutable list, in ascending field number order.
|
FieldDescriptor this[int number]
Retrieves the descriptor for the field with the given number.
Details | |||
---|---|---|---|
Parameters |
|
||
Exceptions |
|
||
Returns |
The accessor for the given field
|
FieldDescriptor this[string name]
Retrieves the descriptor for the field with the given name.
Details | |||
---|---|---|---|
Parameters |
|
||
Exceptions |
|
||
Returns |
The descriptor for the given field
|
IList< FieldDescriptor > InDeclarationOrder()
Returns the fields in the message as an immutable list, in the order in which they are declared in the source .proto file.
IList< FieldDescriptor > InFieldNumberOrder()
Returns the fields in the message as an immutable list, in ascending field number order.
Field numbers need not be contiguous, so there is no direct mapping from the index in the list to the field number; to retrieve a field by field number, it is better to use the FieldCollection indexer.