public class SuperdenseDependency extends BooleanDependency
Red (eal) |
Yellow (eal) |
Modifier and Type | Field and Description |
---|---|
static SuperdenseDependency |
OPLUS_IDENTITY
The additive identity.
|
static SuperdenseDependency |
OTIMES_IDENTITY
The multiplicative identity.
|
_value
EQUALS, GREATER_THAN, INCOMPARABLE, LESS_THAN
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Dependency dependency)
Return Dependency.LESS_THAN, EQUALS, or GREATER_THAN depending
on whether the argument is less than, equal to, or greater than
this dependency.
|
boolean |
equals(java.lang.Object object)
Return true if the value of this dependency equals that
of the specified one, and the specified one is an instance
of RealDependency.
|
int |
hashCode()
Return the same hashCode that that Java Double object would
return had it the same value as the real part of the value
of this dependency.
|
int |
indexValue()
Return the index value of this dependency.
|
Dependency |
oPlus(Dependency dependency)
Return a dependency that results from parallel composition of
this one and the specified one.
|
Dependency |
oPlusIdentity()
Return the dependency that when added to any other
dependency using oPlus() yields the other dependency.
|
Dependency |
oTimes(Dependency dependency)
Return a dependency that results from serial composition of
this one and the specified one.
|
Dependency |
oTimesIdentity()
Return the dependency that when multiplied by any other
dependency using oTimes() yields the other dependency.
|
double |
timeValue()
Return the time value of this dependency.
|
java.lang.String |
toString()
Return a string representation in the form
"SuperdenseDependency(_time, _index)".
|
static SuperdenseDependency |
valueOf(double time,
int index)
Return an instance of SuperdenseDependency with the specified
time and index value.
|
valueOf
public static final SuperdenseDependency OPLUS_IDENTITY
public static final SuperdenseDependency OTIMES_IDENTITY
public int compareTo(Dependency dependency)
In the case where both dependencies have _time value equal to Double.POSITIVE_INFINITY, these two dependencies are equal, even though its indices may differ. This conforms with valueOf() method.
compareTo
in interface java.lang.Comparable<Dependency>
compareTo
in class BooleanDependency
dependency
- The dependency to compare against.java.lang.ClassCastException
- If the argument is not an instance
of SuperdenseDependency.valueOf(double, int)
public boolean equals(java.lang.Object object)
In the case where both dependencies have _time value equal to Double.POSITIVE_INFINITY, these two dependencies are equal, even though its indices may differ. This conforms with valueOf() method.
equals
in class BooleanDependency
object
- The object to compare against.valueOf(double, int)
public int hashCode()
hashCode
in class BooleanDependency
public int indexValue()
public Dependency oPlus(Dependency dependency)
oPlus
in interface Dependency
oPlus
in class BooleanDependency
dependency
- The dependency to add.java.lang.ClassCastException
- if dependency is not a SuperdenseDependency.public Dependency oPlusIdentity()
oPlusIdentity
in interface Dependency
oPlusIdentity
in class BooleanDependency
public Dependency oTimes(Dependency dependency)
oTimes
in interface Dependency
oTimes
in class BooleanDependency
dependency
- The dependency to multiply.java.lang.ClassCastException
- if dependency is not a RealDependency.public Dependency oTimesIdentity()
oTimesIdentity
in interface Dependency
oTimesIdentity
in class BooleanDependency
public double timeValue()
public java.lang.String toString()
toString
in class BooleanDependency
public static SuperdenseDependency valueOf(double time, int index)
time
- The time value.index
- The index value.OTIMES_IDENTITY
is returned, if
value is (Double.POSITIVE_INFINITY, n) for any n,
then OPLUS_IDENTITY
is returned. Otherwise the SuperdenseDependency constructor
is called.