public enum FieldType extends Enum<FieldType>
| 枚举常量和说明 |
|---|
BOOL
The bool.
|
BYTES
The bytes.
|
DEFAULT
The default.
|
DOUBLE
types defined in .proto file.
|
ENUM
The enum.
|
FIXED32
The FIXE d32.
|
FIXED64
The FIXE d64.
|
FLOAT
The float.
|
INT32
The IN t32.
|
INT64
The IN t64.
|
OBJECT
The object.
|
SFIXED32
The SFIXE d32.
|
SFIXED64
The SFIXE d64.
|
SINT32
The SIN t32.
|
SINT64
The SIN t64.
|
STRING
The string.
|
UINT32
The UIN t32.
|
UINT64
The UIN t64.
|
| 限定符和类型 | 方法和说明 |
|---|---|
String |
getDefaultValue()
Gets the default value.
|
com.google.protobuf.WireFormat.FieldType |
getInternalFieldType()
Gets the internal field type.
|
String |
getJavaType()
Gets the java original type.
|
String |
getSuffix()
Gets the suffix.
|
String |
getToPrimitiveType()
Gets the to primitive type.
|
String |
getType()
Gets the protobuf type.
|
String |
getWireFormat()
Gets the protobuf wire format type.
|
boolean |
isPrimitive()
Checks if is primitive.
|
void |
setDefaultValue(String defaultValue)
Sets the default value.
|
void |
setInternalFieldType(com.google.protobuf.WireFormat.FieldType internalFieldType)
Sets the internal field type.
|
static FieldType |
valueOf(String name)
返回带有指定名称的该类型的枚举常量。
|
static FieldType[] |
values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
public static final FieldType DOUBLE
public static final FieldType FLOAT
public static final FieldType INT64
public static final FieldType UINT64
public static final FieldType INT32
public static final FieldType FIXED64
public static final FieldType FIXED32
public static final FieldType BOOL
public static final FieldType STRING
public static final FieldType BYTES
public static final FieldType UINT32
public static final FieldType SFIXED32
public static final FieldType SFIXED64
public static final FieldType SINT32
public static final FieldType SINT64
public static final FieldType OBJECT
public static final FieldType ENUM
public static final FieldType DEFAULT
public static FieldType[] values()
for (FieldType c : FieldType.values()) System.out.println(c);
public static FieldType valueOf(String name)
name - 要返回的枚举常量的名称。IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量NullPointerException - 如果参数为空值public String getSuffix()
public String getDefaultValue()
public void setDefaultValue(String defaultValue)
defaultValue - the new default valuepublic com.google.protobuf.WireFormat.FieldType getInternalFieldType()
public void setInternalFieldType(com.google.protobuf.WireFormat.FieldType internalFieldType)
internalFieldType - the new internal field typepublic String getToPrimitiveType()
public String getWireFormat()
public String getType()
public String getJavaType()
public boolean isPrimitive()
Copyright © 2019 Baidu, Inc.. All rights reserved.