Record Class JarStructure
java.lang.Object
java.lang.Record
com.cleanroommc.gradle.api.names.JarStructure
The class/method/field shape of a jar, read with ASM. Used to emit valid Tiny2
(which needs real descriptors that the legacy MCP SRG text files do not carry, especially for fields).
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordOne class's SRG-named members.static final recordA method or field: its name and JVM descriptor. -
Constructor Summary
ConstructorsConstructorDescriptionJarStructure(Map<String, JarStructure.ClassEntry> classes) Creates an instance of aJarStructurerecord class. -
Method Summary
Modifier and TypeMethodDescriptionclasses()Returns the value of theclassesrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static JarStructureScans a jar, keeping only members whose names look like SRG ids (func_/field_).final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
JarStructure
Creates an instance of aJarStructurerecord class.- Parameters:
classes- the value for theclassesrecord component
-
-
Method Details
-
scan
Scans a jar, keeping only members whose names look like SRG ids (func_/field_). -
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). -
classes
Returns the value of theclassesrecord component.- Returns:
- the value of the
classesrecord component
-