org.ow2.bonita.util
Class AccessorUtil

java.lang.Object
  extended by org.ow2.bonita.util.AccessorUtil

public final class AccessorUtil
extends java.lang.Object

This utility class has been provided to unify access to Bonita APIs and to avoid the use of lookups in JEE deployments: org.ow2.bonita.util.AccessorUtil.
Through this class, Nova Bonita APIs can be reached in a unified way in both local and remote applications.
For that to be done, the system property called "org.ow2.bonita.api-type" must be defined at client side to specify whether the APIs will be reached locally or remotely
(possible values are "standard", "auto-detect", "ejb2" and "ejb3").


Field Summary
static java.lang.String API_TYPE_PROPERTY
           
static java.lang.String COMMANDAPI_JNDINAME
           
protected static java.lang.ThreadLocal<Context> CONTEXT
           
static java.lang.String DEFINITIONAPI_JNDINAME
           
static java.lang.String MANAGEMENT_JNDINAME
           
static java.lang.String QUERYDEFINITION_JNDINAME
           
static java.lang.String QUERYRUNTIME_JNDINAME
           
static java.lang.String RUNTIMEAPI_JNDINAME
           
 
Method Summary
static org.ow2.bonita.facade.APIAccessor getAPIAccessor()
          To get the APIAccessor interface.
static org.ow2.bonita.facade.APIAccessor getAPIAccessor(java.util.Hashtable<java.lang.String,java.lang.String> jndiEnvironment)
           
static org.ow2.bonita.facade.CommandAPI getCommandAPI()
          To get the CommandAPI interface.
static org.ow2.bonita.facade.ManagementAPI getManagementAPI()
          To get the ManagementAPI interface.
static org.ow2.bonita.facade.QueryAPIAccessor getQueryAPIAccessor()
          To get the QueryAPIAccessor interface.
static org.ow2.bonita.facade.QueryAPIAccessor getQueryAPIAccessor(java.util.Hashtable<java.lang.String,java.lang.String> jndiEnvironment)
           
static org.ow2.bonita.facade.QueryDefinitionAPI getQueryDefinitionAPI()
          To get the QueryDefinitionAPI interface.
static org.ow2.bonita.facade.QueryRuntimeAPI getQueryRuntimeAPI()
          To get the QueryRuntimeAPI interface.
static org.ow2.bonita.facade.RuntimeAPI getRuntimeAPI()
          To get the RuntimeAPI interface.
static Context resetContext()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

API_TYPE_PROPERTY

public static final java.lang.String API_TYPE_PROPERTY
See Also:
Constant Field Values

RUNTIMEAPI_JNDINAME

public static final java.lang.String RUNTIMEAPI_JNDINAME
See Also:
Constant Field Values

MANAGEMENT_JNDINAME

public static final java.lang.String MANAGEMENT_JNDINAME
See Also:
Constant Field Values

DEFINITIONAPI_JNDINAME

public static final java.lang.String DEFINITIONAPI_JNDINAME
See Also:
Constant Field Values

QUERYRUNTIME_JNDINAME

public static final java.lang.String QUERYRUNTIME_JNDINAME
See Also:
Constant Field Values

QUERYDEFINITION_JNDINAME

public static final java.lang.String QUERYDEFINITION_JNDINAME
See Also:
Constant Field Values

COMMANDAPI_JNDINAME

public static final java.lang.String COMMANDAPI_JNDINAME
See Also:
Constant Field Values

CONTEXT

protected static final java.lang.ThreadLocal<Context> CONTEXT
Method Detail

resetContext

public static Context resetContext()

getQueryAPIAccessor

public static org.ow2.bonita.facade.QueryAPIAccessor getQueryAPIAccessor(java.util.Hashtable<java.lang.String,java.lang.String> jndiEnvironment)

getAPIAccessor

public static org.ow2.bonita.facade.APIAccessor getAPIAccessor(java.util.Hashtable<java.lang.String,java.lang.String> jndiEnvironment)

getAPIAccessor

public static org.ow2.bonita.facade.APIAccessor getAPIAccessor()
To get the APIAccessor interface.

Returns:
the interface APIAccessor.

getQueryAPIAccessor

public static org.ow2.bonita.facade.QueryAPIAccessor getQueryAPIAccessor()
To get the QueryAPIAccessor interface.

Returns:
the interface QueryAPIAccessor.

getRuntimeAPI

public static org.ow2.bonita.facade.RuntimeAPI getRuntimeAPI()
To get the RuntimeAPI interface.

Returns:
the interface RuntimeAPI.

getManagementAPI

public static org.ow2.bonita.facade.ManagementAPI getManagementAPI()
To get the ManagementAPI interface.

Returns:
the interface ManagementAPI.

getCommandAPI

public static org.ow2.bonita.facade.CommandAPI getCommandAPI()
To get the CommandAPI interface.

Returns:
the interface CommandAPI.

getQueryRuntimeAPI

public static org.ow2.bonita.facade.QueryRuntimeAPI getQueryRuntimeAPI()
To get the QueryRuntimeAPI interface.

Returns:
the interface QueryRuntimeAPI.

getQueryDefinitionAPI

public static org.ow2.bonita.facade.QueryDefinitionAPI getQueryDefinitionAPI()
To get the QueryDefinitionAPI interface.

Returns:
the interface QueryDefinitionAPI.


Copyright © 2009 OW2 Consortium. All Rights Reserved.