This class describes a channel, i.e., a set of vertical or horizontal edge segments whose locations depend on each other.
Remarks
Type Details
- yfiles module
- router-polyline
- yfiles-umd modules
- layout-area, layout-multipage, layout-orthogonal-compact, layout, router-bus, router-polyline
- Legacy UMD name
- yfiles.router.Channel
Constructors
Creates a new Channel that contains the given segment info.
Parameters
A map of options to pass to the method.
- segment - SegmentInfo
- the given segment info for which the Channel is created
Throws
- Exception({ name: 'ArgumentError' })
- if the given segment has a different orientation than the other segments already contained in the channel
Properties
Gets the bounds of this channel.
Remarks
See Also
Gets an interval spanning the union of the maximum extension of the segment infos.
See Also
Gets whether or not the segments in this channel are vertical.
Gets an interval spanning the union of the location ranges of the segment infos.
See Also
Methods
Adds a new segment info to the channel.
Parameters
A map of options to pass to the method.
- segment - SegmentInfo
- the segment info to be added to this channel
Throws
- Exception({ name: 'ArgumentError' })
- if the given segment has a different orientation than the other segments already contained in the channel
Adds a segment group to this channel.
Parameters
A map of options to pass to the method.
- group - SegmentGroup
- the segment group to be added
Returns the current location that the given segment info has been assigned within its location range.
Parameters
A map of options to pass to the method.
- segmentInfo - SegmentInfo
- the segment info for which the current location will be returned
Returns
- ↪number
- the current location of the segment info or Number.NaN if no location has been assigned before
See Also
Returns the segment info with the given index in the list of segments of this channel.
Parameters
A map of options to pass to the method.
- index - number
- the index of the segment in the list of segments
Returns
- ↪SegmentInfo
- the segment info with the given index in the list of segments
Returns the segment group with the given index in this channel.
Parameters
A map of options to pass to the method.
- index - number
- the index of the segment group
Returns
- ↪SegmentGroup
- the segment group with the given index in this channel
Returns the number of segment infos in this channel.
Returns
- ↪number
- the number of segment infos in this channel
Returns the number of segment groups in this channel.
Returns
- ↪number
- the number of segment groups in this channel
Specifies the current location that the given segment info has been assigned within its location range.
Remarks
Parameters
A map of options to pass to the method.
- segmentInfo - SegmentInfo
- the segment info for which the current location will be set
- location - number
- the location of the segment info within its location range