Package dev.architectury.loom.forge
Record Class AccessTransformerRuleTranslator.Input
java.lang.Object
java.lang.Record
dev.architectury.loom.forge.AccessTransformerRuleTranslator.Input
- Record Components:
rules- 原始 AT 规则行(含注释行与空行,原样传入)mappings- 映射树sourceNamespace- 规则当前的命名空间(legacy Forge 为srg)targetNamespace- 目标 jar 所在的命名空间(notch jar 为official)hierarchy- 类继承关系;为null时不做继承回退(只有直接成员能翻译)
- Enclosing class:
AccessTransformerRuleTranslator
public static record AccessTransformerRuleTranslator.Input(List<String> rules, net.fabricmc.mappingio.tree.MappingTree mappings, String sourceNamespace, String targetNamespace, @Nullable AccessTransformerRuleTranslator.ClassHierarchy hierarchy)
extends Record
一次翻译所需的全部输入.
-
Constructor Summary
Constructors -
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.Returns the value of thehierarchyrecord component.net.fabricmc.mappingio.tree.MappingTreemappings()Returns the value of themappingsrecord component.rules()Returns the value of therulesrecord component.Returns the value of thesourceNamespacerecord component.Returns the value of thetargetNamespacerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Input
public Input(List<String> rules, net.fabricmc.mappingio.tree.MappingTree mappings, String sourceNamespace, String targetNamespace, @Nullable AccessTransformerRuleTranslator.ClassHierarchy hierarchy) Creates an instance of aInputrecord class.- Parameters:
rules- the value for therulesrecord componentmappings- the value for themappingsrecord componentsourceNamespace- the value for thesourceNamespacerecord componenttargetNamespace- the value for thetargetNamespacerecord componenthierarchy- the value for thehierarchyrecord 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. All components in this record class are compared withObjects::equals(Object,Object). -
rules
Returns the value of therulesrecord component.- Returns:
- the value of the
rulesrecord component
-
mappings
public net.fabricmc.mappingio.tree.MappingTree mappings()Returns the value of themappingsrecord component.- Returns:
- the value of the
mappingsrecord component
-
sourceNamespace
Returns the value of thesourceNamespacerecord component.- Returns:
- the value of the
sourceNamespacerecord component
-
targetNamespace
Returns the value of thetargetNamespacerecord component.- Returns:
- the value of the
targetNamespacerecord component
-
hierarchy
Returns the value of thehierarchyrecord component.- Returns:
- the value of the
hierarchyrecord component
-