Condition
object associated with synchronizers.
An ownable synchronizer is
a synchronizer that may be exclusively owned by a thread and uses
AbstractOwnableSynchronizer
(or its subclass) to implement its synchronization property.
ReentrantLock and the write-lock (but not
the read-lock) of ReentrantReadWriteLock are
two examples of ownable synchronizers provided by the platform.
LockInfo is mapped to a CompositeData
as specified in the from method.
java.util.concurrent.locks.AbstractOwnableSynchronizer , java.util.concurrent.locks.Condition
| Modifier and Type | Field and Description |
|---|---|
| private String | |
| private int |
| Access | Constructor and Description |
|---|---|
| public | LockInfo(String
the fully qualified name of the class of the lock object. className, int the identityHashCode)identity hash code of the lock object.Constructs a |
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public static LockInfo | Returns: aLockInfo object represented
by cd if cd is not null;
null otherwise.CompositeData representing a LockInfoReturns a |
| public String | Returns: the fully qualified name of the class of the lock object.Returns the fully qualified name of the class of the lock object. |
| public int | Returns: the identity hash code of the lock object.Returns the identity hash code of the lock object
returned from the |
| public String | Returns: the string representation of a lock.Overrides java. Returns a string representation of a lock. |
| className | back to summary |
|---|---|
| private String className | |
| identityHashCode | back to summary |
|---|---|
| private int identityHashCode | |
| LockInfo | back to summary |
|---|---|
| public LockInfo(String className, int identityHashCode) Constructs a
| |
| LockInfo | back to summary |
|---|---|
| pack-priv LockInfo(Object lock) package-private constructors | |
| from | back to summary | ||||||
|---|---|---|---|---|---|---|---|
| public static LockInfo from(CompositeData cd) Returns a
| |||||||
| getClassName | back to summary |
|---|---|
| public String getClassName() Returns the fully qualified name of the class of the lock object.
| |
| getIdentityHashCode | back to summary |
|---|---|
| public int getIdentityHashCode() Returns the identity hash code of the lock object
returned from the
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns a string representation of a lock. The returned string representation consists of the name of the class of the lock object, the at-sign character `@', and the unsigned hexadecimal representation of the identity hash code of the object. This method returns a string equals to the value of: wherelock.getClass().getName() + '@' + Integer.toHexString(System.identityHashCode(lock)) lock is the lock object.
| |