本文整理了Java中com.gemstone.gemfire.internal.cache.locks.QueuedSynchronizer.apparentlyFirstQueuedIsExclusive
方法的一些代码示例,展示了QueuedSynchronizer.apparentlyFirstQueuedIsExclusive
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。QueuedSynchronizer.apparentlyFirstQueuedIsExclusive
方法的具体详情如下:
包路径:com.gemstone.gemfire.internal.cache.locks.QueuedSynchronizer
类名称:QueuedSynchronizer
方法名:apparentlyFirstQueuedIsExclusive
[英]Returns true if the apparent first queued thread, if one exists, is waiting in exclusive mode. If this method returns true, and the current thread is attempting to acquire in shared mode (that is, this method is invoked from TryLockObject#tryAcquireShared) then it is guaranteed that the current thread is not the first queued thread. Used only as a heuristic in ReentrantReadWriteLock.
[中]如果第一个排队线程(如果存在)以独占模式等待,则返回true。如果此方法返回true,并且当前线程正在尝试以共享模式获取(即,此方法从TryLockObject#tryAcquireShared调用),则可以保证当前线程不是第一个排队的线程。仅在ReentranStratedWriteLock中用作启发。
代码示例来源:origin: io.snappydata/gemfirexd
&& this.sync.apparentlyFirstQueuedIsExclusive()) {
return -1;
代码示例来源:origin: io.snappydata/gemfirexd-core
&& this.sync.apparentlyFirstQueuedIsExclusive()) {
return -1;
代码示例来源:origin: io.snappydata/snappydata-store-core
&& this.sync.apparentlyFirstQueuedIsExclusive()) {
return -1;
内容来源于网络,如有侵权,请联系作者删除!