Class DefaultTenantAccess
java.lang.Object
org.eclnt.jsfserver.util.useraccess.DefaultTenantAccess
- All Implemented Interfaces:
ITenantAccess
Default implementation of
The tenant that is currently active is either passed via
If there is no http session available then the tenant may also be passed by
ITenantAccess
.
The tenant that is currently active is either passed via
associateTenantWithCurrentSession(String)
. Internally
this tenant information is stored in the http session.
If there is no http session available then the tenant may also be passed by
associateTenantWithCurrentThread(String)
.-
Field Summary
Fields inherited from interface org.eclnt.jsfserver.util.useraccess.ITenantAccess
TENANT_UNDEFINED
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Passes the tenant into the current session.static void
associateTenantWithCurrentSession
(javax.servlet.http.HttpServletRequest request, String tenant) Passes the tenant into the current session.static void
static void
static void
Get tenant that is associated with the current context.getCurrentTenant
(javax.faces.context.FacesContext context)
-
Constructor Details
-
DefaultTenantAccess
public DefaultTenantAccess()
-
-
Method Details
-
getCurrentTenant
-
getCurrentTenant
Description copied from interface:ITenantAccess
Get tenant that is associated with the current context.- Specified by:
getCurrentTenant
in interfaceITenantAccess
-
associateTenantWithCurrentSession
Passes the tenant into the current session.
This method is the normal one to be used within your application processing (i.e. running within the CC-/JSF-context). If you want to pass the tenant from some servlet-filter processing use#associateTenantWithSession(HttpServletRequest, String)
. -
associateTenantWithCurrentSession
public static void associateTenantWithCurrentSession(javax.servlet.http.HttpServletRequest request, String tenant) Passes the tenant into the current session.
Special implementation to be used from servlet-filters which are arranged in front of the CC filter processing (ThreadingFilter). -
clearTenantWithCurrentSession
public static void clearTenantWithCurrentSession() -
associateTenantWithCurrentThread
-
clearTenantWithCurrentThread
public static void clearTenantWithCurrentThread()
-