Uses of Class
com.google.errorprone.refaster.Choice
Packages that use Choice
-
Uses of Choice in com.google.errorprone.refaster
Methods in com.google.errorprone.refaster that return ChoiceModifier and TypeMethodDescriptionstatic <T> Choice<T>
Choice.any
(Collection<Choice<T>> choices) Returns a choice between any of the options from any of the specified choices.Choice.condition
(boolean condition) Returns this choice ifcondition
, otherwise the empty choice.static <T> Choice<T>
Choice.condition
(boolean condition, T t) Returns aChoice
witht
as an option ifcondition
, and no options otherwise.Filters the choices to those that satisfy the providedPredicate
.UAnyOf.defaultAction
(com.sun.source.tree.Tree tree, Unifier unifier) UFreeIdent.defaultAction
(com.sun.source.tree.Tree target, Unifier unifier) UPlaceholderExpression.defaultAction
(com.sun.source.tree.Tree node, Unifier unifier) UStaticIdent.defaultAction
(com.sun.source.tree.Tree node, Unifier unifier) UTree.defaultAction
(com.sun.source.tree.Tree node, Unifier unifier) static <T> Choice<T>
Choice.from
(Collection<T> choices) static <T> Choice<T>
Choice.fromOptional
(com.google.common.base.Optional<T> optional) Returns a choice of the optional value, if it is present, or the empty choice if it is absent.static <T> Choice<T>
Choice.none()
The emptyChoice
.static <T> Choice<T>
Choice.of
(T t) Returns aChoice
with only one option,t
.Returns a choice of the options from thisChoice
or fromother
.<R> Choice<R>
Choice.thenChoose
(com.google.common.base.Function<? super T, Choice<R>> function) Returns all the choices obtained by choosing from thisChoice
and then choosing from theChoice
yielded by this function on the result.<R> Choice<R>
Choice.thenOption
(com.google.common.base.Function<? super T, com.google.common.base.Optional<R>> function) Returns all the choices obtained by choosing from thisChoice
and yielding a presentOptional
.<R> Choice<R>
Maps the choices with the specified function.Returns all valid unification paths (if any) from thisUnifier
that unify this withtarget
.Returns all successful unification paths from the specifiedUnifier
unifying the specified lists, disallowing varargs.Unifier.unifyList
(Unifier unifier, List<U> toUnify, List<? extends T> targets, boolean allowVarargs) Returns all successful unification paths from the specifiedUnifier
unifying the specified lists, allowing varargs if and only ifallowVarargs
is true.Unifier.unifyNullable
(Unifier unifier, U unifiable, T target) UClassType.visitClassType
(com.sun.tools.javac.code.Type.ClassType classType, Unifier unifier) UIntersectionClassType.visitClassType
(com.sun.tools.javac.code.Type.ClassType t, Unifier unifier) UForAll.visitForAll
(com.sun.tools.javac.code.Type.ForAll target, Unifier unifier) UFreeIdent.visitIdentifier
(com.sun.source.tree.IdentifierTree node, Unifier unifier) UMemberSelect.visitIdentifier
(com.sun.source.tree.IdentifierTree ident, Unifier unifier) ULiteral.visitLiteral
(com.sun.source.tree.LiteralTree literal, Unifier unifier) UMemberSelect.visitMemberSelect
(com.sun.source.tree.MemberSelectTree fieldAccess, Unifier unifier) UMethodInvocation.visitMethodInvocation
(com.sun.source.tree.MethodInvocationTree methodInvocation, Unifier unifier) UMethodType.visitMethodType
(com.sun.tools.javac.code.Type.MethodType methodTy, Unifier unifier) UReturn.visitReturn
(com.sun.source.tree.ReturnTree ret, Unifier unifier) UVariableDecl.visitVariable
(com.sun.source.tree.VariableTree decl, Unifier unifier) Methods in com.google.errorprone.refaster that return types with arguments of type ChoiceModifier and TypeMethodDescriptionUnifier.unifications
(List<U> toUnify, List<? extends T> targets) Unifier.unifications
(List<U> toUnify, List<? extends T> targets, boolean allowVarargs) Unifier.unifications
(U unifiable, T target) Methods in com.google.errorprone.refaster with parameters of type ChoiceModifier and TypeMethodDescriptionReturns a choice of the options from thisChoice
or fromother
.Method parameters in com.google.errorprone.refaster with type arguments of type ChoiceModifier and TypeMethodDescriptionstatic <T> Choice<T>
Choice.any
(Collection<Choice<T>> choices) Returns a choice between any of the options from any of the specified choices.<R> Choice<R>
Choice.thenChoose
(com.google.common.base.Function<? super T, Choice<R>> function) Returns all the choices obtained by choosing from thisChoice
and then choosing from theChoice
yielded by this function on the result.