Class ResolvedIntersectionType
java.lang.Object
com.github.javaparser.resolution.types.ResolvedIntersectionType
- All Implemented Interfaces:
ResolvedType
An intersection type is defined in java as list of types separates by ampersands.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondescribe()booleaninthashCode()booleanisAssignableBy(ResolvedType other) This method checks if ThisType t = new OtherType() would compile.replaceTypeVariables(ResolvedTypeParameterDeclaration tp, ResolvedType replaced, Map<ResolvedTypeParameterDeclaration, ResolvedType> inferredTypes) Replace all variables referring to the given TypeParameter with the given value.Methods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ResolvedType
arrayLevel, asArrayType, asConstraintType, asPrimitive, asReferenceType, asTypeParameter, asTypeVariable, asUnionType, asWildcard, erasure, isArray, isConstraint, isInferenceVariable, isNull, isNumericType, isPrimitive, isReference, isReferenceType, isTypeVariable, isUnionType, isVoid, isWildcard, mention, replaceTypeVariables, solveGenericTypes, toDescriptor
-
Field Details
-
elements
-
-
Constructor Details
-
ResolvedIntersectionType
-
-
Method Details
-
equals
-
hashCode
-
describe
- Specified by:
describein interfaceResolvedType
-
isAssignableBy
Description copied from interface:ResolvedTypeThis method checks if ThisType t = new OtherType() would compile.- Specified by:
isAssignableByin interfaceResolvedType
-
replaceTypeVariables
public ResolvedType replaceTypeVariables(ResolvedTypeParameterDeclaration tp, ResolvedType replaced, Map<ResolvedTypeParameterDeclaration, ResolvedType> inferredTypes) Description copied from interface:ResolvedTypeReplace all variables referring to the given TypeParameter with the given value. By replacing these values I could also infer some type equivalence. Those would be collected in the given map.- Specified by:
replaceTypeVariablesin interfaceResolvedType
-
getElements
-