Package ftbsc.lll.mapper.utils
Class MappingUtils
- java.lang.Object
-
- ftbsc.lll.mapper.utils.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 aType
and a validMapper
it returns its mapped counterpart.
-
-
-
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
- aString
containing the descriptormapper
- theMapper
to use for the processreverse
- 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 aType
and a validMapper
it returns its mapped counterpart.- Parameters:
type
- the type in questionmapper
- theMapper
to use for the processreverse
- if true it uses the inverted mapper rather than the normal one- Returns:
- the mapped type
-
-