Factory used by class MultiPageLayout to create special nodes and edges.
Inheritance Hierarchy
IElementFactory
Type Details
- yfiles module
- layout-multipage
- yfiles-umd modules
- layout-multipage, layout
- Legacy UMD name
- yfiles.multipage.IElementFactory
Methods
createConnectorEdge
(context: LayoutContext, connector: YNode, opposite: YNode, origEdgeId: Object, atTarget: boolean) : EdgeCallback method for creating an edge of type CONNECTOR.
Remarks
Such an edge connects the given connector and opposite node.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- connector - YNode
- the endpoint of the edge that represents the connector node
- opposite - YNode
- the other endpoint of the edge
- origEdgeId - Object
- the ID of the edge that is split by the connector edge
- atTarget - boolean
true
if the connector node is the target of the edge,false
otherwise
Returns
- ↪Edge
- the created connector edge
See Also
All implementations have to use method createEdge to create the edge.
Callback method for creating a node of type CONNECTOR.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- edgesIds - YList
- a list that contains the IDs of edges that are split by this connector
- representedNodeId - Object
- the ID of the node that is represented by this connector
Returns
- ↪YNode
- the created connector node
See Also
Multi-edges (edges connecting the same node pair) may be split by the same connector pair, see edgeBundleModeMask. Hence, the list of
edgeIds
may contain several entries.All implementations have to use method createNode to create the node.
createProxyEdge
(context: LayoutContext, proxyNode: YNode, opposite: YNode, replacingEdgeId: Object, origNodeId: Object) : EdgeCallback method for creating an edge of type PROXY.
Remarks
Such an edge should connect the given proxy and opposite node.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- proxyNode - YNode
- the endpoint of the edge that represents the proxy node
- opposite - YNode
- the other endpoint of the new edge
- replacingEdgeId - Object
- the ID of the related edge that is connected to the original node
- origNodeId - Object
- the ID of the original node to which the proxy node refers
Returns
- ↪Edge
- the created proxy edge
See Also
All implementations have to use method createEdge to create the edge.
Callback method for creating a node of type PROXY.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- origNodeId - Object
- the ID of the node for which a proxy has to be created
Returns
- ↪YNode
- the created proxy node
See Also
All implementations have to use method createNode to create the node.
createProxyReferenceEdge
(context: LayoutContext, proxyReference: YNode, opposite: YNode, referencingCopyId: Object) : EdgeCallback method for creating an edge of type PROXY_REFERENCE.
Remarks
Such an (undirected) edge should connect the given proxy reference and opposite node.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- proxyReference - YNode
- the endpoint of the edge that represents the proxy reference node
- opposite - YNode
- the other endpoint of the new edge
- referencingCopyId - Object
- the ID of the proxy node that is referenced by the proxy reference node
Returns
- ↪Edge
- the created proxy reference edge
See Also
All implementations have to use method createEdge to create the edge.
Callback method for creating a node of type PROXY_REFERENCE.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- context - LayoutContext
- an object providing relevant layout information, for example, the current graph as well as various information about the graph elements
- referringProxyId - Object
- the ID of the proxy to which the created node refers
Returns
- ↪YNode
- the new proxy reference node
See Also
All implementations have to use method createNode to create the node.