org.mule.devkit.model.code
Interface Annotable

All Known Implementing Classes:
AnnotationArrayMember, EnumConstant, GeneratedClass, GeneratedField, GeneratedMethod, GeneratedPackage, GeneratedVariable

public interface Annotable

Annotatable program elements.

Author:
Kohsuke Kawaguchi

Method Summary
 GeneratedAnnotationUse annotate(Class<? extends Annotation> clazz)
          Adds an annotation to this program element.
 GeneratedAnnotationUse annotate(TypeReference clazz)
          Adds an annotation to this program element.
<W extends AnnotationWriter>
W
annotate2(Class<W> clazz)
          Adds an annotation to this program element and returns a type-safe writer to fill in the values of such annotations.
 Collection<GeneratedAnnotationUse> annotations()
          Read-only live view of all annotations on this Annotable
 

Method Detail

annotate

GeneratedAnnotationUse annotate(TypeReference clazz)
Adds an annotation to this program element.

Parameters:
clazz - The annotation class to annotate the program element with

annotate

GeneratedAnnotationUse annotate(Class<? extends Annotation> clazz)
Adds an annotation to this program element.

Parameters:
clazz - The annotation class to annotate the program element with

annotate2

<W extends AnnotationWriter> W annotate2(Class<W> clazz)
Adds an annotation to this program element and returns a type-safe writer to fill in the values of such annotations.


annotations

Collection<GeneratedAnnotationUse> annotations()
Read-only live view of all annotations on this Annotable

Returns:
Can be empty but never null.


Copyright © 2010–2015 MuleSoft, Inc.. All rights reserved.