de.cau.cs.kieler.klay.layered.p4nodes
Class LinearSegmentsNodePlacer.LinearSegment
java.lang.Object
de.cau.cs.kieler.klay.layered.p4nodes.LinearSegmentsNodePlacer.LinearSegment
- All Implemented Interfaces:
- Comparable<LinearSegmentsNodePlacer.LinearSegment>
- Enclosing class:
- LinearSegmentsNodePlacer
public static class LinearSegmentsNodePlacer.LinearSegment
- extends Object
- implements Comparable<LinearSegmentsNodePlacer.LinearSegment>
A linear segment contains a single regular node or all dummy nodes of a long edge.
- Rating

LinearSegmentsNodePlacer.LinearSegment
public LinearSegmentsNodePlacer.LinearSegment()
getNodes
public List<LNode> getNodes()
- Returns:
- the nodes
split
public LinearSegmentsNodePlacer.LinearSegment split(LNode node,
int newId)
- Splits this linear segment before the given node. The returned segment contains
all nodes from the given node onward, with their ID set to the new segment's ID.
Those nodes are removed from this segment.
- Parameters:
node
- the node to split the segment at.newId
- the new segment's id.
- Returns:
- new linear segment with ID
-1
and all nodes from node
onward.
toString
public String toString()
-
- Overrides:
toString
in class Object
compareTo
public int compareTo(LinearSegmentsNodePlacer.LinearSegment other)
-
- Specified by:
compareTo
in interface Comparable<LinearSegmentsNodePlacer.LinearSegment>