|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.alveole.studio.web.data.NodeContainer
public abstract class NodeContainer
This class is the base class of this project's tree nodes.
Each node inherits of this NodeContainer. Do not use this
class directly. Use one of NodePackage
,
NodeAction
or NodeView
instead.
Field Summary | |
---|---|
protected java.lang.String |
ID
A unique ID for this node. |
protected java.lang.String |
label
A label to display this node. |
protected NodePackage |
parent
The parent node package, or null if root. |
protected Project |
project
The containing project. |
protected java.util.Properties |
uiPreferences
User interface preferences (stores node X and Y position). |
Constructor Summary | |
---|---|
NodeContainer(Project project,
NodePackage parent)
Construtor. |
Method Summary | ||
---|---|---|
abstract
|
getAdapter(java.lang.Class<T> cls)
Gets a adapter interface for this node. |
|
java.lang.String |
getID()
A unique identifier. |
|
java.lang.String |
getLabel()
Gets a label for displaying this node. |
|
NodePackage |
getParent()
Gets parent package. |
|
Project |
getProject()
|
|
java.util.Properties |
getUiPreferences()
Get UI prerences. |
|
abstract void |
serialize(org.w3c.dom.Element parent)
Serialize this node to DOM document. |
|
protected void |
serializeUiPrefs(org.w3c.dom.Element thisElement)
Helper method for serializing all preferences for UI. |
|
void |
setID(java.lang.String id)
A unique identifier. |
|
void |
setLabel(java.lang.String name)
Sets a label for displaying this node. |
|
void |
setParent(NodePackage parent)
Set parent package. |
|
void |
setProject(Project project)
|
|
void |
setUiPreferences(java.util.Properties uiPreferences)
Set UI preferences. |
|
abstract void |
unserialize(org.w3c.dom.Element element)
Unserialize this node from DOM element. |
|
protected void |
unserializeUiPrefs(org.w3c.dom.Element thisElement)
Helper method to read UI peferences from DOM element. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.lang.String ID
protected java.lang.String label
protected NodePackage parent
protected Project project
protected java.util.Properties uiPreferences
Constructor Detail |
---|
public NodeContainer(Project project, NodePackage parent)
project
- The project.parent
- The parent package.Method Detail |
---|
public java.lang.String getID()
public void setID(java.lang.String id)
id
- The unique ID for this node.public java.lang.String getLabel()
public void setLabel(java.lang.String name)
name
- The label.public abstract void serialize(org.w3c.dom.Element parent)
parent
- The parent node, in which to store this node.public abstract void unserialize(org.w3c.dom.Element element) throws javax.xml.xpath.XPathException
element
- The DOM element in which data for this node is stored.
javax.xml.xpath.XPathException
- If XPath error.protected void serializeUiPrefs(org.w3c.dom.Element thisElement)
thisElement
- The DOM element create to store this node.protected void unserializeUiPrefs(org.w3c.dom.Element thisElement) throws javax.xml.xpath.XPathException
thisElement
- The element that stores this node.
javax.xml.xpath.XPathException
- In case of error.public NodePackage getParent()
public void setParent(NodePackage parent)
parent
- The parent package.public java.util.Properties getUiPreferences()
public void setUiPreferences(java.util.Properties uiPreferences)
uiPreferences
- The new prefs.public abstract <T> T getAdapter(java.lang.Class<T> cls)
cls
- The target class.
public Project getProject()
public void setProject(Project project)
project
- the project to set
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |