projectviewer.persist
Class DirectoryNodeHandler

java.lang.Object
  extended byprojectviewer.persist.NodeHandler
      extended byprojectviewer.persist.DirectoryNodeHandler

public class DirectoryNodeHandler
extends NodeHandler

Handler for directory nodes.

Version:
$Id: DirectoryNodeHandler.java 7059 2006-09-17 20:58:10Z ezust $
Author:
Marcelo Vanzin

Constructor Summary
DirectoryNodeHandler()
           
 
Method Summary
 VPTNode createNode(org.xml.sax.Attributes attrs, VPTProject project)
          Instantiates a VPTNode based on the information given in the attribute list.
 java.lang.Class getNodeClass()
          Returns the class of the nodes that should be delegated to this handler when saving node data to the config file.
 java.lang.String getNodeName()
          Returns the name of the nodes that should be delegated to this handler when loading configuration data.
 boolean hasChildren()
          Returns whether the node(s) handled by this handler are expected to have children or not.
 boolean isChild()
          Returns whether the node is a child of nome other node or not.
 void saveNode(VPTNode node, java.io.Writer out)
          Saves a VPTDirectory node.
 
Methods inherited from class projectviewer.persist.NodeHandler
startElement, startElement, translatePath, writeAttr
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DirectoryNodeHandler

public DirectoryNodeHandler()
Method Detail

getNodeName

public java.lang.String getNodeName()
Returns the name of the nodes that should be delegated to this handler when loading configuration data.

Specified by:
getNodeName in class NodeHandler

getNodeClass

public java.lang.Class getNodeClass()
Returns the class of the nodes that should be delegated to this handler when saving node data to the config file.

Specified by:
getNodeClass in class NodeHandler

isChild

public boolean isChild()
Returns whether the node is a child of nome other node or not.

Specified by:
isChild in class NodeHandler

hasChildren

public boolean hasChildren()
Returns whether the node(s) handled by this handler are expected to have children or not.

Specified by:
hasChildren in class NodeHandler

createNode

public VPTNode createNode(org.xml.sax.Attributes attrs,
                          VPTProject project)
Instantiates a VPTNode based on the information given in the attribute list.

Specified by:
createNode in class NodeHandler
Parameters:
attrs - The attributes read from the config file.
project - The project that holds this node.

saveNode

public void saveNode(VPTNode node,
                     java.io.Writer out)
              throws java.io.IOException
Saves a VPTDirectory node.

Specified by:
saveNode in class NodeHandler
Throws:
java.io.IOException