Record Class PredicateEntry
java.lang.Object
java.lang.Record
net.dillon.dillonlib.mixinplugin.PredicateEntry
- Record Components:
mixins- the list of mixins that should be disabled ifconditionreturns truecondition- the condition for if the list of mixins should be disabledreason- the message that is sent to console to inform the user why the list of mixins were disabled (this cannot be blank, or else will result in aIllegalStateException).messageType- the type of message that is sent to console (info, warning, debug or error). In a developing environment, a warning message is sent for every predicate entry.
public record PredicateEntry(String[] mixins, boolean condition, String reason, MessageType messageType)
extends Record
A list of mapped
mixin class names with booleans on whether the mixin should be enabled upon load time.
If the mapped boolean returns true, the every mapped mixin class id should be disabled.
- Since:
- 1.0
-
Constructor Summary
ConstructorsConstructorDescriptionPredicateEntry(String[] mixins, boolean condition, String reason) PredicateEntry(String[] mixins, boolean condition, String reason, MessageType messageType) Creates an instance of aPredicateEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of theconditionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of themessageTyperecord component.String[]mixins()Returns the value of themixinsrecord component.reason()Returns the value of thereasonrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PredicateEntry
-
PredicateEntry
Creates an instance of aPredicateEntryrecord class.- Parameters:
mixins- the value for themixinsrecord componentcondition- the value for theconditionrecord componentreason- the value for thereasonrecord componentmessageType- the value for themessageTyperecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
mixins
-
condition
-
reason
-
messageType
Returns the value of themessageTyperecord component.- Returns:
- the value of the
messageTyperecord component
-