public class TypeStringifier extends SimpleTypeVisitor8<String,UnaryOperator<String>>
TypeStringifier converts TypeMirrors into Strings while also applying
an unary operation, such as shortening fully qualified package names.
TODO: this class was added but then turned out to be unnecessary when its functionality was
integrated into the TypeConverter; for now, it is left in the code base as a
nice example for leveraging the SimpleTypeVisitor8, but it should be removed
if it turns out that will not be needed ever againDEFAULT_VALUE| Constructor and Description |
|---|
TypeStringifier(Types types)
Creates a new
TypeStringifier. |
| Modifier and Type | Method and Description |
|---|---|
protected String |
defaultAction(TypeMirror type,
UnaryOperator<String> parameter) |
String |
visitDeclared(DeclaredType type,
UnaryOperator<String> parameter) |
String |
visitWildcard(WildcardType wildcard,
UnaryOperator<String> parameter) |
visitIntersectionvisitUnionvisitArray, visitError, visitExecutable, visitNoType, visitNull, visitPrimitive, visitTypeVariablevisit, visit, visitUnknownpublic TypeStringifier(Types types)
TypeStringifier.types - type utilities, mainly used for creating raw typesprotected String defaultAction(TypeMirror type, UnaryOperator<String> parameter)
defaultAction in class SimpleTypeVisitor6<String,UnaryOperator<String>>public String visitDeclared(DeclaredType type, UnaryOperator<String> parameter)
visitDeclared in interface TypeVisitor<String,UnaryOperator<String>>visitDeclared in class SimpleTypeVisitor6<String,UnaryOperator<String>>public String visitWildcard(WildcardType wildcard, UnaryOperator<String> parameter)
visitWildcard in interface TypeVisitor<String,UnaryOperator<String>>visitWildcard in class SimpleTypeVisitor6<String,UnaryOperator<String>>Copyright © 2024. All rights reserved.