Class MappingUtils


  • public class MappingUtils
    extends java.lang.Object
    A collection of static utility methods correlated to mappers.
    • Constructor Summary

      Constructors 
      Constructor Description
      MappingUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String mapMethodDescriptor​(java.lang.String descriptor, Mapper mapper, boolean reverse)
      Maps a method descriptor, replacing its class references with their mapped counterparts.
      static org.objectweb.asm.Type mapType​(org.objectweb.asm.Type type, Mapper mapper, boolean reverse)
      Given a Type and a valid Mapper it returns its mapped counterpart.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MappingUtils

        public MappingUtils()
    • Method Detail

      • mapMethodDescriptor

        public static java.lang.String mapMethodDescriptor​(java.lang.String descriptor,
                                                           Mapper mapper,
                                                           boolean reverse)
        Maps a method descriptor, replacing its class references with their mapped counterparts.
        Parameters:
        descriptor - a String containing the descriptor
        mapper - the Mapper to use for the process
        reverse - if true it uses the inverted mapper rather than the normal one
        Returns:
        the mapped descriptor
      • mapType

        public static org.objectweb.asm.Type mapType​(org.objectweb.asm.Type type,
                                                     Mapper mapper,
                                                     boolean reverse)
        Given a Type and a valid Mapper it returns its mapped counterpart.
        Parameters:
        type - the type in question
        mapper - the Mapper to use for the process
        reverse - if true it uses the inverted mapper rather than the normal one
        Returns:
        the mapped type