Package org.goplanit.assignment.ltm.sltm
Class BushFlowLabel
- java.lang.Object
-
- org.goplanit.assignment.ltm.sltm.BushFlowLabel
-
- All Implemented Interfaces:
Comparable<BushFlowLabel>
public class BushFlowLabel extends Object implements Comparable<BushFlowLabel>
Label that track a unique composition of flow along an edge of a bush acyclic directed graph. In addition to the label itself it also carries information regarding its predecessor (if any). Predecessor composition labels are other flow compositions upstream of this composition that (partly) split off flow of this composition label at diverges, resulting in a non-zero splitting rate between the two labels at this diverge.- Author:
- markr
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBushFlowLabel(BushFlowLabel other)Copy constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(BushFlowLabel o)static BushFlowLabelcreate(IdGroupingToken idToken)Create a new flow composition label for this bushstatic BushFlowLabelcreate(IdGroupingToken idToken, String name)Create a new flow composition label for this bushbooleanequals(Object o)protected static longgenerateId(IdGroupingToken idToken)Generate idlonggetLabelId()The unique label id within its contextinthashCode()StringtoString()
-
-
-
Constructor Detail
-
BushFlowLabel
protected BushFlowLabel(BushFlowLabel other)
Copy constructor- Parameters:
other- to copy
-
-
Method Detail
-
generateId
protected static final long generateId(IdGroupingToken idToken)
Generate id- Parameters:
idToken- to use- Returns:
- the generated id
-
getLabelId
public long getLabelId()
The unique label id within its context- Returns:
- the label id
-
compareTo
public int compareTo(BushFlowLabel o)
- Specified by:
compareToin interfaceComparable<BushFlowLabel>
-
create
public static BushFlowLabel create(IdGroupingToken idToken)
Create a new flow composition label for this bush- Parameters:
idToken- to use- Returns:
- created label
-
create
public static BushFlowLabel create(IdGroupingToken idToken, String name)
Create a new flow composition label for this bush- Parameters:
idToken- to usename- of the label- Returns:
- created label
-
-