public class DefaultAnnotationFormatter extends java.lang.Object implements AnnotationFormatter
Constructor and Description |
---|
DefaultAnnotationFormatter() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
formatAnnotationMirror(javax.lang.model.element.AnnotationMirror anno)
Converts an individual annotation mirror into a String
|
protected void |
formatAnnotationMirror(javax.lang.model.element.AnnotationMirror am,
java.lang.StringBuilder sb)
A helper method to output a single AnnotationMirror, without showing full package names.
|
protected void |
formatAnnotationMirrorArg(javax.lang.model.element.AnnotationValue av,
java.lang.StringBuilder sb) |
java.lang.String |
formatAnnotationString(java.util.Collection<? extends javax.lang.model.element.AnnotationMirror> annos,
boolean printInvisible)
Creates a space String of each annotation in annos separated by a single space character,
obeying the printInvisible parameter.
|
static boolean |
isInvisibleQualified(javax.lang.model.element.AnnotationMirror anno)
Returns true if, by default, anno should not be printed
|
public static boolean isInvisibleQualified(javax.lang.model.element.AnnotationMirror anno)
InvisibleQualifier
@SideEffectFree public java.lang.String formatAnnotationString(java.util.Collection<? extends javax.lang.model.element.AnnotationMirror> annos, boolean printInvisible)
formatAnnotationString
in interface AnnotationFormatter
annos
- a collection of annotations to printprintInvisible
- whether or not to print "invisible" annotation mirrorsInvisibleQualifier
@SideEffectFree public java.lang.String formatAnnotationMirror(javax.lang.model.element.AnnotationMirror anno)
AnnotationFormatter
formatAnnotationMirror
in interface AnnotationFormatter
anno
- the annotation mirror to convertprotected void formatAnnotationMirror(javax.lang.model.element.AnnotationMirror am, java.lang.StringBuilder sb)
protected void formatAnnotationMirrorArg(javax.lang.model.element.AnnotationValue av, java.lang.StringBuilder sb)