public abstract class BasePropertyStyle extends BaseTraitStyle<Property> implements PropertyStyle
mLog| Modifier | Constructor and Description |
|---|---|
protected |
BasePropertyStyle(BaseTraitStyleConfig config) |
| Modifier and Type | Method and Description |
|---|---|
Map<String,Property> |
getProperties(String type)
Gets the Properties for the given type.
|
protected Map<String,Property> |
getUncachedTraits(String type) |
protected abstract Map<String,Property> |
inspectProperties(String type) |
ValueAndDeclaredType |
traverse(Object toTraverse,
String type,
boolean onlyToParent,
String... names)
Traverses the given Object heirarchy using properties of the given names.
|
cacheTraits, clearCache, getCachedTraits, getTraits, isExcluded, isExcludedBaseType, isExcludedName, isExcludedReturnTypeprotected BasePropertyStyle(BaseTraitStyleConfig config)
public Map<String,Property> getProperties(String type)
PropertyStyle
Properties must be returned using a consistent ordering, so that both unit tests and
CompositeInspector merging is consistent. If the underlying technology does not
define an ordering, one must be imposed (eg. sorted alphabetically by name), even though this
may later be overridden by other mechanisms (eg.
ComesAfterInspectionResultProcessor sorts by comes-after).
getProperties in interface PropertyStylepublic ValueAndDeclaredType traverse(Object toTraverse, String type, boolean onlyToParent, String... names)
Note: traversal involves calling Property.read, which invokes getter methods and can therefore have side effects. For example, a JSF controller 'ResourceController' may have a method 'getLoggedIn' which has to check the HttpSession, maybe even hit some EJBs or access the database.
traverse in interface PropertyStyleprotected final Map<String,Property> getUncachedTraits(String type)
getUncachedTraits in class BaseTraitStyle<Property>Copyright © 2015. All Rights Reserved.