public class LockInfo extends Object
Condition对象与同步器。
An ownable synchronizer是同步器,可以由一个线程只拥有和使用AbstractOwnableSynchronizer(或其子类)来实现其同步性能。ReentrantLock和ReentrantReadWriteLock ownable同步器是通过平台提供的两个例子。
CompositeData在
from方法指定。
AbstractOwnableSynchronizer,
Condition
| Constructor and Description |
|---|
LockInfo(String className, int identityHashCode)
构建了一个
LockInfo对象。
|
| Modifier and Type | Method and Description |
|---|---|
static LockInfo |
from(CompositeData cd)
返回一个给定的
CompositeData代表
LockInfo对象。
|
String |
getClassName()
返回锁定对象的类的完全限定名。
|
int |
getIdentityHashCode()
返回锁对象的身份回来
System.identityHashCode(java.lang.Object)哈希代码的方法。
|
String |
toString()
返回一个锁的字符串表示形式。
|
public LockInfo(String className, int identityHashCode)
className -锁的对象的类的完全限定名。
identityHashCode -锁定对象的
identity hash code。
public String getClassName()
public int getIdentityHashCode()
System.identityHashCode(java.lang.Object)哈希代码的方法。
public static LockInfo from(CompositeData cd)
CompositeData代表
LockInfo对象。给定的
CompositeData必须包含以下属性:
Attribute Name Type className java.lang.String identityHashCode java.lang.Integer
cd -
CompositeData代表
LockInfo
LockInfo对象代表的
cd如果
cd不
null;
null否则。
IllegalArgumentException -如果
cd并不代表上述属性
LockInfo。
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.