public class ObjectLists
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static speiger.src.collections.objects.utils.ObjectLists.EmptyList<?> |
EMPTY
Empty List reference
|
| Constructor and Description |
|---|
ObjectLists() |
| Modifier and Type | Method and Description |
|---|---|
static <T> speiger.src.collections.objects.utils.ObjectLists.EmptyList<T> |
emptyList()
Returns a Immutable EmptyList instance that is automatically casted.
|
static <T> ObjectList<T> |
singletonList(T element)
Creates a Unmodifiable Singleton list
|
static <T> ObjectList<T> |
synchronizedList(ObjectList<T> l)
Returns a synchronized List instance based on the instance given.
|
static <T> ObjectList<T> |
synchronizedList(ObjectList<T> l,
java.lang.Object mutex)
Returns a synchronized List instance based on the instance given.
|
static <T> ObjectList<T> |
unmodifiableList(ObjectList<T> l)
Returns a Immutable List instance based on the instance given.
|
public static final speiger.src.collections.objects.utils.ObjectLists.EmptyList<?> EMPTY
public static <T> speiger.src.collections.objects.utils.ObjectLists.EmptyList<T> emptyList()
T - the type of elements maintained by this Collectionpublic static <T> ObjectList<T> unmodifiableList(ObjectList<T> l)
T - the type of elements maintained by this Collectionl - that should be made immutable/unmodifyablepublic static <T> ObjectList<T> synchronizedList(ObjectList<T> l)
T - the type of elements maintained by this Collectionl - that should be synchronizedpublic static <T> ObjectList<T> synchronizedList(ObjectList<T> l, java.lang.Object mutex)
T - the type of elements maintained by this Collectionl - that should be synchronizedmutex - is the controller of the synchronization block.public static <T> ObjectList<T> singletonList(T element)
T - the type of elements maintained by this Collectionelement - that should be used in the Singleton