harmonic.mz.data
Class SimpleNode

java.lang.Object
  |
  +--harmonic.mz.data.SimpleNode
All Implemented Interfaces:
DataNode

public class SimpleNode
extends java.lang.Object
implements DataNode

This is the minimum implementation of DataNode. Most methods do nothing usefull. This is usually extened and needed methods are overriddin.


Constructor Summary
SimpleNode()
           
 
Method Summary
 void addField(java.lang.String name, DataNode child)
          Adds child
 void addNode(DataNode child)
          Adds child
 void addNodeListener(NodeListener listener)
          Nothing.
 void assignFromXMLAttributes(MVGFileOpener opener, org.xml.sax.Attributes node)
          Nothing.
 void assignToXMLAttributes(MVGFileSaver saver, org.xml.sax.helpers.AttributesImpl node, boolean bUpdate)
          Nothing.
 DataNode at(int index)
          Return data node at index
 boolean canSelect()
          Returns false.
 int childCount()
          Returns child count
 void clearAttrib(java.lang.Object key)
          Nothing.
 org.w3c.dom.Element createXMLElement(org.w3c.dom.Document doc)
          Returns null.
 FileNode fileRoot()
           
 void fromXMLNodes(XMLTransferNode[] nodes)
          Does nothing.
 java.lang.Object getAttrib(java.lang.Object key)
          Returns null.
 java.lang.String getName()
          Returns name
 DataNode[] getNodeChildren()
          Returns children
 DataNode getNodeParent()
          Returns parent
 java.lang.String getRemoteOwner()
          Returns null.
 boolean getSelect()
          Returns selection flag
 int getSerialNo()
          Returns -1
 java.lang.String getTreeName()
          Returns name
 java.awt.Image getTypeImage()
          Returns null
 long getUpdateTime()
          Returns 0.
 XMLTransferNode[] getXMLNodes()
          Returns null.
 boolean isField()
          Returns field flag.
 DataNode linkedTo()
          Returns null.
 void makeReferenced(DataNode linkInput)
           
 void makeUnreferenced()
           
 void notifyListeners(NodeEvent event)
          Nothing.
 void purge()
          Does nothing
 void purgeFinal()
          Clears children and parent reference.
 void removeNode(DataNode child, boolean bUnlink)
          Removes child
 boolean removeNodeListener(NodeListener listener)
          Nothing.
 void set(DataNode other)
          Calls set on children
 void setAttrib(java.lang.Object key, java.lang.Object value)
          Nothing.
 void setIsField(boolean b)
          Implement to set if this node is a field.
 void setName(java.lang.String name)
          Sets name.
 void setNodeParent(DataNode parent)
          Sets parent.
 void setRemoteOwner(java.lang.String owner)
          Nothing.
 void setSelect(boolean b)
          Sets selection flag
 void setSerialNo(int sn)
          Nothing.
 void setUpdateTime(long time)
          Nothing.
 java.lang.String valueString()
          Returns null.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleNode

public SimpleNode()
Method Detail

purge

public void purge()
Does nothing

Specified by:
purge in interface DataNode

purgeFinal

public void purgeFinal()
Clears children and parent reference.

Specified by:
purgeFinal in interface DataNode

set

public void set(DataNode other)
Calls set on children

Specified by:
set in interface DataNode

setNodeParent

public void setNodeParent(DataNode parent)
Sets parent.

Specified by:
setNodeParent in interface DataNode

addNode

public void addNode(DataNode child)
Adds child

Specified by:
addNode in interface DataNode

addField

public void addField(java.lang.String name,
                     DataNode child)
Adds child

Specified by:
addField in interface DataNode

removeNode

public void removeNode(DataNode child,
                       boolean bUnlink)
Removes child

Specified by:
removeNode in interface DataNode

addNodeListener

public void addNodeListener(NodeListener listener)
Nothing.

Specified by:
addNodeListener in interface DataNode

removeNodeListener

public boolean removeNodeListener(NodeListener listener)
Nothing.

Specified by:
removeNodeListener in interface DataNode

notifyListeners

public void notifyListeners(NodeEvent event)
Nothing.

