Class BoundSet
- java.lang.Object
-
- com.github.javaparser.symbolsolver.resolution.typeinference.BoundSet
-
public class BoundSet extends java.lang.Object- Author:
- Federico Tomassetti
-
-
Constructor Summary
Constructors Constructor Description BoundSet()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontainsFalse()BoundSetderiveImpliedBounds(com.github.javaparser.resolution.TypeSolver typeSolver)static BoundSetempty()booleanequals(java.lang.Object o)java.util.List<Bound>getProperUpperBoundsFor(InferenceVariable inferenceVariable)inthashCode()BoundSetincorporate(BoundSet otherBounds, com.github.javaparser.resolution.TypeSolver typeSolver)Maintains a set of inference variable bounds, ensuring that these are consistent as new bounds are added.booleanisEmpty()booleanisTrue()It is sometimes convenient to refer to an empty bound set with the symbol true; this is merely out of convenience, and the two are interchangeable.java.util.Optional<InstantiationSet>performResolution(java.util.List<InferenceVariable> variablesToResolve, com.github.javaparser.resolution.TypeSolver typeSolver)Examines the bounds on an inference variable and determines an instantiation that is compatible with those bounds.java.lang.StringtoString()BoundSetwithBound(Bound bound)
-
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
isTrue
public boolean isTrue()
It is sometimes convenient to refer to an empty bound set with the symbol true; this is merely out of convenience, and the two are interchangeable.
-
empty
public static BoundSet empty()
-
isEmpty
public boolean isEmpty()
-
incorporate
public BoundSet incorporate(BoundSet otherBounds, com.github.javaparser.resolution.TypeSolver typeSolver)
Maintains a set of inference variable bounds, ensuring that these are consistent as new bounds are added. Because the bounds on one variable can sometimes impact the possible choices for another variable, this process propagates bounds between such interdependent variables.
-
deriveImpliedBounds
public BoundSet deriveImpliedBounds(com.github.javaparser.resolution.TypeSolver typeSolver)
-
containsFalse
public boolean containsFalse()
-
performResolution
public java.util.Optional<InstantiationSet> performResolution(java.util.List<InferenceVariable> variablesToResolve, com.github.javaparser.resolution.TypeSolver typeSolver)
Examines the bounds on an inference variable and determines an instantiation that is compatible with those bounds. It also decides the order in which interdependent inference variables are to be resolved.
-
getProperUpperBoundsFor
public java.util.List<Bound> getProperUpperBoundsFor(InferenceVariable inferenceVariable)
-
-