class Property
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
private static class |
Property.Attribute |
Modifier and Type | Field and Description |
---|---|
private Property.Attribute |
attribute |
private JSType |
declaredType |
private Node |
defSite |
private JSType |
inferredType |
Modifier | Constructor and Description |
---|---|
private |
Property(Node defSite,
JSType inferredType,
JSType declaredType,
Property.Attribute attribute) |
Modifier and Type | Method and Description |
---|---|
java.lang.StringBuilder |
appendTo(java.lang.StringBuilder builder) |
boolean |
equals(java.lang.Object o) |
(package private) JSType |
getDeclaredType() |
(package private) JSType |
getType() |
int |
hashCode() |
(package private) boolean |
isConstant() |
(package private) boolean |
isDeclared() |
(package private) boolean |
isOptional() |
(package private) boolean |
isRequired() |
(package private) static Property |
join(Property p1,
Property p2) |
private static Property.Attribute |
joinAttributes(Property.Attribute a1,
Property.Attribute a2) |
(package private) static Property |
make(JSType inferredType,
JSType declaredType) |
(package private) static Property |
makeConstant(Node defSite,
JSType inferredType,
JSType declaredType) |
(package private) static Property |
makeOptional(Node defSite,
JSType inferredType,
JSType declaredType) |
(package private) static Property |
makeWithDefsite(Node defSite,
JSType inferredType,
JSType declaredType) |
(package private) static Property |
meet(Property p1,
Property p2) |
private static Property.Attribute |
meetAttributes(Property.Attribute a1,
Property.Attribute a2) |
(package private) Property |
specialize(Property other) |
(package private) Property |
substituteGenerics(java.util.Map<java.lang.String,JSType> concreteTypes) |
java.lang.String |
toString() |
(package private) static Property |
unifyUnknowns(Property p1,
Property p2)
Unify the two types bidirectionally, ignoring type variables, but
treating JSType.UNKNOWN as a "hole" to be filled.
|
(package private) boolean |
unifyWithSubtype(Property other,
java.util.List<java.lang.String> typeParameters,
com.google.common.collect.Multimap<java.lang.String,JSType> typeMultimap,
SubtypeCache subSuperMap)
Returns whether unification succeeded
|
(package private) Property |
withOptional() |
(package private) Property |
withRequired() |
private final Node defSite
private final JSType inferredType
private final JSType declaredType
private Property.Attribute attribute
private Property(Node defSite, JSType inferredType, JSType declaredType, Property.Attribute attribute)
static Property makeWithDefsite(Node defSite, JSType inferredType, JSType declaredType)
boolean isRequired()
boolean isOptional()
boolean isConstant()
boolean isDeclared()
JSType getType()
JSType getDeclaredType()
Property withOptional()
Property withRequired()
private static Property.Attribute meetAttributes(Property.Attribute a1, Property.Attribute a2)
private static Property.Attribute joinAttributes(Property.Attribute a1, Property.Attribute a2)
static Property unifyUnknowns(Property p1, Property p2)
boolean unifyWithSubtype(Property other, java.util.List<java.lang.String> typeParameters, com.google.common.collect.Multimap<java.lang.String,JSType> typeMultimap, SubtypeCache subSuperMap)
Property substituteGenerics(java.util.Map<java.lang.String,JSType> concreteTypes)
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.StringBuilder appendTo(java.lang.StringBuilder builder)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object