org.apache.catalina.util
Class DefaultAnnotationProcessor

java.lang.Object
  extended by org.apache.catalina.util.DefaultAnnotationProcessor
All Implemented Interfaces:
org.apache.AnnotationProcessor

public class DefaultAnnotationProcessor
extends Object
implements org.apache.AnnotationProcessor

Verify the annotation and Process it.

Version:
$Revision: 676391 $, $Date: 2008-07-13 20:20:40 +0200 (Sun, 13 Jul 2008) $
Author:
Fabien Carrion, Remy Maucherat

Field Summary
protected  Context context
           
 
Constructor Summary
DefaultAnnotationProcessor(Context context)
           
 
Method Summary
 org.ow2.util.ee.metadata.common.api.enc.IENCBindingHolder getEncBindingHolder()
           
protected static void lookupFieldResource(Context context, Object instance, Field field, String name, Class<?> clazz)
          Inject resources in specified field.
protected static void lookupMethodResource(Context context, Object instance, Method method, String name, Class<?> clazz)
          Inject resources in specified method.
 void postConstruct(Object instance)
          Call postConstruct method on the specified instance.
 void preDestroy(Object instance)
          Call preDestroy method on the specified instance.
 void processAnnotations(Object instance)
          Inject resources in specified instance.
 void setEncBindingHolder(org.ow2.util.ee.metadata.common.api.enc.IENCBindingHolder encBindingHolder)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

context

protected Context context
Constructor Detail

DefaultAnnotationProcessor

public DefaultAnnotationProcessor(Context context)
Method Detail

postConstruct

public void postConstruct(Object instance)
                   throws IllegalAccessException,
                          InvocationTargetException
Call postConstruct method on the specified instance.

Specified by:
postConstruct in interface org.apache.AnnotationProcessor
Throws:
IllegalAccessException
InvocationTargetException

preDestroy

public void preDestroy(Object instance)
                throws IllegalAccessException,
                       InvocationTargetException
Call preDestroy method on the specified instance.

Specified by:
preDestroy in interface org.apache.AnnotationProcessor
Throws:
IllegalAccessException
InvocationTargetException

processAnnotations

public void processAnnotations(Object instance)
                        throws IllegalAccessException,
                               InvocationTargetException,
                               NamingException
Inject resources in specified instance.

Specified by:
processAnnotations in interface org.apache.AnnotationProcessor
Throws:
IllegalAccessException
InvocationTargetException
NamingException

lookupFieldResource

protected static void lookupFieldResource(Context context,
                                          Object instance,
                                          Field field,
                                          String name,
                                          Class<?> clazz)
                                   throws NamingException,
                                          IllegalAccessException
Inject resources in specified field.

Throws:
NamingException
IllegalAccessException

lookupMethodResource

protected static void lookupMethodResource(Context context,
                                           Object instance,
                                           Method method,
                                           String name,
                                           Class<?> clazz)
                                    throws NamingException,
                                           IllegalAccessException,
                                           InvocationTargetException
Inject resources in specified method.

Throws:
NamingException
IllegalAccessException
InvocationTargetException

setEncBindingHolder

public void setEncBindingHolder(org.ow2.util.ee.metadata.common.api.enc.IENCBindingHolder encBindingHolder)

getEncBindingHolder

public org.ow2.util.ee.metadata.common.api.enc.IENCBindingHolder getEncBindingHolder()


Copyright © 2010 OW2 Consortium. All Rights Reserved.