org.apache.struts.tiles.xmlDefinition
Class XmlDefinition
- Serializable
public class XmlDefinition
A definition read from an XML definitions file.
private String | inherit - Extends attribute value.
|
private boolean | isVisited - Used for resolving inheritance.
|
protected static Log | log - Commons Logging instance.
|
ACTION , CONTROLLER , URL , attributes , controller , controllerInstance , controllerType , log , name , path , role |
createController , createControllerFromClassname , getAttribute , getAttributes , getController , getControllerInstance , getControllerType , getName , getOrCreateController , getPage , getPath , getRole , getTemplate , put , put , put , put , putAttribute , setController , setControllerClass , setControllerInstance , setControllerType , setControllerUrl , setName , setPage , setPath , setRole , setTemplate , toString |
inherit
private String inherit
Extends attribute value.
isVisited
private boolean isVisited
Used for resolving inheritance.
log
protected static Log log
Commons Logging instance.
XmlDefinition
public XmlDefinition()
Constructor.
addAttribute
public void addAttribute(XmlAttribute attribute)
Add an attribute to this component.
attribute
- Attribute to add.
getExtends
public String getExtends()
Get extends.
- Name of the extended definition.
isExtending
public boolean isExtending()
Get extends flag.
overload
public void overload(XmlDefinition child)
Overload this definition with passed child.
All attributes from child are copied to this definition. Previous attributes with
same name are disguarded.
Special attribute 'path','role' and 'extends' are overloaded if defined in child.
child
- Child used to overload this definition.
resolveInheritance
public void resolveInheritance(XmlDefinitionsSet definitionsSet)
throws NoSuchDefinitionException
Resolve inheritance.
First, resolve parent's inheritance, then set path to the parent's path.
Also copy attributes setted in parent, and not set in child
If instance doesn't extend anything, do nothing.
setExtends
public void setExtends(String name)
Set extends.
name
- Name of the extended definition.
setIsVisited
public void setIsVisited(boolean isVisited)
Set isVisited.
Copyright B) 2000-2007 - The Apache Software Foundation