Package ghidra.util.datastruct
Class WeakDataStructureFactory
- java.lang.Object
-
- ghidra.util.datastruct.WeakDataStructureFactory
-
public class WeakDataStructureFactory extends java.lang.Object
Factory for creating containers to use in various threading environments
-
-
Constructor Summary
Constructors Constructor Description WeakDataStructureFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> WeakSet<T>
createCopyOnReadWeakSet()
Use when mutations outweigh iterations.static <T> WeakSet<T>
createCopyOnWriteWeakSet()
Use when iterations outweigh mutations.static <T> WeakSet<T>
createSingleThreadAccessWeakSet()
Use when all access are on a single thread, such as the Swing thread.
-
-
-
Method Detail
-
createSingleThreadAccessWeakSet
public static <T> WeakSet<T> createSingleThreadAccessWeakSet()
Use when all access are on a single thread, such as the Swing thread.- Returns:
- a new WeakSet
-
createCopyOnReadWeakSet
public static <T> WeakSet<T> createCopyOnReadWeakSet()
Use when mutations outweigh iterations.- Returns:
- a new WeakSet
- See Also:
CopyOnReadWeakSet
-
createCopyOnWriteWeakSet
public static <T> WeakSet<T> createCopyOnWriteWeakSet()
Use when iterations outweigh mutations.- Returns:
- a new WeakSet
- See Also:
CopyOnWriteWeakSet
-
-