Class ResourceMethodMap<T extends ResourceMethodDescriptor>
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,,List<T>> javax.ws.rs.core.MultivaluedMap<String,,T> ExtMultivaluedMap<String,T>
public class ResourceMethodMap<T extends ResourceMethodDescriptor>
extends HashMap<String,List<T>>
implements ExtMultivaluedMap<String,T>
- Version:
- $Id: $
- Author:
- Andrey Parfonov
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K, V> -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.util.HashMap
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, newHashMap, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, valuesMethods inherited from class java.util.AbstractMap
equals, hashCode, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
Constructor Details
-
ResourceMethodMap
public ResourceMethodMap()
-
-
Method Details
-
getList
- Specified by:
getListin interfaceExtMultivaluedMap<String,T extends ResourceMethodDescriptor> - Parameters:
httpMethod- key- Returns:
- never null even any value not found in the map, return empty list instead
-
add
- Specified by:
addin interfacejavax.ws.rs.core.MultivaluedMap<String,T extends ResourceMethodDescriptor>
-
getFirst
- Specified by:
getFirstin interfacejavax.ws.rs.core.MultivaluedMap<String,T extends ResourceMethodDescriptor>
-
putSingle
- Specified by:
putSinglein interfacejavax.ws.rs.core.MultivaluedMap<String,T extends ResourceMethodDescriptor>
-
sort
public void sort()Sort each collections in map. -
getAllow
Get HTTP method names to use it in 'Allow' header.- Returns:
- collection of method names
-