java.lang.Object
org.glassfish.hk2.utilities.reflection.TypeChecker
This class contains various utilities for ensuring
java type safety
- Author:
- jwells
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisRawTypeSafe(Type requiredType, Type beanType) Returns true if the given requiredType is safely assignable from the given beanType.
-
Constructor Details
-
TypeChecker
public TypeChecker()
-
-
Method Details
-
isRawTypeSafe
Returns true if the given requiredType is safely assignable from the given beanType. In otherwords, ifrequiredType = beanTypewithout any cast. It should be noted that this checker is using the CDI rules (as stated in CDI version 1.1 in section- Parameters:
requiredType- The type being assigned intobeanType- the type being assigned- Returns:
- true if things are type safe
-