- java.lang.Object
-
- com.remondis.remap.GenericParameterContext
-
public class GenericParameterContext extends Object
Holds generic parameter types when traversing recursively through nested generic type declarations.
-
-
Constructor Summary
Constructors Constructor Description GenericParameterContext(Method method)Creates a new context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ParameterizedTypeget()Returns the current parameterized type.Class<?>getCurrentType()GenericParameterContextgoInto(int genericParameterIndex)Traverses the next recursive level in the nested generic types.StringtoString()
-
-
-
Constructor Detail
-
GenericParameterContext
public GenericParameterContext(Method method)
Creates a new context.- Parameters:
method- For this method.
-
-
Method Detail
-
get
public ParameterizedType get()
Returns the current parameterized type.- Returns:
- Returns the current parameterized type.
-
getCurrentType
public Class<?> getCurrentType()
-
goInto
public GenericParameterContext goInto(int genericParameterIndex)
Traverses the next recursive level in the nested generic types.- Parameters:
genericParameterIndex- The generic parameter index. Example: Map<A,B>: A=0, B=1.- Returns:
- Return the type after traversing one step.
-
-