Class AutoBeanVisitor.ParameterizationVisitor
java.lang.Object
com.google.web.bindery.autobean.shared.AutoBeanVisitor.ParameterizationVisitor
- Enclosing class:
AutoBeanVisitor
The ParameterizationVisitor provides access to more complete type
information than a simple class literal can provide.
The order of traversal reflects the declared parameterization of the
property. For example, a Map<String, List<Foo>>
would be traversed
via the following sequence:
visitType(Map.class); visitParameter(); visitType(String.class); endVisitType(String.class); endVisitParameter(); visitParameter(); visitType(List.class); visitParameter(); visitType(Foo.class); endVisitType(Foo.class); endParameter(); endVisitType(List.class); endVisitParameter(); endVisitType(Map.class);
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Called when finished with a type parameter.void
endVisitType
(Class<?> type) Called when finished with a type.boolean
Called when visiting a type parameter.boolean
Called when visiting a possibly parameterized type.
-
Constructor Details
-
ParameterizationVisitor
public ParameterizationVisitor()
-
-
Method Details
-
endVisitParameter
public void endVisitParameter()Called when finished with a type parameter. -
endVisitType
Called when finished with a type.- Parameters:
type
- a Class object
-
visitParameter
public boolean visitParameter()Called when visiting a type parameter.- Returns:
true
if the type parameter should be visited
-
visitType
Called when visiting a possibly parameterized type.- Parameters:
type
- a Class object- Returns:
true
if the type should be visited
-