@NonNullByDefault public class RootTypeExpectation extends AbstractRootTypeExpectation
Constructor and Description |
---|
RootTypeExpectation(LightweightTypeReference reference,
AbstractTypeComputationState state) |
Modifier and Type | Method and Description |
---|---|
ITypeExpectation |
copyInto(ITypeReferenceOwner referenceOwner) |
LightweightTypeReference |
getExpectedType()
Returns the expected type.
|
boolean |
isNoTypeExpectation()
Returns
true if anything is allowed and no constraints are expected. |
acceptActualType
createUnboundTypeReference, getConverter, getReferenceOwner, getResolvedTypes, getState, isOwnedBy, isVoidTypeAllowed, toString
public RootTypeExpectation(@Nullable LightweightTypeReference reference, AbstractTypeComputationState state)
public boolean isNoTypeExpectation()
ITypeExpectation
true
if anything is allowed and no constraints are expected.true
if anything is allowed and no constraints are expected.@Nullable public LightweightTypeReference getExpectedType()
ITypeExpectation
ITypeExpectation.getExpectedType()
may return
null
or some sort of unresolved, specialized reference. If null
is returned, clients
may want to check ITypeExpectation.isNoTypeExpectation()
or ITypeExpectation.isVoidTypeAllowed()
.null
.public ITypeExpectation copyInto(ITypeReferenceOwner referenceOwner)