- All Superinterfaces:
- com.sap.engine.frame.core.locking.LockingConstants, Remote
- public interface LogicalLockingFactory
- extends com.sap.engine.frame.core.locking.LockingConstants, Remote
Gives access to an instance of the LogicalLocking, which
belongs to a specified namespace.
The name, under wich the LogicalLockingFactory is bound in the jndi.
|Fields inherited from interface com.sap.engine.frame.core.locking.LockingConstants
FILL_CHARACTER, LIFETIME_TRANSACTION, LIFETIME_USERSESSION, MAX_ARGUMENT_LENGTH, MAX_NAME_LENGTH, MAX_OWNER_LENGTH, MAX_USER_LENGTH, MODE_EXCLUSIVE_CUMULATIVE, MODE_EXCLUSIVE_NONCUMULATIVE, MODE_OPTIMISTIC, MODE_OPTIMISTIC_TO_EXCLUSIVE, MODE_SHARED, OWNER_WILDCARD_CHARACTER, WILDCARD_CHARACTER_MULTI, WILDCARD_CHARACTER_SINGLE
public static final String JNDI_NAME
- The name, under wich the LogicalLockingFactory is bound in the jndi.
- See Also:
- Constant Field Values
public LogicalLocking createLogicalLocking(String namespace,
- Creates a new instance of the LogicalLocking, which belongs to a given namespace.
The namespace must start with a letter or a digit (see Character.isLetterOrDigit()),
because the other characters are reserved for internal usage. For security-reasons a reserved
namespace can not be released again.
On the other hand a namespace can be reserved multiple times:
if it is reserved again with the same namespace AND the same description,
then this will not cause an error. This is the way how different
applications can share the same locks: the applications must agree on a
namespace and description, and then both can reserve this namespace
(technically the first one is reserving it and the second just takes part).
The created LogicalLocking only(!) identifies the namespace. It does not
identify the user-session or transaction. Those are determined again and again
when calling the methods of the LogicalLocking. So it is possible to use the same
LogicalLocking in different transactions or to use different LogicalLockings
in one transaction. Especially it is no problem to lookup this Factory
and create a LogicalLocking in different places of the logic.
namespace - The namespace, to which this LogicalLocking belongs.
description - A description of this namespace, which can be displayed
in the administration-tools. The description must not be null.
- The created instance of the LogicalLocking.
com.sap.engine.frame.core.locking.TechnicalLockException - if the namespace is already reserved for another description
(reserving it a second time for the same description works)