Module org.glavo.classfile
Package org.glavo.classfile.impl
Record Class UnboundAttribute.UnboundModuleRequiresInfo
java.lang.Object
java.lang.Record
org.glavo.classfile.impl.UnboundAttribute.UnboundModuleRequiresInfo
- All Implemented Interfaces:
ModuleRequireInfo
- Enclosing class:
UnboundAttribute<T extends Attribute<T>>
public static record UnboundAttribute.UnboundModuleRequiresInfo(ModuleEntry requires, int requiresFlagsMask, Optional<Utf8Entry> requiresVersion)
extends Record
implements ModuleRequireInfo
-
Constructor Summary
ConstructorsConstructorDescriptionUnboundModuleRequiresInfo(ModuleEntry requires, int requiresFlagsMask, Optional<Utf8Entry> requiresVersion) Creates an instance of aUnboundModuleRequiresInforecord 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.requires()Returns the value of therequiresrecord component.intReturns the value of therequiresFlagsMaskrecord component.Returns the value of therequiresVersionrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.glavo.classfile.attribute.ModuleRequireInfo
has, requiresFlags
-
Constructor Details
-
UnboundModuleRequiresInfo
public UnboundModuleRequiresInfo(ModuleEntry requires, int requiresFlagsMask, Optional<Utf8Entry> requiresVersion) Creates an instance of aUnboundModuleRequiresInforecord class.- Parameters:
requires- the value for therequiresrecord componentrequiresFlagsMask- the value for therequiresFlagsMaskrecord componentrequiresVersion- the value for therequiresVersionrecord component
-
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
requires
Returns the value of therequiresrecord component.- Specified by:
requiresin interfaceModuleRequireInfo- Returns:
- the value of the
requiresrecord component
-
requiresFlagsMask
public int requiresFlagsMask()Returns the value of therequiresFlagsMaskrecord component.- Specified by:
requiresFlagsMaskin interfaceModuleRequireInfo- Returns:
- the value of the
requiresFlagsMaskrecord component
-
requiresVersion
Returns the value of therequiresVersionrecord component.- Specified by:
requiresVersionin interfaceModuleRequireInfo- Returns:
- the value of the
requiresVersionrecord component
-