类 Property
- 所有已实现的接口:
Serializable,AnnotatedElement,Member
java.beans.PropertyDescriptor. The java.beans package
is not available in a number of environments (e.g. Android, Java ME), so this is
desirable for portability of core conversion facility.
Used to build a TypeDescriptor from a property location. The built
TypeDescriptor can then be used to convert from/to the property type.
- 从以下版本开始:
- 4.0 2022/7/23 01:01
- 作者:
- Harry Yang
- 另请参阅:
-
字段概要
字段修饰符和类型字段说明protected Fieldprotected final Stringprotected final Methodprotected final Methodprotected MethodParameter -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明protected TypeDescriptorprotected ResolvableTypeboolean<T extends Annotation>
TgetAnnotation(Class<T> annotationClass) Class<?>Returns theClassobject representing the class or interface that declares the field represented by thisFieldobject.getField()get or find a FieldIf method based bean-propertyintgetName()original property nameClass<?>getType()Returns aClassobject that identifies the declared type for the field represented by thisFieldobject.final TypeDescriptorReturnsTypeDescriptorfor this propertyinthashCode()booleanisAnnotationPresent(Class<? extends Annotation> annotationClass) booleanisInstance(Object value) Determines if the specifiedObjectis assignment-compatible with the object represented by thisProperty.booleanis primitivebooleancan readbooleanread onlybooleanbooleancan writetoString()从接口继承的方法 java.lang.reflect.AnnotatedElement
getAnnotationsByType, getDeclaredAnnotation, getDeclaredAnnotationsByType
-
字段详细资料
-
field
-
name
-
readMethod
- 从以下版本开始:
- 4.0
-
writeMethod
- 从以下版本开始:
- 4.0
-
writeMethodParameter
-
-
构造器详细资料
-
Property
-
Property
-
Property
-
Property
-
-
方法详细资料
-
getTypeDescriptor
ReturnsTypeDescriptorfor this property- 从以下版本开始:
- 3.0.4
-
createDescriptor
-
getResolvableType
-
createResolvableType
-
isInstance
Determines if the specifiedObjectis assignment-compatible with the object represented by thisProperty. This method is the dynamic equivalent of the Java languageinstanceofoperator. The method returnstrueif the specifiedObjectargument is non-null and can be cast to the reference type represented by thisPropertyobject without raising aClassCastException.It returnsfalseotherwise.Specifically, if this
Propertyobject represents a declared class, this method returnstrueif the specifiedObjectargument is an instance of the represented class (or of any of its subclasses); it returnsfalseotherwise. If thisPropertyobject represents an array class, this method returnstrueif the specifiedObjectargument can be converted to an object of the array class by an identity conversion or by a widening reference conversion; it returnsfalseotherwise. If thisPropertyobject represents an interface, this method returnstrueif the class or any superclass of the specifiedObjectargument implements this interface; it returnsfalseotherwise. If thisPropertyobject represents a primitive type, this method returnsfalse.- 参数:
value- the object to check- 返回:
- true if
objis an instance of this property-type - 另请参阅:
-
getType
Returns aClassobject that identifies the declared type for the field represented by thisFieldobject.- 返回:
- a
Classobject identifying the declared type of the field represented by this object
-
getField
get or find a Field- 返回:
- returns null show that isSynthetic
-
getName
original property name -
getModifiers
public int getModifiers()- 指定者:
getModifiers在接口中Member
-
isSynthetic
public boolean isSynthetic()- 指定者:
isSynthetic在接口中Member
-
isReadOnly
public boolean isReadOnly()read only- 从以下版本开始:
- 3.0.2
-
isWriteable
public boolean isWriteable()can write- 从以下版本开始:
- 4.0
-
isReadable
public boolean isReadable()can read- 从以下版本开始:
- 4.0
-
isPrimitive
public boolean isPrimitive()is primitive -
getDeclaringClass
Returns theClassobject representing the class or interface that declares the field represented by thisFieldobject.- 指定者:
getDeclaringClass在接口中Member- 从以下版本开始:
- 4.0
-
getReadMethod
-
getWriteMethod
-
getWriteMethodParameter
-
getMethodParameter
If method based bean-property -
isAnnotationPresent
- 指定者:
isAnnotationPresent在接口中AnnotatedElement
-
getAnnotation
- 指定者:
getAnnotation在接口中AnnotatedElement
-
getDeclaredAnnotations
- 指定者:
getDeclaredAnnotations在接口中AnnotatedElement
-
getAnnotations
- 指定者:
getAnnotations在接口中AnnotatedElement
-
equals
-
hashCode
public int hashCode() -
toString
-