Class ClassTweakerRemapperVisitor
java.lang.Object
net.fabricmc.classtweaker.visitors.ClassTweakerRemapperVisitor
- All Implemented Interfaces:
ClassTweakerVisitor
Decorates a
ClassTweakerVisitor with a Remapper
to remap names passing through the visitor if they come from a different namespace.-
Constructor Summary
ConstructorsConstructorDescriptionClassTweakerRemapperVisitor(ClassTweakerVisitor delegate, Remapper remapper, String fromNamespace, String toNamespace) -
Method Summary
Modifier and TypeMethodDescription@Nullable AccessWidenerVisitorvisitAccessWidener(String owner) voidvisitHeader(String namespace) Visits the header data.voidvisitInjectedInterface(String owner, String iface, boolean transitive) Visit an injected interface.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.fabricmc.classtweaker.api.visitor.ClassTweakerVisitor
visitLineNumber
-
Constructor Details
-
ClassTweakerRemapperVisitor
public ClassTweakerRemapperVisitor(ClassTweakerVisitor delegate, Remapper remapper, String fromNamespace, String toNamespace) - Parameters:
delegate- The visitor to forward the remapped information to.remapper- Will be used to remap names found in the access widener.fromNamespace- The expected namespace of the access widener being remapped. Remapping fails if the actual namespace is different.toNamespace- The namespace that the access widener will be remapped to.
-
-
Method Details
-
visitHeader
Description copied from interface:ClassTweakerVisitorVisits the header data.- Specified by:
visitHeaderin interfaceClassTweakerVisitor- Parameters:
namespace- the access widener's mapping namespace
-
visitAccessWidener
- Specified by:
visitAccessWidenerin interfaceClassTweakerVisitor
-
visitInjectedInterface
Description copied from interface:ClassTweakerVisitorVisit an injected interface.- Specified by:
visitInjectedInterfacein interfaceClassTweakerVisitor- Parameters:
owner- the class name of the class to inject the interface ontoiface- the class name of the interface to inject onto the target class, plus any generics. If generics are present, then this follows the format of JVMS 4.7.9.1ClassTypeSignatures, minus the surroundingLand semicolon.transitive- whether this widener should be applied across mod boundaries
-