org.apache.tapestry.spec
Class ExtensionSpecification
java.lang.Object
org.apache.tapestry.util.BasePropertyHolder
org.apache.tapestry.spec.LocatablePropertyHolder
org.apache.tapestry.spec.ExtensionSpecification
- All Implemented Interfaces:
- IExtensionSpecification, IPropertyHolder, org.apache.hivemind.Locatable, org.apache.hivemind.LocationHolder
- public class ExtensionSpecification
- extends LocatablePropertyHolder
- implements IExtensionSpecification
Defines an "extension", which is much like a helper bean, but is part of a library or application
specification (and has the same lifecycle as the application).
- Since:
- 2.2
- Author:
- Howard Lewis Ship
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.apache.hivemind.LocationHolder |
setLocation |
Methods inherited from interface org.apache.hivemind.Locatable |
getLocation |
_configuration
protected java.util.Map _configuration
ExtensionSpecification
public ExtensionSpecification(org.apache.hivemind.ClassResolver resolver,
ValueConverter valueConverter)
- Since:
- 4.0
getClassName
public java.lang.String getClassName()
- Specified by:
getClassName
in interface IExtensionSpecification
setClassName
public void setClassName(java.lang.String className)
- Specified by:
setClassName
in interface IExtensionSpecification
addConfiguration
public void addConfiguration(java.lang.String propertyName,
java.lang.String value)
- Specified by:
addConfiguration
in interface IExtensionSpecification
getConfiguration
public java.util.Map getConfiguration()
- Returns an immutable Map of the configuration; keyed on property name, with values as
properties to assign.
- Specified by:
getConfiguration
in interface IExtensionSpecification
instantiateExtension
public java.lang.Object instantiateExtension()
- Invoked to instantiate an instance of the extension and return it. It also configures
properties of the extension.
- Specified by:
instantiateExtension
in interface IExtensionSpecification
toString
public java.lang.String toString()
isImmediate
public boolean isImmediate()
- Returns true if the extensions should be instantiated immediately after the containing
LibrarySpecification
if parsed. Non-immediate extensions are
instantiated only as needed.
- Specified by:
isImmediate
in interface IExtensionSpecification
setImmediate
public void setImmediate(boolean immediate)
- Specified by:
setImmediate
in interface IExtensionSpecification