Package com.tngtech.archunit.core.domain
Interface JavaType
- All Superinterfaces:
HasName
- All Known Subinterfaces:
JavaParameterizedType
- All Known Implementing Classes:
JavaClass
,JavaGenericArrayType
,JavaTypeVariable
,JavaWildcardType
@PublicAPI(usage=ACCESS) public interface JavaType extends HasName
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
JavaType.Functions
Nested classes/interfaces inherited from interface com.tngtech.archunit.core.domain.properties.HasName
HasName.AndFullName, HasName.Predicates
-
Method Summary
Modifier and Type Method Description JavaClass
toErasure()
Converts thisJavaType
into the erased type (compare the Java Language Specification).
-
Method Details
-
toErasure
Converts thisJavaType
into the erased type (compare the Java Language Specification). In particular this will result in- the class itself, if this type is a
JavaClass
- the
JavaClass
equivalent toObject
, if this type is an unboundJavaTypeVariable
- the
JavaClass
equivalent to the erasure of the left most bound, if this type is a boundJavaTypeVariable
- if this type is a
JavaGenericArrayType
, the erasure will be theJavaClass
equivalent to the array type that has the erasure of the generic component type of this type as its component type; e.g. take the generic array typeT[][]
whereT
is unbound, then the erasure will be the array typeObject[][]
- the class itself, if this type is a
-