View RSS Feed

Java Object

Annotation Processing

Rate this Entry
by , 04-26-2012 at 05:27 PM (1779 Views)
Uses of advanced annotation comprises of the annotation processor writing that reads the Java program. Actions are taken based at the annotations. Generation of the auxiliary source code takes place that would relieve programmer to create the boilerplate code,that will be following the predictable patterns. 5 of JDK will be released to facilitate this task, which will be including annotation processing tool. When 6 of JDK is released, functionality of apt is the standard part of java compiler.

To make the annotation information available, annotate the annotation type along with
Java Code:
@Retention(RetentionPolicy.RUNTIME) :
import java.lang.annotation.*; 

@Retention(RetentionPolicy.RUNTIME)
@interface AnnotationForRuntime {

   // Elements that give information
   // for runtime processing
   
}

Submit "Annotation Processing" to Facebook Submit "Annotation Processing" to Digg Submit "Annotation Processing" to del.icio.us Submit "Annotation Processing" to StumbleUpon Submit "Annotation Processing" to Google

Categories
Tutorial

Comments