public enum FieldType extends Enum<FieldType>
Enumeration identifying all relevant type information for a protobuf field.
Static Fields | |
---|---|
Name | Description |
BOOL | |
BOOL_LIST | |
BOOL_LIST_PACKED | |
BYTES | |
BYTES_LIST | |
DOUBLE | |
DOUBLE_LIST | |
DOUBLE_LIST_PACKED | |
ENUM | |
ENUM_LIST | |
ENUM_LIST_PACKED | |
FIXED32 | |
FIXED32_LIST | |
FIXED32_LIST_PACKED | |
FIXED64 | |
FIXED64_LIST | |
FIXED64_LIST_PACKED | |
FLOAT | |
FLOAT_LIST | |
FLOAT_LIST_PACKED | |
GROUP | |
GROUP_LIST | |
INT32 | |
INT32_LIST | |
INT32_LIST_PACKED | |
INT64 | |
INT64_LIST | |
INT64_LIST_PACKED | |
MAP | |
MESSAGE | |
MESSAGE_LIST | |
SFIXED32 | |
SFIXED32_LIST | |
SFIXED32_LIST_PACKED | |
SFIXED64 | |
SFIXED64_LIST | |
SFIXED64_LIST_PACKED | |
SINT32 | |
SINT32_LIST | |
SINT32_LIST_PACKED | |
SINT64 | |
SINT64_LIST | |
SINT64_LIST_PACKED | |
STRING | |
STRING_LIST | |
UINT32 | |
UINT32_LIST | |
UINT32_LIST_PACKED | |
UINT64 | |
UINT64_LIST | |
UINT64_LIST_PACKED |
Static Methods | |
---|---|
Name | Description |
forId(int id) | Looks up the appropriate FieldType by it's identifier. |
valueOf(String name) | |
values() |
Methods | |
---|---|
Name | Description |
getJavaType() | Gets the JavaType for this field. For lists, this identifies the type of the elements contained within the list. |
id() | A reliable unique identifier for this type. |
isList() | Indicates whether this field represents a list of values. |
isMap() | Indicates whether this field represents a map. |
isPacked() | Indicates whether a list field should be represented on the wire in packed form. |
isPrimitiveScalar() | Indicates whether this field type represents a primitive scalar value. If this is |
isScalar() | Indicates whether this field type represents a scalar value. |
isValidForField(Field field) | Indicates whether or not this FieldType can be applied to the given Field. |