public class WildcardRef extends TypeRef
| Modifier and Type | Class and Description |
|---|---|
static class |
WildcardRef.BoundKind |
AT, CB, CC, CLP, COLN, COMA, CP, DOT, DQ, EMPTY, EQ, EXTENDS, GT, IMPLEMENTS, INDENT, JAVA_LANG, JAVA_LANG_ENUM, JAVA_LANG_OBJECT, JAVA_LANG_STRING, LT, NEWLINE, NEWLINE_PATTERN, OB, OC, OP, Q, SEMICOLN, SEMICOLN_SUFFIX_PATTERN, SPACE, STAR, THROWS, VARARGALSO_IMPORT, DEFAULT_VALUE, INIT, INIT_FUNCTION, LAZY_INIT| Constructor and Description |
|---|
WildcardRef() |
WildcardRef(WildcardRef.BoundKind boundKind,
List<TypeRef> bounds,
Map<AttributeKey,Object> attributes) |
| Modifier and Type | Method and Description |
|---|---|
WildcardRef.BoundKind |
getBoundKind() |
List<TypeRef> |
getBounds() |
int |
getDimensions() |
String |
getName() |
String |
render()
Render the type into a
String for the purpose of code generation. |
String |
toString() |
TypeRef |
withDimensions(int dimensions) |
getAttribute, getAttributes, hasAttributeclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitnoSemicolon, tabpublic WildcardRef()
public WildcardRef(WildcardRef.BoundKind boundKind, List<TypeRef> bounds, Map<AttributeKey,Object> attributes)
public WildcardRef.BoundKind getBoundKind()
public int getDimensions()
getDimensions in class TypeRefpublic TypeRef withDimensions(int dimensions)
withDimensions in class TypeRefpublic String render()
RenderableString for the purpose of code generation.
This is slightly different from the `toString()` method as `toString()` is mostly needed for logging / debugging and should
be idempotent.
Regarding idempotency this method may yield different result based on the context it is used even if the internal state of
the object does not change.
An example of such case, is a reference to class that may change based on the package from which it's refenced.String representation of the object as it's meant to appear in the generated code.Copyright © 2023. All rights reserved.