public class OAThreadLocalDelegate extends Object
Modifier and Type | Field and Description |
---|---|
static int |
cntDeadlock |
static HashMap<Object,OAThreadLocal[]> |
hmLock |
protected static ReentrantReadWriteLock |
rwLock |
Constructor and Description |
---|
OAThreadLocalDelegate() |
Modifier and Type | Method and Description |
---|---|
static void |
addHubEvent(HubEvent he) |
static boolean |
addSiblingHelper(OASiblingHelper sh) |
protected static boolean |
addSiblingHelper(OAThreadLocal ti,
OASiblingHelper sh) |
static void |
clearSiblingHelpers() |
static void |
endUndoable() |
protected static void |
endUndoable(OAThreadLocal ti) |
static String |
getAllStackTraces() |
static boolean |
getCreateUndoablePropertyChanges() |
protected static boolean |
getCreateUndoablePropertyChanges(OAThreadLocal ti) |
static HubEvent |
getCurrentHubEvent() |
static int |
getDeadlockCount() |
static int |
getHubListenerTreeCount() |
protected static int |
getHubListenerTreeCount(OAThreadLocal ti) |
static String |
getIgnoreTreeListenerProperty() |
static Object[] |
getLocks() |
static int |
getOASyncEventCount() |
static OAThreadLocal |
getOAThreadLocal() |
static int |
getObjectCacheAddMode() |
protected static int |
getObjectCacheAddMode(OAThreadLocal ti) |
static OAObjectSerializer |
getObjectSerializer()
used by Serialization for the current thread.
|
protected static OAObjectSerializer |
getObjectSerializer(OAThreadLocal ti) |
static HubEvent |
getOldestHubEvent() |
static int |
getRecursiveTriggerCount() |
protected static int |
getRecursiveTriggerCount(OAThreadLocal ti) |
static RequestInfo |
getRemoteRequestInfo() |
static ArrayList<OASiblingHelper> |
getSiblingHelpers() |
static ArrayList<OASiblingHelper> |
getSiblingHelpers(OAThreadLocal ti) |
protected static OAThreadLocal |
getThreadLocal(boolean bCreateIfNull) |
static OATransaction |
getTransaction() |
static boolean |
hasLock() |
static boolean |
hasLock(Object obj) |
static boolean |
hasSentCalcPropertyChange(Hub thisHub,
OAObject thisObj,
String propertyName) |
static boolean |
hasSiblingHelpers() |
static void |
incrOASyncEventCount() |
static boolean |
isDeleting()
Is this thread currently deleting.
|
protected static boolean |
isDeleting(OAThreadLocal ti,
Object obj) |
static boolean |
isDeleting(Object obj)
Is any thread currently deleting an object.
|
static boolean |
isEditQueryEnabled() |
protected static boolean |
isEditQueryEnabled(OAThreadLocal ti) |
protected static boolean |
isFlag(OAThreadLocal ti,
Object obj) |
static boolean |
isFlag(Object obj)
getFlag -----------------------
Flag used for generic/misc purposes
|
static boolean |
isHubMergerChanging() |
protected static boolean |
isHubMergerChanging(OAThreadLocal ti) |
static boolean |
isLoading() |
protected static boolean |
isLoading(OAThreadLocal ti) |
static boolean |
isLocked(Object object) |
static boolean |
isLockOwner(Object object) |
static boolean |
isOpenHubEvent(HubEvent he) |
static boolean |
isSendingEvent() |
protected static boolean |
isSendingEvent(OAThreadLocal ti) |
static boolean |
isSuppressCSMessages() |
static boolean |
isSuppressCSMessages(OAThreadLocal ti) |
static boolean |
isThreadDeleting(Object obj)
Is this thread currently deleting an object/hub.
|
protected static void |
lock(OAThreadLocal tiThis,
Object thisLockObject,
int maxWaitTries) |
static void |
lock(Object object) |
static void |
lock(Object object,
int maxWaitTries)
This locking was created to prevent deadlocks.
|
static void |
notifyWaitingThread() |
static void |
releaseAllLocks() |
protected static void |
removeFlag(OAThreadLocal ti,
Object obj) |
static void |
removeFlag(Object obj) |
static void |
removeHubEvent(HubEvent he) |
static void |
removeSiblingHelper(OASiblingHelper sh) |
protected static void |
removeSiblingHelper(OAThreadLocal ti,
OASiblingHelper sh) |
static void |
setCreateUndoablePropertyChanges(boolean b) |
protected static void |
setCreateUndoablePropertyChanges(OAThreadLocal ti,
boolean b) |
protected static void |
setDeleting(OAThreadLocal ti,
Object obj,
boolean b) |
static void |
setDeleting(Object obj,
boolean b) |
static boolean |
setEnableEditQuery(boolean b) |
protected static boolean |
setEnableEditQuery(OAThreadLocal ti,
boolean b) |
protected static void |
setFlag(OAThreadLocal ti,
Object obj) |
static void |
setFlag(Object obj) |
static void |
setHubListenerTree(boolean b) |
protected static void |
setHubListenerTree(OAThreadLocal ti,
boolean b) |
static void |
setHubMergerIsChanging(boolean b) |
protected static void |
setHubMergerIsChanging(OAThreadLocal ti,
boolean b) |
static void |
setIgnoreTreeListenerProperty(String prop) |
static boolean |
setLoading(boolean b) |
protected static boolean |
setLoading(OAThreadLocal ti,
boolean b) |
static void |
setNotifyObject(Object obj) |
static void |
setObjectCacheAddMode(int mode) |
static void |
setObjectSerializer(OAObjectSerializer si) |
protected static void |
setObjectSerializer(OAThreadLocal ti,
OAObjectSerializer si) |
static void |
setRecursiveTriggerCount(int x) |
protected static void |
setRecursiveTriggerCount(OAThreadLocal ti,
int x) |
static void |
setRemoteRequestInfo(RequestInfo ri) |
static boolean |
setSendMessages(boolean b)
Flag that can be set to allow messages from OARemoteThread to be
sent to other clients/server.
|
static void |
setStatus(String msg) |
static void |
setSuppressCSMessages(boolean b) |
static void |
setSuppressCSMessages(OAThreadLocal ti,
boolean b) |
static void |
setTransaction(OATransaction t)
Called by OATransaction.start()
Used internally by classes that work with the transaction.
|
protected static void |
startUndoable(OAThreadLocal ti,
String compoundName) |
static void |
startUndoable(String compoundName) |
static long |
throttleLOG(String msg,
long msLast) |
protected static void |
unlock(OAThreadLocal ti,
Object object) |
static void |
unlock(Object object) |
public static final HashMap<Object,OAThreadLocal[]> hmLock
protected static ReentrantReadWriteLock rwLock
public static int cntDeadlock
protected static OAThreadLocal getThreadLocal(boolean bCreateIfNull)
public static void setTransaction(OATransaction t)
public static OATransaction getTransaction()
public static boolean isLoading()
OAThreadLocal.loading
protected static boolean isLoading(OAThreadLocal ti)
public static boolean setLoading(boolean b)
protected static boolean setLoading(OAThreadLocal ti, boolean b)
public static int getObjectCacheAddMode()
public static void setObjectCacheAddMode(int mode)
protected static int getObjectCacheAddMode(OAThreadLocal ti)
public static OAObjectSerializer getObjectSerializer()
protected static OAObjectSerializer getObjectSerializer(OAThreadLocal ti)
public static void setObjectSerializer(OAObjectSerializer si)
protected static void setObjectSerializer(OAThreadLocal ti, OAObjectSerializer si)
public static boolean isSuppressCSMessages()
public static boolean isSuppressCSMessages(OAThreadLocal ti)
public static void setSuppressCSMessages(boolean b)
public static void setSuppressCSMessages(OAThreadLocal ti, boolean b)
public static boolean isDeleting()
public static boolean isDeleting(Object obj)
public static boolean isThreadDeleting(Object obj)
protected static boolean isDeleting(OAThreadLocal ti, Object obj)
public static void setDeleting(Object obj, boolean b)
protected static void setDeleting(OAThreadLocal ti, Object obj, boolean b)
public static boolean isFlag(Object obj)
protected static boolean isFlag(OAThreadLocal ti, Object obj)
public static void setFlag(Object obj)
protected static void setFlag(OAThreadLocal ti, Object obj)
public static void removeFlag(Object obj)
protected static void removeFlag(OAThreadLocal ti, Object obj)
public static void lock(Object object, int maxWaitTries)
maxWaitTries
- (default=10) max number of waits (each 50 ms) to wait before taking the lock - 0 to wait
until notified. This will only be used if the current threadLocal has 1+ locks already and object is locked
by another threadLocal.public static void lock(Object object)
public static boolean hasLock()
public static boolean hasLock(Object obj)
public static Object[] getLocks()
public static boolean isLocked(Object object)
public static boolean isLockOwner(Object object)
public static OAThreadLocal getOAThreadLocal()
protected static void lock(OAThreadLocal tiThis, Object thisLockObject, int maxWaitTries)
public static int getDeadlockCount()
public static void releaseAllLocks()
public static void unlock(Object object)
protected static void unlock(OAThreadLocal ti, Object object)
public static boolean isHubMergerChanging()
protected static boolean isHubMergerChanging(OAThreadLocal ti)
public static void setHubMergerIsChanging(boolean b)
protected static void setHubMergerIsChanging(OAThreadLocal ti, boolean b)
public static void setCreateUndoablePropertyChanges(boolean b)
protected static void setCreateUndoablePropertyChanges(OAThreadLocal ti, boolean b)
public static boolean getCreateUndoablePropertyChanges()
protected static boolean getCreateUndoablePropertyChanges(OAThreadLocal ti)
public static void startUndoable(String compoundName)
protected static void startUndoable(OAThreadLocal ti, String compoundName)
public static void endUndoable()
protected static void endUndoable(OAThreadLocal ti)
public static boolean addSiblingHelper(OASiblingHelper sh)
public static void removeSiblingHelper(OASiblingHelper sh)
public static ArrayList<OASiblingHelper> getSiblingHelpers()
public static ArrayList<OASiblingHelper> getSiblingHelpers(OAThreadLocal ti)
public static boolean hasSiblingHelpers()
public static void clearSiblingHelpers()
protected static boolean addSiblingHelper(OAThreadLocal ti, OASiblingHelper sh)
protected static void removeSiblingHelper(OAThreadLocal ti, OASiblingHelper sh)
public static long throttleLOG(String msg, long msLast)
public static String getAllStackTraces()
public static void setStatus(String msg)
public static void setRemoteRequestInfo(RequestInfo ri)
public static RequestInfo getRemoteRequestInfo()
public static boolean setSendMessages(boolean b)
public static void setNotifyObject(Object obj)
public static void notifyWaitingThread()
public static int getRecursiveTriggerCount()
protected static int getRecursiveTriggerCount(OAThreadLocal ti)
public static void setRecursiveTriggerCount(int x)
protected static void setRecursiveTriggerCount(OAThreadLocal ti, int x)
public static int getHubListenerTreeCount()
protected static int getHubListenerTreeCount(OAThreadLocal ti)
public static void setHubListenerTree(boolean b)
protected static void setHubListenerTree(OAThreadLocal ti, boolean b)
public static void setIgnoreTreeListenerProperty(String prop)
public static String getIgnoreTreeListenerProperty()
public static int getOASyncEventCount()
public static void incrOASyncEventCount()
public static HubEvent getCurrentHubEvent()
public static boolean isOpenHubEvent(HubEvent he)
public static HubEvent getOldestHubEvent()
public static void addHubEvent(HubEvent he)
public static void removeHubEvent(HubEvent he)
public static boolean isSendingEvent()
protected static boolean isSendingEvent(OAThreadLocal ti)
public static boolean hasSentCalcPropertyChange(Hub thisHub, OAObject thisObj, String propertyName)
public static boolean isEditQueryEnabled()
protected static boolean isEditQueryEnabled(OAThreadLocal ti)
public static boolean setEnableEditQuery(boolean b)
protected static boolean setEnableEditQuery(OAThreadLocal ti, boolean b)
Copyright © 1999–2019 ViaOA. All rights reserved.