Class TemplateTypeMap
- java.lang.Object
-
- com.google.javascript.rhino.jstype.TemplateTypeMap
-
- All Implemented Interfaces:
java.io.Serializable
public class TemplateTypeMap extends java.lang.Object implements java.io.SerializableManages a mapping from TemplateType to its resolved JSType. Provides utility methods for cloning/extending the map.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancheckEquivalenceHelper(TemplateTypeMap that, com.google.javascript.rhino.jstype.EquivalenceMethod eqMethod)Determines if this map and the specified map have equivalent template types.com.google.common.collect.ImmutableList<TemplateType>getTemplateKeys()Returns a list of all template keys.JSTypegetTemplateType(TemplateType key)Returns the JSType value associated with the specified template key.TemplateTypegetTemplateTypeKeyByName(java.lang.String keyName)booleanhasTemplateKey(TemplateType templateKey)Returns true if this map contains the specified template key, false otherwise.booleanhasTemplateType(TemplateType key)Returns true if there is a JSType value associated with the specified template key; false otherwise.
-
-
-
Method Detail
-
getTemplateKeys
public com.google.common.collect.ImmutableList<TemplateType> getTemplateKeys()
Returns a list of all template keys.
-
hasTemplateKey
public boolean hasTemplateKey(TemplateType templateKey)
Returns true if this map contains the specified template key, false otherwise.
-
hasTemplateType
public boolean hasTemplateType(TemplateType key)
Returns true if there is a JSType value associated with the specified template key; false otherwise.
-
getTemplateType
public JSType getTemplateType(TemplateType key)
Returns the JSType value associated with the specified template key. If no JSType value is associated, returns UNKNOWN_TYPE.
-
getTemplateTypeKeyByName
public TemplateType getTemplateTypeKeyByName(java.lang.String keyName)
-
checkEquivalenceHelper
public boolean checkEquivalenceHelper(TemplateTypeMap that, com.google.javascript.rhino.jstype.EquivalenceMethod eqMethod)
Determines if this map and the specified map have equivalent template types.
-
-