public final class TimePoint extends Variable
APSPSolver temporal reasoner, namely time points.
Note that as all variables, TimePoints should be created with a solver factory method
(in this case, APSPSolver).attributes, backupForSerialization, dependentVariables, id, logger, solver| Constructor and Description |
|---|
TimePoint(int id,
int MAX_TPS,
APSPSolver sol)
Instantiate a new
TimePoint with a given identifier and maximum number of time points that can be
added to the temporal network. |
TimePoint(int id,
int MAX_TPS,
APSPSolver sol,
long lb,
long ub)
Instantiate a new
TimePoint with a given identifier, upper bound and lower bound that can be
added to the temporal network. |
| Modifier and Type | Method and Description |
|---|---|
TimePoint |
clone() |
int |
compareTo(Variable o) |
boolean |
equals(java.lang.Object obj)
Compare this time point with a reference time point.
|
Domain |
getDomain()
Get the domain of this Variable.
|
long |
getLowerBound()
Get this time point's lower bound.
|
SimpleDistanceConstraint[] |
getOut() |
SimpleDistanceConstraint |
getOut(int i)
Get the i-th outgoing edge of this time point.
|
long |
getUpperBound()
Get this time point's upper bound.
|
boolean |
isUsed()
Reports whether this time point is used in the underlying temporal network.
|
void |
setDomain(Domain d)
Set the domain of this variable.
|
void |
setLowerBound(long newVal)
Set this time point's lower bound.
|
void |
setOut(int i,
SimpleDistanceConstraint newVal)
Set the i-th outgoing edge of this time point.
|
void |
setUpperBound(long newVal)
Set this time point's upper bound.
|
void |
setUsed(boolean newVal)
Set whether this time point as used in the underlying temporal network.
|
java.lang.String |
toString()
Get a String representation of this
TimePoint. |
addDependentVariables, dependsOn, getAncestorVariable, getAttributes, getColor, getComponent, getConstraintSolver, getDependentVariables, getDescription, getID, getMarking, getOwner, getParentVariable, getRecursivelyDependentVariables, getRootVariable, hashCode, isDependentVariable, removeDependentVariables, setAttributes, setColor, setComponent, setDependentVariables, setMarking, setOwner, setParentVariablepublic TimePoint(int id,
int MAX_TPS,
APSPSolver sol)
TimePoint with a given identifier and maximum number of time points that can be
added to the temporal network. This constructor should NOT be used. As the APSPSolver is static,
this method is used in the APSPSolver's constructor to instantiate the array of time points
representing the temporal network.id - The identifier of this time point.MAX_TPS - The maximum number of time points supported by the APSPSolver.sol - the APSPSolver managing this TimePoint.public TimePoint(int id,
int MAX_TPS,
APSPSolver sol,
long lb,
long ub)
TimePoint with a given identifier, upper bound and lower bound that can be
added to the temporal network. This constructor should NOT be used (it is used within the APSPSolver,
a static STN implementation.id - The identifier of this time point.lb - The lower bound of this time point.ub - The upper bound of this time point.sol - the APSPSolver managing this TimePoint.public boolean equals(java.lang.Object obj)
public java.lang.String toString()
TimePoint.public long getLowerBound()
public void setLowerBound(long newVal)
newVal - The new lower bound to set.public long getUpperBound()
public void setUpperBound(long newVal)
newVal - The new upper bound to set.public boolean isUsed()
public void setUsed(boolean newVal)
newVal - Set to true iff the time point should be included in the underlying temporal network.public SimpleDistanceConstraint getOut(int i)
i - The index of the edge to get.SimpleDistanceConstraint correspionding to the i-th outgoing edge.public SimpleDistanceConstraint[] getOut()
public void setOut(int i,
SimpleDistanceConstraint newVal)
i - The index of the edge to set.newVal - The SimpleDistanceConstraint correspionding to set as i-th outgoing edge.public Domain getDomain()
Variablepublic void setDomain(Domain d)
Variablepublic int compareTo(Variable o)
public TimePoint clone()
clone in class java.lang.Object