|
Search this API | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objecty.layout.multipage.DefaultElementFactory
public class DefaultElementFactory
This class is a default implementation of interface ElementFactory.
ElementFactory![]() |
![]() |
| Constructor Summary | |
|---|---|
DefaultElementFactory()
Creates a new instance of DefaultElementFactory. |
|
| Method Summary | |
|---|---|
Edge |
createConnectorEdge(LayoutContext context,
Node connector,
Node opposite,
java.lang.Object origEdgeId,
boolean atTarget)
Callback method for creating an edge of type EdgeInfo.TYPE_CONNECTOR. |
Node |
createConnectorNode(LayoutContext context,
YList edgeIds,
java.lang.Object representedNodeId)
Callback method for creating a node of type NodeInfo.TYPE_CONNECTOR. |
Edge |
createProxyEdge(LayoutContext context,
Node proxyNode,
Node opposite,
java.lang.Object replacingEdgeId,
java.lang.Object origNodeId)
Callback method for creating an edge of type EdgeInfo.TYPE_PROXY. |
Node |
createProxyNode(LayoutContext context,
java.lang.Object origNodeId)
Callback method for creating a node of type NodeInfo.TYPE_PROXY. |
Edge |
createProxyReferenceEdge(LayoutContext context,
Node proxyReference,
Node opposite,
java.lang.Object referencingCopyId)
Callback method for creating an edge of type EdgeInfo.TYPE_PROXY_REFERENCE. |
Node |
createProxyReferenceNode(LayoutContext context,
java.lang.Object referringProxyId)
Callback method for creating a node of type NodeInfo.TYPE_PROXY_REFERENCE. |
protected YDimension |
getDefaultNodeSize(LayoutContext context,
java.lang.Object id,
byte type)
Returns the default size for nodes created by this factory. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultElementFactory()
DefaultElementFactory.
| Method Detail |
|---|
public Edge createConnectorEdge(LayoutContext context,
Node connector,
Node opposite,
java.lang.Object origEdgeId,
boolean atTarget)
ElementFactoryEdgeInfo.TYPE_CONNECTOR.
Such an edge connects the given connector and opposite node.
createConnectorEdge in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsconnector - the endpoint of the edge that represents the connector nodeopposite - the other endpoint of the edgeorigEdgeId - the ID of the edge that is split by the connector edgeatTarget - true if the connector node is the target of the edge, false otherwise
EdgeInfo.TYPE_CONNECTOR,
NodeInfo.TYPE_CONNECTOR,
LayoutContext.createEdge(y.base.Node, y.base.Node, java.lang.Object)
public Node createConnectorNode(LayoutContext context,
YList edgeIds,
java.lang.Object representedNodeId)
ElementFactoryNodeInfo.TYPE_CONNECTOR.
createConnectorNode in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsedgeIds - a list that contains the IDs of edges that are split by this connectorrepresentedNodeId - the ID of the node that is represented by this connector
NodeInfo.TYPE_CONNECTOR,
LayoutContext.createNode(Object),
NodeInfo.getRepresentedNode()
public Node createProxyReferenceNode(LayoutContext context,
java.lang.Object referringProxyId)
ElementFactoryNodeInfo.TYPE_PROXY_REFERENCE.
createProxyReferenceNode in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsreferringProxyId - the ID of the proxy to which the created node refers
NodeInfo.TYPE_PROXY_REFERENCE,
LayoutContext.createNode(Object),
NodeInfo.TYPE_PROXY
public Node createProxyNode(LayoutContext context,
java.lang.Object origNodeId)
ElementFactoryNodeInfo.TYPE_PROXY.
createProxyNode in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsorigNodeId - the ID of the node for which a proxy has to be created
LayoutContext.createNode(Object),
NodeInfo.TYPE_PROXY_REFERENCE,
NodeInfo.TYPE_PROXY
public Edge createProxyReferenceEdge(LayoutContext context,
Node proxyReference,
Node opposite,
java.lang.Object referencingCopyId)
ElementFactoryEdgeInfo.TYPE_PROXY_REFERENCE.
Such an (undirected) edge should connect the given
proxy reference and opposite node.
createProxyReferenceEdge in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsproxyReference - the endpoint of the edge that represents the proxy
reference nodeopposite - the other endpoint of the new edgereferencingCopyId - the ID of the proxy node that is referenced by the
proxy reference node
EdgeInfo.TYPE_PROXY_REFERENCE,
NodeInfo.TYPE_PROXY_REFERENCE,
LayoutContext.createEdge(y.base.Node, y.base.Node, java.lang.Object)
public Edge createProxyEdge(LayoutContext context,
Node proxyNode,
Node opposite,
java.lang.Object replacingEdgeId,
java.lang.Object origNodeId)
ElementFactoryEdgeInfo.TYPE_PROXY.
Such an edge should connect the given proxy and opposite node.
createProxyEdge in interface ElementFactorycontext - an object providing relevant layout information, for example, the current graph as well as
various information about the graph elementsproxyNode - the endpoint of the edge that represents the proxy nodeopposite - the other endpoint of the new edgereplacingEdgeId - the ID of the related edge that is connected to the original nodeorigNodeId - the ID of the original node to which the proxy node refers
EdgeInfo.TYPE_PROXY,
NodeInfo.TYPE_PROXY,
LayoutContext.createEdge(y.base.Node, y.base.Node, java.lang.Object)
protected YDimension getDefaultNodeSize(LayoutContext context,
java.lang.Object id,
byte type)
This method is called from createConnectorNode(LayoutContext, YList, Object),
createProxyReferenceNode(LayoutContext, Object), and/or
createProxyNode(LayoutContext, Object).
It must return a non-null size with positive width and height.
Subclasses may implement this method to use custom size values.
context - an object providing relevant layout information,
for example, the current graph as well as various information about the graph elementsid - the element IDtype - the type of the node to be created
|
© Copyright 2000-2025, yWorks GmbH. All rights reserved. |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||