Record Class AssignmentPlan.Problem
java.lang.Object
java.lang.Record
mekhq.campaign.unit.crewAssignment.AssignmentPlan.Problem
- Record Components:
change- the changereason- why it cannot be applied
- Enclosing class:
AssignmentPlan
public static record AssignmentPlan.Problem(AssignmentPlan.StagedAssignment change, AssignmentPlan.Reason reason)
extends Record
Something that would stop a staged crew move from being applied.
-
Constructor Summary
ConstructorsConstructorDescriptionProblem(AssignmentPlan.StagedAssignment change, AssignmentPlan.Reason reason) Creates an instance of aProblemrecord class. -
Method Summary
Modifier and TypeMethodDescriptionchange()Returns the value of thechangerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.reason()Returns the value of thereasonrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
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 withObjects::equals(Object,Object). -
change
Returns the value of thechangerecord component.- Returns:
- the value of the
changerecord component
-
reason
Returns the value of thereasonrecord component.- Returns:
- the value of the
reasonrecord component
-