com.google.common.util.concurrent.CycleDetectingLockFactory Java Examples
The following examples show how to use
com.google.common.util.concurrent.CycleDetectingLockFactory.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Threading.java From GreenBits with GNU General Public License v3.0 | 4 votes |
public static void ignoreLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.DISABLED); }
Example #2
Source File: Threading.java From jelectrum with MIT License | 4 votes |
public static CycleDetectingLockFactory.Policy getPolicy() { return policy; }
Example #3
Source File: Threading.java From jelectrum with MIT License | 4 votes |
public static void setPolicy(CycleDetectingLockFactory.Policy policy) { Threading.policy = policy; factory = CycleDetectingLockFactory.newInstance(policy); }
Example #4
Source File: Threading.java From jelectrum with MIT License | 4 votes |
public static void ignoreLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.DISABLED); }
Example #5
Source File: Threading.java From jelectrum with MIT License | 4 votes |
public static void throwOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.THROW); }
Example #6
Source File: Threading.java From jelectrum with MIT License | 4 votes |
public static void warnOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.WARN); }
Example #7
Source File: Threading.java From bitherj with Apache License 2.0 | 4 votes |
public static CycleDetectingLockFactory.Policy getPolicy() { return policy; }
Example #8
Source File: Threading.java From bitherj with Apache License 2.0 | 4 votes |
public static void setPolicy(CycleDetectingLockFactory.Policy policy) { Threading.policy = policy; factory = CycleDetectingLockFactory.newInstance(policy); }
Example #9
Source File: Threading.java From bitherj with Apache License 2.0 | 4 votes |
public static void ignoreLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.DISABLED); }
Example #10
Source File: Threading.java From bitherj with Apache License 2.0 | 4 votes |
public static void throwOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.THROW); }
Example #11
Source File: Threading.java From bitherj with Apache License 2.0 | 4 votes |
public static void warnOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.WARN); }
Example #12
Source File: Threading.java From GreenBits with GNU General Public License v3.0 | 4 votes |
public static CycleDetectingLockFactory.Policy getPolicy() { return policy; }
Example #13
Source File: Threading.java From GreenBits with GNU General Public License v3.0 | 4 votes |
public static void setPolicy(CycleDetectingLockFactory.Policy policy) { Threading.policy = policy; factory = CycleDetectingLockFactory.newInstance(policy); }
Example #14
Source File: Threading.java From bcm-android with GNU General Public License v3.0 | 4 votes |
public static void warnOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.WARN); }
Example #15
Source File: Threading.java From GreenBits with GNU General Public License v3.0 | 4 votes |
public static void throwOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.THROW); }
Example #16
Source File: Threading.java From GreenBits with GNU General Public License v3.0 | 4 votes |
public static void warnOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.WARN); }
Example #17
Source File: Threading.java From green_android with GNU General Public License v3.0 | 4 votes |
public static CycleDetectingLockFactory.Policy getPolicy() { return policy; }
Example #18
Source File: Threading.java From green_android with GNU General Public License v3.0 | 4 votes |
public static void setPolicy(CycleDetectingLockFactory.Policy policy) { Threading.policy = policy; factory = CycleDetectingLockFactory.newInstance(policy); }
Example #19
Source File: Threading.java From green_android with GNU General Public License v3.0 | 4 votes |
public static void ignoreLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.DISABLED); }
Example #20
Source File: Threading.java From green_android with GNU General Public License v3.0 | 4 votes |
public static void throwOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.THROW); }
Example #21
Source File: Threading.java From green_android with GNU General Public License v3.0 | 4 votes |
public static void warnOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.WARN); }
Example #22
Source File: Threading.java From bcm-android with GNU General Public License v3.0 | 4 votes |
public static CycleDetectingLockFactory.Policy getPolicy() { return policy; }
Example #23
Source File: Threading.java From bcm-android with GNU General Public License v3.0 | 4 votes |
public static void setPolicy(CycleDetectingLockFactory.Policy policy) { Threading.policy = policy; factory = CycleDetectingLockFactory.newInstance(policy); }
Example #24
Source File: Threading.java From bcm-android with GNU General Public License v3.0 | 4 votes |
public static void ignoreLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.DISABLED); }
Example #25
Source File: Threading.java From bcm-android with GNU General Public License v3.0 | 4 votes |
public static void throwOnLockCycles() { setPolicy(CycleDetectingLockFactory.Policies.THROW); }
Example #26
Source File: CycleDetectingLockUtils.java From dcos-commons with Apache License 2.0 | 2 votes |
/** * Returns a new cycle detecting lock instance which has the provided label. * * @param exitOnDeadlock whether to exit the process if a deadlock is detected * @param parentClass to be used in any error messages */ public static ReadWriteLock newLock(boolean exitOnDeadlock, Class<?> parentClass) { return CycleDetectingLockFactory .newInstance(exitOnDeadlock ? LOG_AND_EXIT_POLICY : CycleDetectingLockFactory.Policies.WARN) .newReentrantReadWriteLock(parentClass.getSimpleName()); }