|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface BeanLock
BeanLock interface
Revisions:
2001/07/29: marcf
20010802: marcf
Method Summary | |
---|---|
void |
addRef()
Increment the reference count of this lock. |
void |
endInvocation(Invocation mi)
Callback to the BeanLock to inform it that a method invocation has ended. |
void |
endTransaction(Transaction tx)
Informs the lock that the given transaction has ended. |
Object |
getId()
Get the bean instance cache id for the bean we are locking for. |
int |
getRefs()
Get the current reference count of this lock. |
Transaction |
getTransaction()
Get the transaction currently associated with this lock. |
void |
releaseSync()
Release exclusive access to this lock instance. |
void |
removeRef()
Decrement the reference count of this lock. |
void |
schedule(Invocation mi)
This method implements the actual logic of the lock. |
void |
setContainer(Container container)
set the ejb container of this lock. |
void |
setId(Object id)
Set the bean instance cache id for the bean we are locking for. |
void |
setTimeout(int timeout)
Change long we should wait for a lock. |
void |
setTransaction(Transaction tx)
Set the transaction currently associated with this lock. |
void |
sync()
Obtain exclusive access to this lock instance. |
void |
wontSynchronize(Transaction tx)
Signifies to the lock that the transaction will not Synchronize (Tx demarcation not seen). |
Method Detail |
---|
Object getId()
void setId(Object id)
id
- The cache key for the bean instance we are locking for.void setTimeout(int timeout)
void setContainer(Container container)
void sync()
void releaseSync()
void schedule(Invocation mi) throws Exception
mi
- The method invocation that needs a lock.
Exception
void setTransaction(Transaction tx)
tx
- The transaction to associate with this lock.Transaction getTransaction()
null
if no transaction is currently
associated with this lock.void endTransaction(Transaction tx)
tx
- The transaction that has ended.void wontSynchronize(Transaction tx)
OSH: This method does not seem to be called from anywhere. What is it meant for? To be called on a timeout before the transaction has terminated?
void endInvocation(Invocation mi)
void addRef()
void removeRef()
int getRefs()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |