private abstract static class MasterProcedureScheduler.Queue<TKey extends Comparable<TKey>> extends Object implements MasterProcedureScheduler.QueueInterface
Modifier and Type | Field and Description |
---|---|
private int |
avlHeight |
private MasterProcedureScheduler.Queue<TKey> |
avlLeft |
private MasterProcedureScheduler.Queue<TKey> |
avlRight |
private long |
exclusiveLockProcIdOwner |
private MasterProcedureScheduler.Queue<TKey> |
iterNext |
private MasterProcedureScheduler.Queue<TKey> |
iterPrev |
private TKey |
key |
private int |
priority |
private int |
sharedLock |
private boolean |
suspended |
Constructor and Description |
---|
MasterProcedureScheduler.Queue(TKey key) |
MasterProcedureScheduler.Queue(TKey key,
int priority) |
Modifier and Type | Method and Description |
---|---|
int |
compareKey(TKey cmpKey) |
int |
compareTo(MasterProcedureScheduler.Queue<TKey> other) |
protected TKey |
getKey() |
protected int |
getPriority() |
boolean |
hasExclusiveLock() |
boolean |
isAvailable() |
boolean |
isLocked() |
protected boolean |
isSingleSharedLock() |
boolean |
isSuspended()
True if the queue is not in the run-queue and it is owned by an event.
|
void |
releaseExclusiveLock() |
void |
releaseSharedLock() |
protected boolean |
setSuspended(boolean isSuspended) |
String |
toString() |
boolean |
tryExclusiveLock(long procIdOwner) |
boolean |
trySharedLock() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
add, isEmpty, peek, poll, requireExclusiveLock, size
private MasterProcedureScheduler.Queue<TKey extends Comparable<TKey>> avlRight
private MasterProcedureScheduler.Queue<TKey extends Comparable<TKey>> avlLeft
private int avlHeight
private MasterProcedureScheduler.Queue<TKey extends Comparable<TKey>> iterNext
private MasterProcedureScheduler.Queue<TKey extends Comparable<TKey>> iterPrev
private boolean suspended
private long exclusiveLockProcIdOwner
private int sharedLock
private final TKey extends Comparable<TKey> key
private final int priority
public MasterProcedureScheduler.Queue(TKey key)
public MasterProcedureScheduler.Queue(TKey key, int priority)
protected TKey getKey()
protected int getPriority()
public boolean isSuspended()
isSuspended
in interface MasterProcedureScheduler.QueueInterface
protected boolean setSuspended(boolean isSuspended)
public boolean isLocked()
public boolean hasExclusiveLock()
public boolean trySharedLock()
public void releaseSharedLock()
protected boolean isSingleSharedLock()
public boolean tryExclusiveLock(long procIdOwner)
public void releaseExclusiveLock()
public boolean isAvailable()
isAvailable
in interface MasterProcedureScheduler.QueueInterface
public int compareKey(TKey cmpKey)
public int compareTo(MasterProcedureScheduler.Queue<TKey> other)
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.