Annotation Type Type
@DefaultQualifier(org.checkerframework.checker.nullness.qual.NonNull.class)
@Target(PARAMETER)
@Retention(RUNTIME)
public @interface Type
Used to specify an alternate type to use instead of the
annotated element's type.
This is mostly useful when a method
has a parameter whose type is not visible during compilation,
as it allows referencing a reflection proxy, or fully qualified
class name to use instead of Object, which must be used
at compile time for these types.
-
Optional Element Summary
Optional Elements
-
Element Details
-
value
Class<?> valueA reflection proxy interface proxying the target class. A value ofObject.classindicates it has not been changed from the default, and thatclassName()should be used to lookup the class instead.- Returns:
- target class
- Default:
- java.lang.Object.class
-
className
String classNameThe fully qualified name of the target class. A value of""(empty string) indicates it has not been changed from the default, and thatvalue()should be used instead.- Returns:
- target class name
- Default:
- ""
-