Defines a component in terms of its capabilities, parameters, sub-components, etc. During
component model is immutable. During
time, when the class is being transformed and loaded, the
model is mutable.
|Method from org.apache.tapestry5.model.ComponentModel Detail:|
public Resource getBaseResource()
Returns the resource corresponding to the class file for this component. This is used to find related resources,
such as the component's template and message catalog.
public String getComponentClassName()
The FQCN of the component.
public List<String> getDeclaredParameterNames()
Returns an alphabetically sorted list of the names of all formal parameters defined by this specific class
(parameters inherited from base classes are not identified).
public List<String> getEmbeddedComponentIds()
public EmbeddedComponentModel getEmbeddedComponentModel(String componentId)
Returns an embedded component defined by this component or by a super-class.
public String getFieldPersistenceStrategy(String fieldName)
Returns the persistent strategy associated with the field.
public Set<Class> getHandledRenderPhases()
public Logger getLogger()
Returns object that will be used to log warnings and errors related to this component.
public String getMeta(String key)
Gets a meta value identified by the given key. If the current model does not provide a value for the key, then
the parent component model (if any) is searched.
public List<String> getMixinClassNames()
Returns a list of the class names of mixins that are part of the component's implementation.
public ParameterModel getParameterModel(String parameterName)
Return a single parameter model by parameter name, or null if the parameter is not defined.
public List<String> getParameterNames()
Returns an alphabetically sorted list of the names of all formal parameters. This includes parameters defined by
a base class.
public ComponentModel getParentModel()
Returns the component model for this component's super-class, if it exists. Remember that only classes in the
correct packages, are considered component classes.
public List<String> getPersistentFieldNames()
Returns a list of the names of all persistent fields (within this class, or any super-class). The names are
public boolean getSupportsInformalParameters()
Returns true if the model indicates that informal parameters, additional parameters beyond the formal parameter
defined for the component, are supported. This is false in most cases, but may be set to true for specific
classes (when the SupportsInformalParameters annotation is present, or inherited from a super-class).
public boolean isMixinAfter()
Relevant for component mixins only. Indicates that the mixin behavior should occur after (not before)
the component. Normally, this flag is set by the presence of the MixinAfter annotation.
public boolean isRootClass()
Returns true if the modeled component is a root class, a component class whose parent class is not a component
class. We may in the future require that components only extend from Object.