T - - the return typeprotected abstract class AbstractJMXMBean.TenantAwareExecutor<T>
extends java.lang.Object
Inner tenant aware executor class. This claas deals with the AbstractJMXMBean.activateTenant() and
AbstractJMXMBean.deactivateTenant() calls.
<code>
public Integer getMaxAllowedSize()
{
<b>return</b> new TenantAwareExecutor<Integer>()
{
protected Integer doExecute()
{
<b>return</b> Integer.valueOf(Registry.getCurrentTenant().getCache().getMaxAllowedSize());
}
}.getResult();
}
</code>
| Modifier | Constructor and Description |
|---|---|
protected |
TenantAwareExecutor()
calls
perform() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract T |
doExecute()
The content of this method will run with activated tenant and the tenant will always deactivated afterward.
|
protected Tenant |
getCurrentTenant() |
T |
getResult() |
protected TenantAwareExecutor()
perform()public T getResult()
doExecute() operation.protected final Tenant getCurrentTenant()
protected abstract T doExecute()
Copyright © 2018 SAP SE. All Rights Reserved.