|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--suncertify.db.util.Semaphore | +--suncertify.db.util.LockObject
This Class represents the lock object - it is supose to know the id of the client owning the lock and has the lock object for others client that wants to wait for the unlock
Constructor Summary | |
LockObject(java.lang.String clientId)
LockObject constructor |
Method Summary | |
boolean |
countingNotify()
Methods notify the internal lock object. |
boolean |
countingNotifyAll()
Methods notify all threads waiting on the internal lock object. |
void |
countingWait()
Methods waits on the internal lock object. |
java.lang.String |
getClientId()
Returns clientId string |
void |
setClientId(java.lang.String string)
Sets the clientId string of the client currently ownig the lock |
Methods inherited from class suncertify.db.util.Semaphore |
P, V |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public LockObject(java.lang.String clientId)
clientId
- - the id of the client who wants to do the lockMethod Detail |
public java.lang.String getClientId()
public void setClientId(java.lang.String string)
string
- - clientIdpublic void countingWait() throws java.lang.InterruptedException
java.lang.InterruptedException
- @see Object#wait()public boolean countingNotify()
public boolean countingNotifyAll()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |