com.stvconsultants.easygloss.javaee
Class GlossInjectionProvider

java.lang.Object
  extended by com.stvconsultants.easygloss.javaee.GlossInjectionProvider
All Implemented Interfaces:
InjectionProvider

public class GlossInjectionProvider
extends java.lang.Object
implements InjectionProvider

An implementation of Java Server Faces 1.2 InjectionProvider in order to support testing JSF applications.

Author:
STV Consultants

Constructor Summary
GlossInjectionProvider()
           
 
Method Summary
static void clearInjection()
          Removes all gloss from injection.
 void inject(java.lang.Object managedBean)
          The implementation of this method must perform the following steps: Inject the supported resources per the Servlet 2.5 specification into the provided object Inoke any method marked with the @PostConstruct annotation (per the Common Annotations Specification)
 void invokePreDestroy(java.lang.Object managedBean)
          The implemenation of this method must invoke any method marked with the @PreDestroy annotation (per the Common Annotations Specification).
static void setInjection(JavaEEGloss gloss)
          Sets a new gloss to apply.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GlossInjectionProvider

public GlossInjectionProvider()
Method Detail

inject

public void inject(java.lang.Object managedBean)
            throws InjectionProviderException

The implementation of this method must perform the following steps:

Specified by:
inject in interface InjectionProvider
Parameters:
managedBean - the target managed bean
Throws:
InjectionProviderException - if an error occurs during resource injection

invokePreDestroy

public void invokePreDestroy(java.lang.Object managedBean)
                      throws InjectionProviderException

The implemenation of this method must invoke any method marked with the @PreDestroy annotation (per the Common Annotations Specification).

Specified by:
invokePreDestroy in interface InjectionProvider
Parameters:
managedBean - the target managed bean
Throws:
InjectionProviderException - if an error occurs when invoking the method annotated by the @PreDestroy annotation

clearInjection

public static void clearInjection()
Removes all gloss from injection.


setInjection

public static void setInjection(JavaEEGloss gloss)
Sets a new gloss to apply.

Parameters:
gloss - the new gloss to apply.


Copyright © 2006 null. All Rights Reserved.