Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Apache CXF API
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cxf.common.injection
Class ResourceInjector

    java.lang.Object
      org.apache.cxf.common.annotation.AbstractAnnotationVisitor
          org.apache.cxf.common.injection.ResourceInjector

All Implemented Interfaces:
  AnnotationVisitor

    public class ResourceInjector

extends AbstractAnnotationVisitor

injects references specified using @Resource annotation

Field Summary

Fields inherited from class org.apache.cxf.common.annotation.AbstractAnnotationVisitor
`target, targetClass`

Constructor Summary
`ResourceInjector(ResourceManager resMgr)`
`ResourceInjector(ResourceManager resMgr, List<ResourceResolver> resolvers)`

Method Summary
`void` | `construct(Object o)`
`void` | `construct(Object o, Class<?> cls)`
`void` | `destroy(Object o)`
`protected Class<?>` | `getResourceType(javax.annotation.Resource res, Field field)` making this protected to keep pmd happy
`void` | `inject(Object o)`
`void` | `inject(Object o, Class<?> claz)`
`void` | `invokePostConstruct()`
`void` | `invokePreDestroy()`
`static boolean` | `processable(Class<?> cls, Object o)`
`void` | `visitClass(Class<?> clz, Annotation annotation)` visit an annotated class.
`void` | `visitField(Field field, Annotation annotation)` visit an annotated field.
`void` | `visitMethod(Method method, Annotation annotation)` visit an annotated method.

Methods inherited from class org.apache.cxf.common.annotation.AbstractAnnotationVisitor
`addTargetAnnotation, getTarget, getTargetAnnotations, getTargetClass, setTarget, setTarget`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ResourceInjector

    public ResourceInjector(ResourceManager resMgr)

### ResourceInjector

    public ResourceInjector(ResourceManager resMgr,
                            List<ResourceResolver> resolvers)

Method Detail

### processable

    public static boolean processable(Class<?> cls,
                                      Object o)

### inject

    public void inject(Object o)

### inject

    public void inject(Object o,
                       Class<?> claz)

### construct

    public void construct(Object o)

### construct

    public void construct(Object o,
                          Class<?> cls)

### destroy

    public void destroy(Object o)

### visitClass

    public final void visitClass(Class<?> clz,
                                 Annotation annotation)

  Description copied from interface: `AnnotationVisitor`
  visit an annotated class. Invoked when the class of an object is annotated by one of the specified annotations. `visitClass` is called for each of the annotations that matches and for each class.

  Specified by:
    `visitClass` in interface `AnnotationVisitor`
  Overrides:
    `visitClass` in class `AbstractAnnotationVisitor`
  Parameters:
    `clz` - the class with the annotation
    `annotation` - the annotation

### visitField

    public final void visitField(Field field,
                                 Annotation annotation)

  Description copied from interface: `AnnotationVisitor`
  visit an annotated field. Invoked when the field of an object is annotated by one of the specified annotations. `visitField` is called for each of the annotations that matches and for each field.

  Specified by:
    `visitField` in interface `AnnotationVisitor`
  Overrides:
    `visitField` in class `AbstractAnnotationVisitor`
  Parameters:
    `field` - the annotated field
    `annotation` - the annotation

### visitMethod

    public final void visitMethod(Method method,
                                  Annotation annotation)

  Description copied from interface: `AnnotationVisitor`
  visit an annotated method. Invoked when the method of an object is annotated by one of the specified annotations. `visitMethod` is called for each of the annotations that matches and for each method.

  Specified by:
    `visitMethod` in interface `AnnotationVisitor`
  Overrides:
    `visitMethod` in class `AbstractAnnotationVisitor`
  Parameters:
    `method` - the annotated fieldx
    `annotation` - the annotation

### invokePostConstruct

    public void invokePostConstruct()

### invokePreDestroy

    public void invokePreDestroy()

### getResourceType

    protected Class<?> getResourceType(javax.annotation.Resource res,
                                       Field field)

  making this protected to keep pmd happy

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Apache CXF API
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Apache CXF