com.alveole.studio.web.data
Class NodeView

java.lang.Object
  extended by com.alveole.studio.web.data.NodeContainer
      extended by com.alveole.studio.web.data.NodeView

public class NodeView
extends NodeContainer

This is a MVC view. This type of node may be a JSP, a static file, or any template...

Author:
sylvain

Field Summary
protected  java.lang.String mgrId
          This ViewManager plugin's ID.
protected  java.lang.Object specificObject
          Specific embedded object for this view.
protected  java.util.Properties specificProperties
          Specific properties for this view.
 
Fields inherited from class com.alveole.studio.web.data.NodeContainer
ID, label, parent, project, uiPreferences
 
Constructor Summary
NodeView(Project project, NodePackage parent)
          Constructor.
 
Method Summary
<T> T
getAdapter(java.lang.Class<T> cls)
          Gets an adapter for this view.
 java.lang.String getMgrId()
          Get plugin ID for ViewManager.
 java.lang.Object getSpecificObject()
          Gets specific object for this View.
 java.util.Properties getSpecificProperties()
          Get this node specific properties.
 void serialize(org.w3c.dom.Element parent)
          Stores this view to XML file.
 void setMgrId(java.lang.String mgrId)
          Set plugin ID for ViewManager.
 void setSpecificObject(java.lang.Object specificObject)
          Set specific object for this view.
 void setSpecificProperties(java.util.Properties specificProperties)
          Set this node specific properties.
 void unserialize(org.w3c.dom.Element element)
          Reads this view from XML.
 
Methods inherited from class com.alveole.studio.web.data.NodeContainer
getID, getLabel, getParent, getProject, getUiPreferences, serializeUiPrefs, setID, setLabel, setParent, setProject, setUiPreferences, unserializeUiPrefs
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mgrId

protected java.lang.String mgrId
This ViewManager plugin's ID.


specificProperties

protected java.util.Properties specificProperties
Specific properties for this view.


specificObject

protected java.lang.Object specificObject
Specific embedded object for this view.

Constructor Detail

NodeView

public NodeView(Project project,
                NodePackage parent)
Constructor.

Parameters:
project - The current project.
parent - The parent package.
Method Detail

serialize

public void serialize(org.w3c.dom.Element parent)
Stores this view to XML file.

Specified by:
serialize in class NodeContainer
Parameters:
parent - The parent XML node.

unserialize

public void unserialize(org.w3c.dom.Element element)
Reads this view from XML.

Specified by:
unserialize in class NodeContainer
Parameters:
element - This XML node.

getMgrId

public java.lang.String getMgrId()
Get plugin ID for ViewManager.

Returns:
The ID.

setMgrId

public void setMgrId(java.lang.String mgrId)
Set plugin ID for ViewManager.

Parameters:
mgrId - The ID.

getSpecificProperties

public java.util.Properties getSpecificProperties()
Get this node specific properties.

Returns:
The properties.

setSpecificProperties

public void setSpecificProperties(java.util.Properties specificProperties)
Set this node specific properties.

Parameters:
specificProperties - The specific properties of this node.

getSpecificObject

public java.lang.Object getSpecificObject()
Gets specific object for this View.

Returns:
the object.

setSpecificObject

public void setSpecificObject(java.lang.Object specificObject)
Set specific object for this view.

Parameters:
specificObject - The object.

getAdapter

public <T> T getAdapter(java.lang.Class<T> cls)
Gets an adapter for this view. This method calls the underlying ViewManager to find a specific implementation of the given class.

Specified by:
getAdapter in class NodeContainer
Parameters:
cls - The target class.
Returns:
The implementation or null.