public class HttpServletResponseHeaders extends Object implements MultivaluedMap<String,Object>
Constructor and Description |
---|
HttpServletResponseHeaders(HttpServletResponse response,
ResteasyProviderFactory factory) |
Modifier and Type | Method and Description |
---|---|
void |
add(String key,
Object value)
Add a value to the current list of values for the supplied key.
|
void |
addAll(String key,
List<Object> valueList)
Add all the values from the supplied value list to the current list of
values for the supplied key.
|
void |
addAll(String key,
Object... newValues)
Add multiple values to the current list of values for the supplied key.
|
void |
addFirst(String key,
Object value)
Add a value to the first position in the current list of values for the
supplied key.
|
protected void |
addResponseHeader(String key,
Object value) |
void |
clear() |
boolean |
containsKey(Object o) |
boolean |
containsValue(Object o) |
Set<Map.Entry<String,List<Object>>> |
entrySet() |
boolean |
equals(Object o) |
boolean |
equalsIgnoreValueOrder(MultivaluedMap<String,Object> otherMap)
Compare the specified map with this map for equality modulo the order
of values for each key.
|
List<Object> |
get(Object o) |
Object |
getFirst(String key)
A shortcut to get the first value of the supplied key.
|
int |
hashCode() |
boolean |
isEmpty() |
Set<String> |
keySet() |
List<Object> |
put(String s,
List<Object> objs) |
void |
putAll(Map<? extends String,? extends List<Object>> map) |
protected void |
putResponseHeader(String key,
Object value) |
void |
putSingle(String key,
Object value)
Set the key's value to be a one item list consisting of the supplied value.
|
List<Object> |
remove(Object o) |
int |
size() |
Collection<List<Object>> |
values() |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
public HttpServletResponseHeaders(HttpServletResponse response, ResteasyProviderFactory factory)
public void addAll(String key, Object... newValues)
MultivaluedMap
NullPointerException
if the supplied array of values
is null
.addAll
in interface MultivaluedMap<String,Object>
key
- the key.newValues
- the values to be added.public void addAll(String key, List<Object> valueList)
MultivaluedMap
NullPointerException
if the
supplied array of values is null
.addAll
in interface MultivaluedMap<String,Object>
key
- the key.valueList
- the list of values to be added.public void addFirst(String key, Object value)
MultivaluedMap
addFirst
in interface MultivaluedMap<String,Object>
key
- the keyvalue
- the value to be added.public void putSingle(String key, Object value)
MultivaluedMap
putSingle
in interface MultivaluedMap<String,Object>
key
- the keyvalue
- the single value of the keypublic void add(String key, Object value)
MultivaluedMap
add
in interface MultivaluedMap<String,Object>
key
- the keyvalue
- the value to be added.public Object getFirst(String key)
MultivaluedMap
getFirst
in interface MultivaluedMap<String,Object>
key
- the keypublic boolean containsKey(Object o)
containsKey
in interface Map<String,List<Object>>
public boolean containsValue(Object o)
containsValue
in interface Map<String,List<Object>>
public Collection<List<Object>> values()
public boolean equals(Object o)
public int hashCode()
public boolean equalsIgnoreValueOrder(MultivaluedMap<String,Object> otherMap)
MultivaluedMap
equalsIgnoreValueOrder
in interface MultivaluedMap<String,Object>
otherMap
- map to be compared to this one.Copyright © 2021 JBoss by Red Hat. All rights reserved.