java.lang.Object
java.lang.Record
org.maxicp.modeling.xcsp3.XCSP3.XCSP3LoadedInstance
- All Implemented Interfaces:
AutoCloseable
- Enclosing class:
XCSP3
public static record XCSP3.XCSP3LoadedInstance(ModelDispatcher md, IntExpression[] decisionVars, Supplier<String> solutionGenerator)
extends Record
implements AutoCloseable
-
Constructor Summary
ConstructorsConstructorDescriptionXCSP3LoadedInstance(ModelDispatcher md, IntExpression[] decisionVars, Supplier<String> solutionGenerator) Creates an instance of aXCSP3LoadedInstancerecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Returns the value of thedecisionVarsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.md()Returns the value of themdrecord component.Returns the value of thesolutionGeneratorrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
XCSP3LoadedInstance
public XCSP3LoadedInstance(ModelDispatcher md, IntExpression[] decisionVars, Supplier<String> solutionGenerator) Creates an instance of aXCSP3LoadedInstancerecord class.- Parameters:
md- the value for themdrecord componentdecisionVars- the value for thedecisionVarsrecord componentsolutionGenerator- the value for thesolutionGeneratorrecord component
-
-
Method Details
-
close
- Specified by:
closein interfaceAutoCloseable- Throws:
Exception
-
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 withObjects::equals(Object,Object). -
md
Returns the value of themdrecord component.- Returns:
- the value of the
mdrecord component
-
decisionVars
Returns the value of thedecisionVarsrecord component.- Returns:
- the value of the
decisionVarsrecord component
-
solutionGenerator
Returns the value of thesolutionGeneratorrecord component.- Returns:
- the value of the
solutionGeneratorrecord component
-