java.lang.Object
java.lang.Record
org.maxicp.search.blackbox.BlackBoxSearch.IntervalSnapshot
- Enclosing class:
BlackBoxSearch
public static record BlackBoxSearch.IntervalSnapshot(boolean present, int start, int length, int end)
extends Record
Snapshot of an
IntervalVar in an incumbent solution.-
Constructor Summary
ConstructorsConstructorDescriptionIntervalSnapshot(boolean present, int start, int length, int end) Creates an instance of aIntervalSnapshotrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintend()Returns the value of theendrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intlength()Returns the value of thelengthrecord component.booleanpresent()Returns the value of thepresentrecord component.intstart()Returns the value of thestartrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
IntervalSnapshot
public IntervalSnapshot(boolean present, int start, int length, int end) Creates an instance of aIntervalSnapshotrecord class.- Parameters:
present- the value for thepresentrecord componentstart- the value for thestartrecord componentlength- the value for thelengthrecord componentend- the value for theendrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
present
public boolean present()Returns the value of thepresentrecord component.- Returns:
- the value of the
presentrecord component
-
start
public int start()Returns the value of thestartrecord component.- Returns:
- the value of the
startrecord component
-
length
public int length()Returns the value of thelengthrecord component.- Returns:
- the value of the
lengthrecord component
-
end
public int end()Returns the value of theendrecord component.- Returns:
- the value of the
endrecord component
-