Enum Class Type
- 所有已实现的接口:
EnumReadable,Serializable,Comparable<Type>,java.lang.constant.Constable
Enumeration type defines at
DescriptorProtos.FieldDescriptorProto.- 从以下版本开始:
- 2.0.1
- 作者:
- xiemalin
-
嵌套类概要
从类继承的嵌套类/接口 java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
枚举常量概要
枚举常量枚举常量说明TYPE_BOOL = 8;.TYPE_BYTES = 12;TYPE_DOUBLE = 1;TYPE_ENUM = 14;.TYPE_FIXED32 = 7;.TYPE_FIXED64 = 6;.TYPE_FLOAT = 2;.TYPE_GROUP = 10;TYPE_INT32 = 5;TYPE_INT64 = 3;TYPE_MESSAGE = 11;TYPE_SFIXED32 = 15;.TYPE_SFIXED64 = 16;.TYPE_SINT32 = 17;TYPE_SINT64 = 18;TYPE_STRING = 9;.TYPE_UINT32 = 13;.TYPE_UINT64 = 4;. -
方法概要
-
枚举常量详细资料
-
TYPE_DOUBLE
TYPE_DOUBLE = 1;0 is reserved for errors. Order is weird for historical reasons.
-
TYPE_FLOAT
TYPE_FLOAT = 2;. -
TYPE_INT64
TYPE_INT64 = 3;Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if negative values are likely.
-
TYPE_UINT64
TYPE_UINT64 = 4;. -
TYPE_INT32
TYPE_INT32 = 5;Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if negative values are likely.
-
TYPE_FIXED64
TYPE_FIXED64 = 6;. -
TYPE_FIXED32
TYPE_FIXED32 = 7;. -
TYPE_BOOL
TYPE_BOOL = 8;. -
TYPE_STRING
TYPE_STRING = 9;. -
TYPE_GROUP
TYPE_GROUP = 10;Tag-delimited aggregate.
-
TYPE_MESSAGE
TYPE_MESSAGE = 11;Length-delimited aggregate.
-
TYPE_BYTES
TYPE_BYTES = 12;New in version 2.
-
TYPE_UINT32
TYPE_UINT32 = 13;. -
TYPE_ENUM
TYPE_ENUM = 14;. -
TYPE_SFIXED32
TYPE_SFIXED32 = 15;. -
TYPE_SFIXED64
TYPE_SFIXED64 = 16;. -
TYPE_SINT32
TYPE_SINT32 = 17;Uses ZigZag encoding.
-
TYPE_SINT64
TYPE_SINT64 = 18;Uses ZigZag encoding.
-
-
方法详细资料
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- 返回:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- 参数:
name- 要返回的枚举常量的名称。- 返回:
- 返回带有指定名称的枚举常量
- 抛出:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- 如果参数为空值
-
value
public int value()- 指定者:
value在接口中EnumReadable- 返回:
- the value of Enum element
-
valueOf
Value of.- 参数:
value- the value- 返回:
- the type
-