|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.opencms.util.CmsCollectionsGenericWrapper
public final class CmsCollectionsGenericWrapper
Provides Map wrapping utility functions for Java generics.
Method Summary | ||
---|---|---|
static
|
createLazyMap(org.apache.commons.collections.Transformer T)
Provides a wrapper to access the LazyMap functionality that avoids warnings with Java 1.5 generic code. |
|
static
|
createLRUMap()
Provides a wrapper to create a LRUMap that avoids warnings with Java 1.5 generic code. |
|
static
|
createLRUMap(int size)
Provides a wrapper to create a LRUMap with the given size that avoids warnings with Java 1.5 generic code. |
|
static
|
enumeration(java.util.Enumeration enumeration)
Provides a wrapper to convert an enumeration that avoids warnings with Java 1.5 generic code. |
|
static
|
list(java.lang.Object o)
Provides a wrapper to convert an object into a list that avoids warnings with Java 1.5 generic code. |
|
static
|
map(java.lang.Object o)
Provides a wrapper to convert an object into a map that avoids warnings with Java 1.5 generic code. |
|
static
|
set(java.lang.Object o)
Provides a wrapper to convert an object into a set that avoids warnings with Java 1.5 generic code. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static <K,V> java.util.Map<K,V> createLazyMap(org.apache.commons.collections.Transformer T)
LazyMap
functionality that avoids warnings with Java 1.5 generic code.
K
- the type of keys maintained by the returned mapV
- the type of mapped valuesT
- the transformer to use for the Lazy Map
LazyMap
of the required generic typepublic static <K,V> java.util.Map<K,V> createLRUMap()
LRUMap
that avoids warnings with Java 1.5 generic code.
K
- the type of keys maintained by the returned mapV
- the type of mapped values
LRUMap
of the required generic typepublic static <K,V> java.util.Map<K,V> createLRUMap(int size)
LRUMap
with the given size that avoids warnings with Java 1.5 generic code.
K
- the type of keys maintained by the returned mapV
- the type of mapped valuessize
- the initial size of the created Map
LRUMap
with the given size of the required generic typepublic static <K> java.util.Enumeration<K> enumeration(java.util.Enumeration enumeration)
K
- the type of the returned enumeration elementsenumeration
- the enumeration to be converted
Enumeration
with the required generic typepublic static <K> java.util.List<K> list(java.lang.Object o)
K
- the type of the returned list elementso
- the object to be converted
List
with the required generic typepublic static <K,V> java.util.Map<K,V> map(java.lang.Object o)
K
- the type of keys maintained by the returned mapV
- the type of mapped valueso
- the object to be converted
Map
of the required generic typepublic static <K> java.util.Set<K> set(java.lang.Object o)
K
- the type of the returned set elementso
- the object to be converted
Set
with the required generic type
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |