类 FieldInfo
java.lang.Object
com.baidu.bjf.remoting.protobuf.utils.FieldInfo
combined class of
Field and @Protobuf annotation value.- 从以下版本开始:
- 1.0.7
- 作者:
- xiemalin
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明get the description.getField()get the field.get the fieldType.Class<?>get the genericeValueType.Class<?>get the genericKeyType.intgetOrder()get the order.Gets the use as type.booleanChecks for description.booleanChecks if is enum key type.booleanChecks if is enum value type.booleanisList()get the isList.static booleanisListType(Field field) Checks if is list type.booleanisMap()get the isMap.booleanChecks if is object type.booleanisPacked()Checks if is packed.static booleanChecks if is primitive type.booleanget the required.static booleanChecks if is set type.booleanChecks if is use type.booleanChecks if is wildcard type.voidsetDescription(String description) set description value to description.voidsetFieldType(FieldType fieldType) set fieldType value to fieldType.voidsetGenericeValueType(Class<?> genericeValueType) set genericeValueType value to genericeValueType.voidsetGenericKeyType(Class<?> genericKeyType) set genericKeyType value to genericKeyType.voidsetList(boolean isList) set isList value to isList.voidsetMap(boolean isMap) set isMap value to isMap.voidsetOrder(int order) set order value to order.voidsetPacked(boolean packed) Sets the packed.voidsetRequired(boolean required) set required value to required.voidsetUseAsType(Class useAsType) Sets the use as type.voidsetUseType(boolean useType) Sets the use type.
-
构造器详细资料
-
FieldInfo
Instantiates a new field info.- 参数:
field- the field
-
-
方法详细资料
-
setUseAsType
Sets the use as type.- 参数:
useAsType- the new use as type
-
getUseAsType
Gets the use as type.- 返回:
- the use as type
-
setUseType
public void setUseType(boolean useType) Sets the use type.- 参数:
useType- the new use type
-
isUseType
public boolean isUseType()Checks if is use type.- 返回:
- true, if is use type
-
isWildcardType
public boolean isWildcardType()Checks if is wildcard type.- 返回:
- the wildcard type
-
isList
public boolean isList()get the isList.- 返回:
- the isList
-
setList
public void setList(boolean isList) set isList value to isList.- 参数:
isList- the isList to set
-
isMap
public boolean isMap()get the isMap.- 返回:
- the isMap
-
setMap
public void setMap(boolean isMap) set isMap value to isMap.- 参数:
isMap- the isMap to set
-
getField
get the field.- 返回:
- the field
-
isRequired
public boolean isRequired()get the required.- 返回:
- the required
-
setRequired
public void setRequired(boolean required) set required value to required.- 参数:
required- the required to set
-
getOrder
public int getOrder()get the order.- 返回:
- the order
-
setOrder
public void setOrder(int order) set order value to order.- 参数:
order- the order to set
-
getFieldType
get the fieldType.- 返回:
- the fieldType
-
setFieldType
set fieldType value to fieldType.- 参数:
fieldType- the fieldType to set
-
getDescription
get the description.- 返回:
- the description
-
setDescription
set description value to description.- 参数:
description- the description to set
-
hasDescription
public boolean hasDescription()Checks for description.- 返回:
- true, if successful
-
getGenericKeyType
get the genericKeyType.- 返回:
- the genericKeyType
-
setGenericKeyType
set genericKeyType value to genericKeyType.- 参数:
genericKeyType- the genericKeyType to set
-
getGenericeValueType
get the genericeValueType.- 返回:
- the genericeValueType
-
setGenericeValueType
set genericeValueType value to genericeValueType.- 参数:
genericeValueType- the genericeValueType to set
-
isPacked
public boolean isPacked()Checks if is packed.- 返回:
- the packed
-
setPacked
public void setPacked(boolean packed) Sets the packed.- 参数:
packed- the packed to set
-
isObjectType
public boolean isObjectType()Checks if is object type.- 返回:
- true, if is object type
-
isEnumValueType
public boolean isEnumValueType()Checks if is enum value type.- 返回:
- true, if is enum value type
-
isEnumKeyType
public boolean isEnumKeyType()Checks if is enum key type.- 返回:
- true, if is enum key type
-
isPrimitiveType
Checks if is primitive type.- 参数:
c- the c- 返回:
- true, if is primitive type
-
isListType
Checks if is list type.- 参数:
field- the field- 返回:
- true, if is list type
-
isSetType
Checks if is set type.- 参数:
field- the field- 返回:
- true, if is set type
-