Class GenericType
- java.lang.Object
-
- org.apache.karaf.shell.commands.converter.ReifiedType
-
- org.apache.karaf.shell.commands.converter.GenericType
-
@Deprecated public class GenericType extends ReifiedType
Deprecated.
-
-
Constructor Summary
Constructors Constructor Description GenericType(Class clazz, GenericType... parameters)Deprecated.GenericType(Type type)Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ReifiedTypegetActualTypeArgument(int i)Deprecated.Access to a type argument.static GenericTypeparse(String type, Object loader)Deprecated.intsize()Deprecated.Return the number of type arguments.StringtoString()Deprecated.-
Methods inherited from class org.apache.karaf.shell.commands.converter.ReifiedType
getRawClass
-
-
-
-
Constructor Detail
-
GenericType
public GenericType(Type type)
Deprecated.
-
GenericType
public GenericType(Class clazz, GenericType... parameters)
Deprecated.
-
-
Method Detail
-
parse
public static GenericType parse(String type, Object loader) throws ClassNotFoundException, IllegalArgumentException
Deprecated.
-
getActualTypeArgument
public ReifiedType getActualTypeArgument(int i)
Deprecated.Description copied from class:ReifiedTypeAccess to a type argument. The type argument refers to a argument in a generic type declaration given by indexi. This method returns a Reified Type that has Object as class when no generic type information is available. Any object is assignable to Object and therefore no conversion is then necessary, this is compatible with older Javas than 5. For this reason, the implementation in this class always returns theObjectclass, regardless of the given index. This method should be overridden by a subclass that provides access to the generic information. For example, in the following example:Map<String, Object> map;
The type argument 0 isString, and type argument 1 isObject.- Overrides:
getActualTypeArgumentin classReifiedType- Parameters:
i- The index of the type argument- Returns:
ReifiedType(Object.class), subclasses must override this and return the generic argument at indexi
-
size
public int size()
Deprecated.Description copied from class:ReifiedTypeReturn the number of type arguments. This method should be overridden by a subclass to support Java 5 types.- Overrides:
sizein classReifiedType- Returns:
- 0, subclasses must override this and return the number of generic arguments
-
-