Interface NameMapper

  • All Known Implementing Classes:
    ClassTree

    public interface NameMapper
    Interface to a class, method, field remapping table.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String[] getAttrsToKeep​(java.lang.String className)
      Return a list of attributes marked to keep.
      java.lang.String mapAnnotationField​(java.lang.String className, java.lang.String annotationFieldName)
      Mapping for an annotation field/method, of fully qualified annotation class.
      java.lang.String mapClass​(java.lang.String className)
      Mapping for fully qualified class name.
      java.lang.String mapDescriptor​(java.lang.String descriptor)
      Mapping for descriptor of field or method.
      java.lang.String mapField​(java.lang.String className, java.lang.String fieldName)
      Mapping for field name, of fully qualified class.
      boolean mapLineNumberTable​(java.lang.String className, java.lang.String methodName, java.lang.String methodSignature, LineNumberTableAttrInfo info)
      Mapping for the line number table.
      java.lang.String mapLocalVariable​(java.lang.String thisClassName, java.lang.String methodName, java.lang.String descriptor, java.lang.String string)
      Map local variable string.
      java.lang.String mapMethod​(java.lang.String className, java.lang.String methodName, java.lang.String descriptor)
      Mapping for method name, of fully qualified class.
      java.lang.String mapPackage​(java.lang.String packageName)
      Mapping for package name.
      java.lang.String mapSignature​(java.lang.String signature)
      Mapping for signature of field or method.
      java.lang.String mapSourceFile​(java.lang.String className, java.lang.String sourceFile)
      Mapping for the source file attribute of a file.
    • Method Detail

      • getAttrsToKeep

        java.lang.String[] getAttrsToKeep​(java.lang.String className)
        Return a list of attributes marked to keep.
        Parameters:
        className - the class name
        Returns:
        the string [ ]
      • mapClass

        java.lang.String mapClass​(java.lang.String className)
        Mapping for fully qualified class name.
        Parameters:
        className - the class name
        Returns:
        the string
      • mapMethod

        java.lang.String mapMethod​(java.lang.String className,
                                   java.lang.String methodName,
                                   java.lang.String descriptor)
        Mapping for method name, of fully qualified class.
        Parameters:
        className - the class name
        methodName - the method name
        descriptor - the descriptor
        Returns:
        the string
      • mapAnnotationField

        java.lang.String mapAnnotationField​(java.lang.String className,
                                            java.lang.String annotationFieldName)
        Mapping for an annotation field/method, of fully qualified annotation class.
        Parameters:
        className - the class name
        annotationFieldName - the annotation field name
        Returns:
        the string
      • mapField

        java.lang.String mapField​(java.lang.String className,
                                  java.lang.String fieldName)
        Mapping for field name, of fully qualified class.
        Parameters:
        className - the class name
        fieldName - the field name
        Returns:
        the string
      • mapDescriptor

        java.lang.String mapDescriptor​(java.lang.String descriptor)
        Mapping for descriptor of field or method.
        Parameters:
        descriptor - the descriptor
        Returns:
        the string
      • mapSignature

        java.lang.String mapSignature​(java.lang.String signature)
        Mapping for signature of field or method.
        Parameters:
        signature - the signature
        Returns:
        the string
      • mapSourceFile

        java.lang.String mapSourceFile​(java.lang.String className,
                                       java.lang.String sourceFile)
        Mapping for the source file attribute of a file.
        Parameters:
        className - the class name
        sourceFile - the source file
        Returns:
        the string
      • mapLineNumberTable

        boolean mapLineNumberTable​(java.lang.String className,
                                   java.lang.String methodName,
                                   java.lang.String methodSignature,
                                   LineNumberTableAttrInfo info)
        Mapping for the line number table.
        Parameters:
        className - the class name
        methodName - the method name
        methodSignature - the method signature
        info - the info
        Returns:
        false if the line number table may be discarded
      • mapLocalVariable

        java.lang.String mapLocalVariable​(java.lang.String thisClassName,
                                          java.lang.String methodName,
                                          java.lang.String descriptor,
                                          java.lang.String string)
        Map local variable string.
        Parameters:
        thisClassName - the this class name
        methodName - the method name
        descriptor - the descriptor
        string - the string
        Returns:
        the string
      • mapPackage

        java.lang.String mapPackage​(java.lang.String packageName)
        Mapping for package name.
        Parameters:
        packageName - the package name
        Returns:
        the string