|
Nuxeo ECM Projects 5.4.3-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.nuxeo.ecm.platform.ui.web.util.SeamComponentCallHelper
public final class SeamComponentCallHelper
This class provides helper methods for accessing a Seam Component
Why this class?
At startup time, Seam generates CGLib Wrappers around each Seam component. This wrapper holds all interceptors that are used for bijection. Because of that, accessing a Seam component by its reference will lead to call a disinjected instance (all @In member variables are null).
Seam components are usually accessed via EL or via injected references, in this cases, Seam takes care of everything and you get a functional instance. But in some cases, you need to access a Seam component:
Method Summary | |
---|---|
static Object |
callSeamComponentByName(String seamName,
String methodName,
Object param)
Calls a Seam component by name. |
static Object |
callSeamComponentByName(String seamName,
String methodName,
Object[] params)
Calls a Seam component by name. |
static Object |
callSeamComponentByRef(Object seamRef,
String methodName,
Object param)
Calls a Seam component by reference. |
static Object |
callSeamComponentByRef(Object seamRef,
String methodName,
Object[] params)
Calls a Seam component by reference. |
static Object |
getSeamComponentByName(String seamName)
Gets the CGLib-wrapped Seam component from its name. |
static Object |
getSeamComponentByRef(Object seamRef)
Gets the CGLib-wrapped Seam component from a reference. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static Object getSeamComponentByName(String seamName)
seamName
- the name of the Seam component
public static Object getSeamComponentByRef(Object seamRef)
seamRef
- reference of the object behind the Seam component
public static Object callSeamComponentByName(String seamName, String methodName, Object[] params)
seamName
- the name of the Seam componentmethodName
- the method name (for ejb3 method must be exposed in the local
interface)params
- parameters as Object[]
RuntimeException
public static Object callSeamComponentByRef(Object seamRef, String methodName, Object[] params)
seamRef
- the reference on the object behind the Seam componentmethodName
- the method name (for ejb3 method must be exposed in the local
interface)params
- parameters as Object[]
RuntimeException
public static Object callSeamComponentByRef(Object seamRef, String methodName, Object param)
seamRef
- the reference on the object behind the Seam componentmethodName
- the method name (for ejb3 method must be exposed in the local
interface)param
- parameter as Object
RuntimeException
public static Object callSeamComponentByName(String seamName, String methodName, Object param)
seamName
- the name of the Seam componentmethodName
- the method name (for ejb3 method must be exposed in the local
interface)param
- parameters as Object[]
RuntimeException
|
Nuxeo ECM Projects 5.4.3-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |