Package: org.codehaus.groovy.tools.groovydoc

## [Java] Class SimpleGroovyAnnotationRef

- org.codehaus.groovy.tools.groovydoc.SimpleGroovyAnnotationRef

- All Implemented Interfaces and Traits:
    GroovyAnnotationRef

      public class SimpleGroovyAnnotationRef
      extends Object
      implements GroovyAnnotationRef

  Default GroovyAnnotationRef implementation backed by parsed source text.

- - ### Constructor Summary

    Constructors
    Constructor and description
    `SimpleGroovyAnnotationRef(String name, String desc)` Creates an annotation reference from its simple name and raw source description.

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public String` | `description()` * The string representation of the annotation reference. * Initially implemented as a temporary hack stored from the source. * To be replaced with strong-typed finer grained information. * * Returns: the text representation of the annotation ref
    `` | `public boolean` | `isTypeAvailable()` Indicates whether the annotation type has been resolved.
    `` | `public String` | `name()` * Name of the annotation being referenced. Once resolved, * equates to `type().typeName()`. * * Returns: the name of the annotation reference
    `` | `public void` | `setName(String name)` Replaces the annotation name used by this reference.
    `` | `public void` | `setType(GroovyClassDoc type)` Associates the resolved annotation type with this reference.
    `` | `public GroovyClassDoc` | `type()` * The annotation being referenced. * * Returns: the annotation being referenced

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Object` | `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### public SimpleGroovyAnnotationRef(String name, String desc)

      Creates an annotation reference from its simple name and raw source description.

      Parameters:
        `name` - the annotation name
        `desc` - the raw source description of the annotation

  - ### Method Detail

    - #### public String description()

      * The string representation of the annotation reference. * Initially implemented as a temporary hack stored from the source. * To be replaced with strong-typed finer grained information. * *

      Returns:
        the text representation of the annotation ref

    - #### public boolean isTypeAvailable()

      Indicates whether the annotation type has been resolved.

      Returns:
        `true` if the annotation type is available

    - #### public String name()

      * Name of the annotation being referenced. Once resolved, * equates to `type().typeName()`. * *

      Returns:
        the name of the annotation reference

    - #### public void setName(String name)

      Replaces the annotation name used by this reference.

      Parameters:
        `name` - the annotation name to store

    - #### public void setType(GroovyClassDoc type)

      Associates the resolved annotation type with this reference.

      Parameters:
        `type` - the resolved annotation type

    - #### public GroovyClassDoc type()

      * The annotation being referenced. * *

      Returns:
        the annotation being referenced