Specified by:
notifyListeners in interface DataNode

fileRoot

public FileNode fileRoot()
Specified by:
fileRoot in interface DataNode

setSerialNo

public void setSerialNo(int sn)
Nothing.

Specified by:
setSerialNo in interface DataNode

setName

public void setName(java.lang.String name)
Sets name.

Specified by:
setName in interface DataNode

setIsField

public void setIsField(boolean b)
Implement to set if this node is a field. Fields cannot come and go.

Specified by:
setIsField in interface DataNode

setAttrib

public void setAttrib(java.lang.Object key,
                      java.lang.Object value)
Nothing.

Specified by:
setAttrib in interface DataNode

setRemoteOwner

public void setRemoteOwner(java.lang.String owner)
Nothing.

Specified by:
setRemoteOwner in interface DataNode

setUpdateTime

public void setUpdateTime(long time)
Nothing.

Specified by:
setUpdateTime in interface DataNode

clearAttrib

public void clearAttrib(java.lang.Object key)
Nothing.

Specified by:
clearAttrib in interface DataNode

setSelect

public void setSelect(boolean b)
Sets selection flag

Specified by:
setSelect in interface DataNode

getSelect

public boolean getSelect()
Returns selection flag

Specified by:
getSelect in interface DataNode

getNodeChildren

public DataNode[] getNodeChildren()
Returns children

Specified by:
getNodeChildren in interface DataNode

getNodeParent

public DataNode getNodeParent()
Returns parent

Specified by:
getNodeParent in interface DataNode

childCount

public int childCount()
Returns child count

Specified by:
childCount in interface DataNode

at

public DataNode at(int index)
Return data node at index

Specified by:
at in interface DataNode

getName

public java.lang.String getName()
Returns name

Specified by:
getName in interface DataNode

getTreeName

public java.lang.String getTreeName()
Returns name

Specified by:
getTreeName in interface DataNode

getTypeImage

public java.awt.Image getTypeImage()
Returns null

Specified by:
getTypeImage in interface DataNode

getSerialNo

public int getSerialNo()
Returns -1

Specified by:
getSerialNo in interface DataNode

isField

public boolean isField()
Returns field flag.

Specified by:
isField in interface DataNode

linkedTo

public DataNode linkedTo()
Returns null.

Specified by:
linkedTo in interface DataNode

makeReferenced

public void makeReferenced(DataNode linkInput)
Specified by:
makeReferenced in interface DataNode

makeUnreferenced

public void makeUnreferenced()
Specified by:
makeUnreferenced in interface DataNode

canSelect

public boolean canSelect()
Returns false.

Specified by:
canSelect in interface DataNode

getRemoteOwner

public java.lang.String getRemoteOwner()
Returns null.

Specified by:
getRemoteOwner in interface DataNode

getUpdateTime

public long getUpdateTime()
Returns 0.

Specified by:
getUpdateTime in interface DataNode

getAttrib

public java.lang.Object getAttrib(java.lang.Object key)
Returns null.

Specified by:
getAttrib in interface DataNode

valueString

public java.lang.String valueString()
Returns null.

Specified by:
valueString in interface DataNode

createXMLElement

public org.w3c.dom.Element createXMLElement(org.w3c.dom.Document doc)
Returns null.

Specified by:
createXMLElement in interface DataNode

assignFromXMLAttributes

public void assignFromXMLAttributes(MVGFileOpener opener,
                                    org.xml.sax.Attributes node)
Nothing.

Specified by:
assignFromXMLAttributes in interface DataNode

assignToXMLAttributes

public void assignToXMLAttributes(MVGFileSaver saver,
                                  org.xml.sax.helpers.AttributesImpl node,
                                  boolean bUpdate)
Nothing.

Specified by:
assignToXMLAttributes in interface DataNode

getXMLNodes

public XMLTransferNode[] getXMLNodes()
Returns null.

Specified by:
getXMLNodes in interface DataNode

fromXMLNodes

public void fromXMLNodes(XMLTransferNode[] nodes)
Does nothing.

Specified by:
fromXMLNodes in interface DataNode