Package com.google.javascript.rhino.jstype

# Interface Visitor<T>

All Known Implementing Classes:
  `ModificationVisitor`

public interface Visitor<T>
A type visitor.

This code will calculate a specific value of type `T` from a type based on its structure:

    JSType type = …;
     T value = type.visit(new Visitor<T>() {
       …
     });

## Method Summary

Modifier and Type
Method
Description
`T`
`caseAllType()`
All type's case.
`T`
`caseBooleanType()`
Boolean value type's case.
`T`
`caseEnumElementType(EnumElementType type)`
Enum element type's case.
`T`
`caseFunctionType(FunctionType type)`
Function type's case.
`T`
`caseNoObjectType()`
Bottom Object type's case.
`T`
`caseNoType()`
Bottom type's case.
`T`
`caseNullType()`
Null type's case.
`T`
`caseNumberType()`
Number value type's case.
`T`
`caseObjectType(ObjectType type)`
Object type's case.
`T`
`caseStringType()`
String value type's case.
`T`
`caseTemplateType(TemplateType templateType)`
Template type's case.
`T`
`caseTemplatizedType(TemplatizedType type)`
Templatized type's case.
`T`
`caseUnionType(UnionType type)`
Union type's case.
`T`
`caseUnknownType()`
Unknown type's case.
`T`
`caseVoidType()`
Void type's case.

## Method Details

### caseNoType

T caseNoType()
Bottom type's case.

### caseEnumElementType

T caseEnumElementType(EnumElementType type)
Enum element type's case.

### caseAllType

T caseAllType()
All type's case.

### caseBooleanType

T caseBooleanType()
Boolean value type's case.

### caseNoObjectType

T caseNoObjectType()
Bottom Object type's case.

### caseFunctionType

T caseFunctionType(FunctionType type)
Function type's case.

### caseObjectType

T caseObjectType(ObjectType type)
Object type's case.

### caseUnknownType

T caseUnknownType()
Unknown type's case.

### caseNullType

T caseNullType()
Null type's case.

### caseNumberType

T caseNumberType()
Number value type's case.

### caseStringType

T caseStringType()
String value type's case.

### caseVoidType

T caseVoidType()
Void type's case.

### caseUnionType

T caseUnionType(UnionType type)
Union type's case.

### caseTemplatizedType

T caseTemplatizedType(TemplatizedType type)
Templatized type's case.

### caseTemplateType

T caseTemplateType(TemplateType templateType)
Template type's case.