Record Class ModuleRequireRuleSpec
java.lang.Object
java.lang.Record
dev.archunitjava.rules.ModuleRequireRuleSpec
public record ModuleRequireRuleSpec(ModuleRuleMode mode, DirectiveFlagPolicy transitive, DirectiveFlagPolicy staticPhase)
extends Record
Requires-directive mode plus exact transitive/static-phase modifier constraints.
-
Constructor Summary
ConstructorsConstructorDescriptionModuleRequireRuleSpec(ModuleRuleMode mode, DirectiveFlagPolicy transitive, DirectiveFlagPolicy staticPhase) Creates an instance of aModuleRequireRuleSpecrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.mode()Returns the value of themoderecord component.static ModuleRequireRuleSpecno()static ModuleRequireRuleSpeconly()static ModuleRequireRuleSpecrequired()Returns the value of thestaticPhaserecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetransitiverecord component.withStaticPhase(DirectiveFlagPolicy policy) withTransitive(DirectiveFlagPolicy policy)
-
Constructor Details
-
ModuleRequireRuleSpec
public ModuleRequireRuleSpec(ModuleRuleMode mode, DirectiveFlagPolicy transitive, DirectiveFlagPolicy staticPhase) Creates an instance of aModuleRequireRuleSpecrecord class.- Parameters:
mode- the value for themoderecord componenttransitive- the value for thetransitiverecord componentstaticPhase- the value for thestaticPhaserecord component
-
-
Method Details
-
no
-
only
-
required
-
withTransitive
-
withStaticPhase
-
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). -
mode
Returns the value of themoderecord component.- Returns:
- the value of the
moderecord component
-
transitive
Returns the value of thetransitiverecord component.- Returns:
- the value of the
transitiverecord component
-
staticPhase
Returns the value of thestaticPhaserecord component.- Returns:
- the value of the
staticPhaserecord component
-