Interface FlatMappingVisitor
- All Known Implementing Classes:
RegularAsFlatMappingVisitor, SubsetChecker
public interface FlatMappingVisitor
A mapping visitor that provides the entire data for a given element within a single visit call.
-
Method Summary
Modifier and TypeMethodDescriptiondefault MappingVisitorstatic FlatMappingVisitorfromRegularVisitor(MappingVisitor visitor) default Set<MappingFlag> getFlags()default voidreset()booleanvisitClass(String srcName, @Nullable String[] dstNames) default booleanvisitClass(String srcName, String dstName) voidvisitClassComment(String srcName, @Nullable String[] dstNames, String comment) default voidvisitClassComment(String srcName, @Nullable String dstName, String comment) default voidvisitClassComment(String srcName, String comment) default booleanDetermine whether the mapping content (classes and anything below, metadata if not part of the header) should be visited.default booleanvisitEnd()Finish the visitation pass.booleanvisitField(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String[] dstClsNames, @Nullable String[] dstNames, @Nullable String[] dstDescs) default booleanvisitField(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String dstClsName, String dstName, @Nullable String dstDesc) default booleanvisitField(String srcClsName, String srcName, @Nullable String srcDesc, String dstName) default booleanvisitField(String srcClsName, String srcName, @Nullable String srcDesc, String[] dstNames) voidvisitFieldComment(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String[] dstClsNames, @Nullable String[] dstNames, @Nullable String[] dstDescs, String comment) default voidvisitFieldComment(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String dstClsName, @Nullable String dstName, @Nullable String dstDesc, String comment) default voidvisitFieldComment(String srcClsName, String srcName, @Nullable String srcDesc, String comment) default booleanDetermine whether the header (namespaces, metadata if part of the header) should be visited.default voidvisitMetadata(String key, @Nullable String value) booleanvisitMethod(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String[] dstClsNames, @Nullable String[] dstNames, @Nullable String[] dstDescs) default booleanvisitMethod(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String dstClsName, String dstName, @Nullable String dstDesc) default booleanvisitMethod(String srcClsName, String srcName, @Nullable String srcDesc, String dstName) default booleanvisitMethod(String srcClsName, String srcName, @Nullable String srcDesc, String[] dstNames) booleanvisitMethodArg(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, @Nullable String[] dstClsNames, @Nullable String[] dstMethodNames, @Nullable String[] dstMethodDescs, String[] dstNames) default booleanvisitMethodArg(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, @Nullable String dstClsName, @Nullable String dstMethodName, @Nullable String dstMethodDesc, String dstName) default booleanvisitMethodArg(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, String dstName) default booleanvisitMethodArg(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, String[] dstNames) voidvisitMethodArgComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, @Nullable String[] dstClsNames, @Nullable String[] dstMethodNames, @Nullable String[] dstMethodDescs, @Nullable String[] dstNames, String comment) default voidvisitMethodArgComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, @Nullable String dstClsName, @Nullable String dstMethodName, @Nullable String dstMethodDesc, @Nullable String dstName, String comment) default voidvisitMethodArgComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable String srcName, String comment) voidvisitMethodComment(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String[] dstClsNames, @Nullable String[] dstNames, @Nullable String[] dstDescs, String comment) default voidvisitMethodComment(String srcClsName, String srcName, @Nullable String srcDesc, @Nullable String dstClsName, @Nullable String dstName, @Nullable String dstDesc, String comment) default voidvisitMethodComment(String srcClsName, String srcName, @Nullable String srcDesc, String comment) booleanvisitMethodVar(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, @Nullable String[] dstClsNames, @Nullable String[] dstMethodNames, @Nullable String[] dstMethodDescs, String[] dstNames) default booleanvisitMethodVar(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, @Nullable String dstClsName, @Nullable String dstMethodName, @Nullable String dstMethodDesc, String dstName) default booleanvisitMethodVar(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, String dstName) default booleanvisitMethodVar(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, String[] dstNames) voidvisitMethodVarComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, @Nullable String[] dstClsNames, @Nullable String[] dstMethodNames, @Nullable String[] dstMethodDescs, @Nullable String[] dstNames, String comment) default voidvisitMethodVarComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, @Nullable String dstClsName, @Nullable String dstMethodName, @Nullable String dstMethodDesc, @Nullable String dstName, String comment) default voidvisitMethodVarComment(String srcClsName, String srcMethodName, @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable String srcName, String comment) voidvisitNamespaces(String srcNamespace, List<String> dstNamespaces)
-
Method Details
-
getFlags
-
reset
default void reset() -
visitHeader
Determine whether the header (namespaces, metadata if part of the header) should be visited.- Returns:
trueif the header is to be visited,falseotherwise.- Throws:
IOException
-
visitNamespaces
- Throws:
IOException
-
visitMetadata
- Throws:
IOException
-
visitContent
Determine whether the mapping content (classes and anything below, metadata if not part of the header) should be visited.- Returns:
trueif content is to be visited,falseotherwise.- Throws:
IOException
-
visitClass
- Throws:
IOException
-
visitClassComment
void visitClassComment(String srcName, @Nullable @Nullable String[] dstNames, String comment) throws IOException - Throws:
IOException
-
visitField
boolean visitField(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstNames, @Nullable @Nullable String[] dstDescs) throws IOException - Throws:
IOException
-
visitFieldComment
void visitFieldComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstNames, @Nullable @Nullable String[] dstDescs, String comment) throws IOException - Throws:
IOException
-
visitMethod
boolean visitMethod(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstNames, @Nullable @Nullable String[] dstDescs) throws IOException - Throws:
IOException
-
visitMethodComment
void visitMethodComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstNames, @Nullable @Nullable String[] dstDescs, String comment) throws IOException - Throws:
IOException
-
visitMethodArg
boolean visitMethodArg(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstMethodNames, @Nullable @Nullable String[] dstMethodDescs, String[] dstNames) throws IOException - Throws:
IOException
-
visitMethodArgComment
void visitMethodArgComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstMethodNames, @Nullable @Nullable String[] dstMethodDescs, @Nullable @Nullable String[] dstNames, String comment) throws IOException - Throws:
IOException
-
visitMethodVar
boolean visitMethodVar(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstMethodNames, @Nullable @Nullable String[] dstMethodDescs, String[] dstNames) throws IOException - Throws:
IOException
-
visitMethodVarComment
void visitMethodVarComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, @Nullable @Nullable String[] dstClsNames, @Nullable @Nullable String[] dstMethodNames, @Nullable @Nullable String[] dstMethodDescs, @Nullable @Nullable String[] dstNames, String comment) throws IOException - Throws:
IOException
-
visitEnd
Finish the visitation pass.- Returns:
trueif the visitation pass is final,falseif it should be started over.- Throws:
IOException
-
asRegularVisitor
-
fromRegularVisitor
-
visitField
default boolean visitField(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String[] dstNames) throws IOException - Throws:
IOException
-
visitMethod
default boolean visitMethod(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String[] dstNames) throws IOException - Throws:
IOException
-
visitMethodArg
default boolean visitMethodArg(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, String[] dstNames) throws IOException - Throws:
IOException
-
visitMethodVar
default boolean visitMethodVar(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, String[] dstNames) throws IOException - Throws:
IOException
-
visitClass
- Throws:
IOException
-
visitClassComment
- Throws:
IOException
-
visitClassComment
default void visitClassComment(String srcName, @Nullable @Nullable String dstName, String comment) throws IOException - Throws:
IOException
-
visitField
default boolean visitField(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String dstName) throws IOException - Throws:
IOException
-
visitField
default boolean visitField(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String dstClsName, String dstName, @Nullable @Nullable String dstDesc) throws IOException - Throws:
IOException
-
visitFieldComment
default void visitFieldComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String comment) throws IOException - Throws:
IOException
-
visitFieldComment
default void visitFieldComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstName, @Nullable @Nullable String dstDesc, String comment) throws IOException - Throws:
IOException
-
visitMethod
default boolean visitMethod(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String dstName) throws IOException - Throws:
IOException
-
visitMethod
default boolean visitMethod(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String dstClsName, String dstName, @Nullable @Nullable String dstDesc) throws IOException - Throws:
IOException
-
visitMethodComment
default void visitMethodComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, String comment) throws IOException - Throws:
IOException
-
visitMethodComment
default void visitMethodComment(String srcClsName, String srcName, @Nullable @Nullable String srcDesc, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstName, @Nullable @Nullable String dstDesc, String comment) throws IOException - Throws:
IOException
-
visitMethodArg
default boolean visitMethodArg(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, String dstName) throws IOException - Throws:
IOException
-
visitMethodArg
default boolean visitMethodArg(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstMethodName, @Nullable @Nullable String dstMethodDesc, String dstName) throws IOException - Throws:
IOException
-
visitMethodArgComment
default void visitMethodArgComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, String comment) throws IOException - Throws:
IOException
-
visitMethodArgComment
default void visitMethodArgComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int argPosition, int lvIndex, @Nullable @Nullable String srcName, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstMethodName, @Nullable @Nullable String dstMethodDesc, @Nullable @Nullable String dstName, String comment) throws IOException - Throws:
IOException
-
visitMethodVar
default boolean visitMethodVar(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, String dstName) throws IOException - Throws:
IOException
-
visitMethodVar
default boolean visitMethodVar(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstMethodName, @Nullable @Nullable String dstMethodDesc, String dstName) throws IOException - Throws:
IOException
-
visitMethodVarComment
default void visitMethodVarComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, String comment) throws IOException - Throws:
IOException
-
visitMethodVarComment
default void visitMethodVarComment(String srcClsName, String srcMethodName, @Nullable @Nullable String srcMethodDesc, int lvtRowIndex, int lvIndex, int startOpIdx, int endOpIdx, @Nullable @Nullable String srcName, @Nullable @Nullable String dstClsName, @Nullable @Nullable String dstMethodName, @Nullable @Nullable String dstMethodDesc, @Nullable @Nullable String dstName, String comment) throws IOException - Throws:
IOException
-