Record Class ConstraintDescriptor
java.lang.Object
java.lang.Record
ai.timefold.solver.service.definition.internal.descriptor.ConstraintDescriptor
- Record Components:
name- the human-readable name serving as the unique identifierdescription- the human-readable descriptiondefaultWeight- default weight of the constraint
-
Constructor Summary
ConstructorsConstructorDescriptionConstraintDescriptor(String id, String name, String description, String defaultWeight) Creates an instance of aConstraintDescriptorrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedefaultWeightrecord component.Returns the value of thedescriptionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.name()Returns the value of thenamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ConstraintDescriptor
Creates an instance of aConstraintDescriptorrecord class.- Parameters:
id- the value for theidrecord componentname- the value for thenamerecord componentdescription- the value for thedescriptionrecord componentdefaultWeight- the value for thedefaultWeightrecord component
-
-
Method Details
-
toString
-
hashCode
-
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). -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
name
-
description
Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-
defaultWeight
Returns the value of thedefaultWeightrecord component.- Returns:
- the value of the
defaultWeightrecord component
-