yext.graphml.graph2D
Class ReadNodeRealizerHandler

java.lang.Object
  extended byyext.graphml.reader.AbstractDOMInputHandler
      extended byyext.graphml.graph2D.ReadNodeRealizerHandler
All Implemented Interfaces:
DOMInputHandler

public class ReadNodeRealizerHandler
extends AbstractDOMInputHandler

Reads the y-graphics extension for nodes in GraphML input.


Constructor Summary
ReadNodeRealizerHandler()
           
 
Method Summary
 boolean acceptKey(NamedNodeMap attributes, int scopeType)
          This method defines whether a specific key/data pair is handled by the input handler.
static void addNodeRealizerSerializer(NodeRealizerSerializer nrs)
          Deprecated. Use RealizerSerializerManager instead for instance specific registration.
protected  void applyDefault(DOMGraphMLParseContext context, Graph graph, Object nodeedge)
          Apply default data.
protected  void parseData(DOMGraphMLParseContext context, Graph graph, Object node, boolean defaultMode, Node domNode)
          Parses the data.
static NodeRealizer parseRealizer(Node node, GraphMLParseContext context)
           
 
Methods inherited from class yext.graphml.reader.AbstractDOMInputHandler
applyDefault, parseData
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReadNodeRealizerHandler

public ReadNodeRealizerHandler()
Method Detail

addNodeRealizerSerializer

public static void addNodeRealizerSerializer(NodeRealizerSerializer nrs)
Deprecated. Use RealizerSerializerManager instead for instance specific registration.

Register an NodeRealizerSerializer for input. Instances registered with this method will be used as fallback if no better serializer can be found in the current parse context.

Parameters:
nrs -

acceptKey

public boolean acceptKey(NamedNodeMap attributes,
                         int scopeType)
Description copied from interface: DOMInputHandler
This method defines whether a specific key/data pair is handled by the input handler. When it returns true, each occurence of data elements which match the id of the key element are forwarded to the input handler.

Parameters:
attributes - the attributes of the key tag.
scopeType - the scope for which the key is defined. One of GraphMLConstants.SCOPE_ALL, GraphMLConstants.SCOPE_EDGE, GraphMLConstants.SCOPE_ENDPOINT, GraphMLConstants.SCOPE_GRAPH, GraphMLConstants.SCOPE_NODE, GraphMLConstants.SCOPE_PORT, GraphMLConstants.SCOPE_HYPEREDGE.

parseData

protected void parseData(DOMGraphMLParseContext context,
                         Graph graph,
                         Object node,
                         boolean defaultMode,
                         Node domNode)
Description copied from class: AbstractDOMInputHandler
Parses the data.

Specified by:
parseData in class AbstractDOMInputHandler
Parameters:
context - The context in which the parser is.
graph - The current graph in the parse context.
node - The current node/edge in the parse context.
defaultMode - Whether default data or real data is read.
domNode - The DOM node which is actually processed.

parseRealizer

public static NodeRealizer parseRealizer(Node node,
                                         GraphMLParseContext context)

applyDefault

protected void applyDefault(DOMGraphMLParseContext context,
                            Graph graph,
                            Object nodeedge)
Description copied from class: AbstractDOMInputHandler
Apply default data.

Specified by:
applyDefault in class AbstractDOMInputHandler
Parameters:
context - The context in which the parser is.
graph - The current graph in the parse context.
nodeedge - The current node/edge in the parse context.


Copyright ©2000-2008, yWorks GmbH. All rights reserved.