public enum TypeMatchingStrategy extends Enum<TypeMatchingStrategy>
JSType
of nodes.Modifier and Type | Class and Description |
---|---|
static class |
TypeMatchingStrategy.MatchResult
The result of comparing two different
JSType instances. |
Enum Constant and Description |
---|
DEFAULT
Matches type or any subtype.
|
EXACT
Does not match subtypes.
|
STRICT_NULLABILITY
Matches type or any subtype.
|
Modifier and Type | Method and Description |
---|---|
TypeMatchingStrategy.MatchResult |
match(JSType templateType,
JSType type) |
static TypeMatchingStrategy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TypeMatchingStrategy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final TypeMatchingStrategy DEFAULT
public static final TypeMatchingStrategy STRICT_NULLABILITY
public static final TypeMatchingStrategy EXACT
public static TypeMatchingStrategy[] values()
for (TypeMatchingStrategy c : TypeMatchingStrategy.values()) System.out.println(c);
public static TypeMatchingStrategy valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic TypeMatchingStrategy.MatchResult match(JSType templateType, JSType type)
Copyright © 2009–2023 Google. All rights reserved.