Modifier and Type | Class and Description |
---|---|
public abstract static class | FieldLocator.AbstractBase
An abstract base implementation of a field locator. |
public static interface | FieldLocator.Factory
A factory for creating a |
public static class | FieldLocator.ForClassHierarchy
A field locator that looks up fields that are declared within a class's class hierarchy. |
public static class | FieldLocator.ForExactType
A field locator that only looks up fields that are declared by a specific type. |
public static class | FieldLocator.ForTopLevelType
A field locator that only locates fields in the top-level type. |
public static enum | FieldLocator.NoOp
A field locator that never discovers a field. |
public static interface | FieldLocator.Resolution
A resolution for a field lookup. |
Modifier and Type | Method and Description |
---|---|
public FieldLocator. | |
public FieldLocator. | Returns: A resolution for a field lookup.The name of the field to locate. name, TypeDescription The type fo the field to locate. type)Locates a field with the given name and type and throws an exception if no such type exists. |
locate | back to summary |
---|---|
public FieldLocator. Locates a field with the given name and throws an exception if no such type exists.
|
locate | back to summary |
---|---|
public FieldLocator. Locates a field with the given name and type and throws an exception if no such type exists.
|
Modifier and Type | Field and Description |
---|---|
protected final TypeDescription | accessingType
The type accessing the field. |
Access | Constructor and Description |
---|---|
protected | AbstractBase(TypeDescription
The type accessing the field. accessingType)Creates a new field locator. |
Modifier and Type | Method and Description |
---|---|
public FieldLocator. | locate(String
The name of the field to locate. name)Implements net. |
public FieldLocator. | locate(String
The name of the field to locate. name, TypeDescription The type fo the field to locate. type)Implements net. |
protected abstract FieldList | Returns: A list of fields that match the specified matcher.The matcher that identifies fields of interest. matcher)Locates fields that match the given matcher. |
accessingType | back to summary |
---|---|
protected final TypeDescription accessingType The type accessing the field. |
AbstractBase | back to summary |
---|---|
protected AbstractBase(TypeDescription accessingType) Creates a new field locator.
|
locate | back to summary |
---|---|
public FieldLocator. Implements net. Doc from net. Locates a field with the given name and throws an exception if no such type exists.
|
locate | back to summary |
---|---|
public FieldLocator. Implements net. Doc from net. Locates a field with the given name and type and throws an exception if no such type exists.
|
locate | back to summary |
---|---|
protected abstract FieldList Locates fields that match the given matcher.
|
FieldLocator
.
Modifier and Type | Method and Description |
---|---|
public FieldLocator | Returns: A suitable field locator.The type for which to create a field locator. typeDescription)Creates a field locator for a given type. |
make | back to summary |
---|---|
public FieldLocator make(TypeDescription typeDescription) Creates a field locator for a given type.
|
Modifier and Type | Class and Description |
---|---|
public static enum | FieldLocator.ForClassHierarchy.Factory
A factory for creating a |
Modifier and Type | Field and Description |
---|---|
private final TypeDescription | typeDescription
The type for which to look up a field within its class hierarchy. |
Access | Constructor and Description |
---|---|
public | ForClassHierarchy(TypeDescription
The type for which to look up a field within its class hierarchy which is also the accessing type. typeDescription)Creates a field locator that looks up fields that are declared within a class's class hierarchy. |
public | ForClassHierarchy(TypeDescription
The type for which to look up a field within its class hierarchy. typeDescription, TypeDescription The accessing type. accessingType)Creates a field locator that looks up fields that are declared within a class's class hierarchy. |
Modifier and Type | Method and Description |
---|---|
protected FieldList | locate(ElementMatcher<? super FieldDescription>
The matcher that identifies fields of interest. matcher)Implements abstract net. |
typeDescription | back to summary |
---|---|
private final TypeDescription typeDescription The type for which to look up a field within its class hierarchy. |
ForClassHierarchy | back to summary |
---|---|
public ForClassHierarchy(TypeDescription typeDescription) Creates a field locator that looks up fields that are declared within a class's class hierarchy.
|
ForClassHierarchy | back to summary |
---|---|
public ForClassHierarchy(TypeDescription typeDescription, TypeDescription accessingType) Creates a field locator that looks up fields that are declared within a class's class hierarchy.
|
locate | back to summary |
---|---|
protected FieldList Implements abstract net. Doc from net. Locates fields that match the given matcher.
|
ForClassHierarchy
.
Modifier and Type | Field and Description |
---|---|
public static final FieldLocator. | INSTANCE
The singleton instance. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public FieldLocator | make(TypeDescription
The type for which to create a field locator. typeDescription)Implements net. |
public static FieldLocator. | |
public static FieldLocator. |
INSTANCE | back to summary |
---|---|
public static final FieldLocator. The singleton instance. |
Factory | back to summary |
---|---|
private Factory() |
make | back to summary |
---|---|
public FieldLocator make(TypeDescription typeDescription) Implements net. Doc from net. Creates a field locator for a given type.
|
valueOf | back to summary |
---|---|
public static FieldLocator. |
values | back to summary |
---|---|
public static FieldLocator. |
Modifier and Type | Class and Description |
---|---|
public static class | FieldLocator.ForExactType.Factory
A factory for creating a |
Modifier and Type | Field and Description |
---|---|
private final TypeDescription | typeDescription
The type for which to look up fields. |
Access | Constructor and Description |
---|---|
public | ForExactType(TypeDescription
The type for which to look up fields that is also providing the accessing type. typeDescription)Creates a new field locator for locating fields from a declared type. |
public | ForExactType(TypeDescription
The type for which to look up fields. typeDescription, TypeDescription The accessing type. accessingType)Creates a new field locator for locating fields from a declared type. |
Modifier and Type | Method and Description |
---|---|
protected FieldList | locate(ElementMatcher<? super FieldDescription>
The matcher that identifies fields of interest. matcher)Implements abstract net. |
typeDescription | back to summary |
---|---|
private final TypeDescription typeDescription The type for which to look up fields. |
ForExactType | back to summary |
---|---|
public ForExactType(TypeDescription typeDescription) Creates a new field locator for locating fields from a declared type.
|
ForExactType | back to summary |
---|---|
public ForExactType(TypeDescription typeDescription, TypeDescription accessingType) Creates a new field locator for locating fields from a declared type.
|
locate | back to summary |
---|---|
protected FieldList Implements abstract net. Doc from net. Locates fields that match the given matcher.
|
ForExactType
.
Modifier and Type | Field and Description |
---|---|
private final TypeDescription | typeDescription
The type for which to locate a field. |
Access | Constructor and Description |
---|---|
public | Factory(TypeDescription
The type for which to locate a field. typeDescription)Creates a new factory for a field locator that locates a field for an exact type. |
Modifier and Type | Method and Description |
---|---|
public FieldLocator | make(TypeDescription
The type for which to create a field locator. typeDescription)Implements net. |
typeDescription | back to summary |
---|---|
private final TypeDescription typeDescription The type for which to locate a field. |
Factory | back to summary |
---|---|
public Factory(TypeDescription typeDescription) Creates a new factory for a field locator that locates a field for an exact type.
|
make | back to summary |
---|---|
public FieldLocator make(TypeDescription typeDescription) Implements net. Doc from net. Creates a field locator for a given type.
|
Modifier and Type | Class and Description |
---|---|
public static enum | FieldLocator.ForTopLevelType.Factory
A factory for locating a field in a top-level type. |
Access | Constructor and Description |
---|---|
protected | ForTopLevelType(TypeDescription
The type to access. typeDescription)Creates a new type locator for a top-level type. |
Modifier and Type | Method and Description |
---|---|
protected FieldList | locate(ElementMatcher<? super FieldDescription>
The matcher that identifies fields of interest. matcher)Implements abstract net. |
ForTopLevelType | back to summary |
---|---|
protected ForTopLevelType(TypeDescription typeDescription) Creates a new type locator for a top-level type.
|
locate | back to summary |
---|---|
protected FieldList Implements abstract net. Doc from net. Locates fields that match the given matcher.
|
Modifier and Type | Field and Description |
---|---|
public static final FieldLocator. | INSTANCE
The singleton instance. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public FieldLocator | make(TypeDescription
The type for which to create a field locator. typeDescription)Implements net. |
public static FieldLocator. | |
public static FieldLocator. |
INSTANCE | back to summary |
---|---|
public static final FieldLocator. The singleton instance. |
Factory | back to summary |
---|---|
private Factory() |
make | back to summary |
---|---|
public FieldLocator make(TypeDescription typeDescription) Implements net. Doc from net. Creates a field locator for a given type.
|
valueOf | back to summary |
---|---|
public static FieldLocator. |
values | back to summary |
---|---|
public static FieldLocator. |
Modifier and Type | Field and Description |
---|---|
public static final FieldLocator. | INSTANCE
The singleton instance. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public FieldLocator. | locate(String
The name of the field to locate. name)Implements net. |
public FieldLocator. | locate(String
The name of the field to locate. name, TypeDescription The type fo the field to locate. type)Implements net. |
public FieldLocator | make(TypeDescription
The type for which to create a field locator. typeDescription)Implements net. |
public static FieldLocator. | |
public static FieldLocator. |
INSTANCE | back to summary |
---|---|
public static final FieldLocator. The singleton instance. |
NoOp | back to summary |
---|---|
private NoOp() |
locate | back to summary |
---|---|
public FieldLocator. Implements net. Doc from net. Locates a field with the given name and throws an exception if no such type exists.
|
locate | back to summary |
---|---|
public FieldLocator. Implements net. Doc from net. Locates a field with the given name and type and throws an exception if no such type exists.
|
make | back to summary |
---|---|
public FieldLocator make(TypeDescription typeDescription) Implements net. Doc from net. Creates a field locator for a given type.
|
valueOf | back to summary |
---|---|
public static FieldLocator. |
values | back to summary |
---|---|
public static FieldLocator. |
Modifier and Type | Class and Description |
---|---|
public static enum | FieldLocator.Resolution.Illegal
An illegal resolution. |
public static class | FieldLocator.Resolution.Simple
A simple implementation for a field resolution. |
Modifier and Type | Method and Description |
---|---|
public FieldDescription | |
public boolean |
getField | back to summary |
---|---|
public FieldDescription getField() Returns the field description if a field was located. This method must only be called if this resolution was actually resolved.
|
isResolved | back to summary |
---|---|
public boolean isResolved() Returns
|
Modifier and Type | Field and Description |
---|---|
public static final FieldLocator. | INSTANCE
The singleton instance. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public FieldDescription | getField()
Implements net. |
public boolean | isResolved()
Implements net. true if a field was located.
|
public static FieldLocator. | |
public static FieldLocator. |
INSTANCE | back to summary |
---|---|
public static final FieldLocator. The singleton instance. |
Illegal | back to summary |
---|---|
private Illegal() |
getField | back to summary |
---|---|
public FieldDescription getField() Implements net. Doc from net. Returns the field description if a field was located. This method must only be called if this resolution was actually resolved.
|
isResolved | back to summary |
---|---|
public boolean isResolved() Implements net. Doc from net. Returns
|
valueOf | back to summary |
---|---|
public static FieldLocator. |
values | back to summary |
---|---|
public static FieldLocator. |
Modifier and Type | Field and Description |
---|---|
private final FieldDescription | fieldDescription
A description of the located field. |
Access | Constructor and Description |
---|---|
protected | Simple(FieldDescription
A description of the located field. fieldDescription)Creates a new simple resolution for a field. |
Modifier and Type | Method and Description |
---|---|
public FieldDescription | getField()
Implements net. |
public boolean | isResolved()
Implements net. true if a field was located.
|
public static FieldLocator. | Returns: A resolution for a field locator.The field locator to use. fieldLocator, MethodDescription The method description that is the potential accessor. methodDescription)Resolves a field locator for a potential accessor method. |
fieldDescription | back to summary |
---|---|
private final FieldDescription fieldDescription A description of the located field. |
Simple | back to summary |
---|---|
protected Simple(FieldDescription fieldDescription) Creates a new simple resolution for a field.
|
getField | back to summary |
---|---|
public FieldDescription getField() Implements net. Doc from net. Returns the field description if a field was located. This method must only be called if this resolution was actually resolved.
|
isResolved | back to summary |
---|---|
public boolean isResolved() Implements net. Doc from net. Returns
|
ofBeanAccessor | back to summary |
---|---|
public static FieldLocator. Resolves a field locator for a potential accessor method. If the provided method is not a bean accessor, an illegal resolution is returned.
|