Packagecom.yworks.graph.model
Classpublic class CurrentEdgePortsCandidateProvider
ImplementsIEdgePortCandidateProvider
SubclassesDefaultEdgePortsCandidateProvider

An implementation of the IEdgePortCandidateProvider interface that returns the current source and target ports



Protected Properties
 PropertyDefined by
  edge : IEdge
[read-only] The edge to return candidates for.
CurrentEdgePortsCandidateProvider
Public Methods
 MethodDefined by
  
Creates a new instance.
CurrentEdgePortsCandidateProvider
  
Returns all source port candidates that may be used for the edge.
CurrentEdgePortsCandidateProvider
  
Returns all target port candidates that may be used for the edge.
CurrentEdgePortsCandidateProvider
Protected Methods
 MethodDefined by
  
Creates a candidate from the given existing port instance.
CurrentEdgePortsCandidateProvider
Property detail
edgeproperty
edge:IEdge  [read-only]

The edge to return candidates for.

Implementation
    protected function get edge():IEdge
Constructor detail
CurrentEdgePortsCandidateProvider()constructor
public function CurrentEdgePortsCandidateProvider(edge:IEdge)

Creates a new instance.

Parameters
edge:IEdge — The edge to get the port candidates for.
Method detail
createCandidate()method
protected function createCandidate(graph:IGraph, port:IPort):DefaultPortCandidate

Creates a candidate from the given existing port instance.

Parameters
graph:IGraph — The graph
 
port:IPort — The port to create a candidate for.

Returns
DefaultPortCandidate — A candidate for the given port.
getSourcePortCandidates()method 
public function getSourcePortCandidates(context:IInputModeContext, graph:IGraph):Iterable

Returns all source port candidates that may be used for the edge.

The iterable may both contain valid and invalid port candidates.

Parameters
context:IInputModeContext — The context for which the candidates should be provided.
 
graph:IGraph — The graph for which the candidates should be queried.

Returns
Iterable — An iterable over all source port candidates that are associated with the current context edge.
getTargetPortCandidates()method 
public function getTargetPortCandidates(context:IInputModeContext, graph:IGraph):Iterable

Returns all target port candidates that may be used for the edge.

The iterable may both contain valid and invalid port candidates.

Parameters
context:IInputModeContext — The context for which the candidates should be provided.
 
graph:IGraph — The graph for which the candidates should be queried.

Returns
Iterable — An iterable over all target port candidates that are associated with the current context edge.