|
Search this API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object y.io.graphml.input.DefaultGraphElementFactory
public class DefaultGraphElementFactory
The basic implementation of the GraphElementFactory
interface for use with the default Graph
s.
This uses the CreationProperties
from the
GraphMLParseContext
to create the items with the correct
initial values if they have been put into the creation properties
by InputHandler
implementations that have been
invoked before the creation of the items.
Constructor Summary | |
---|---|
DefaultGraphElementFactory()
|
Method Summary | |
---|---|
Edge |
createEdge(GraphMLParseContext context,
Node sourceNode,
Port sourcePort,
Node targetNode,
Port targetPort)
Creates an edge for the given context and the provided source and target nodes or ports. |
Node |
createNode(GraphMLParseContext context)
Creates a node for the given context. |
Port |
createPort(GraphMLParseContext context,
Node owner)
Creates a port object that is owned by owner |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultGraphElementFactory()
Method Detail |
---|
public Node createNode(GraphMLParseContext context)
GraphElementFactory
createNode
in interface GraphElementFactory
context
- The context from which the graph, the CreationProperties
, and the GraphMLParseContext.getObjectStack()
can be queried.
public Edge createEdge(GraphMLParseContext context, Node sourceNode, Port sourcePort, Node targetNode, Port targetPort)
GraphElementFactory
createEdge
in interface GraphElementFactory
context
- The context from which the graph, the CreationProperties
, and the GraphMLParseContext.getObjectStack()
can be queried.sourceNode
- The source node for the edge.sourcePort
- The source port for the edge, if specified, otherwise null
.targetNode
- The target node for the edge.targetPort
- The target port for the edge, if specified, otherwise null
.
public Port createPort(GraphMLParseContext context, Node owner)
GraphElementFactory
owner
createPort
in interface GraphElementFactory
context
- The context from which the graph, the CreationProperties
, and the GraphMLParseContext.getObjectStack()
can be queried.owner
- The owner of the port object
|
© Copyright 2000-2022, yWorks GmbH. All rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |