public class MultiMap extends Object
It's useful in Vert.x to represent things in Vert.x like HTTP headers and HTTP parameters which allow multiple values for keys.
NOTE: This class has been automatically generated from theoriginal
non RX-ified interface using Vert.x codegen.Modifier and Type | Method and Description |
---|---|
MultiMap |
add(String name,
String value)
Adds a new value with the specified name and value.
|
MultiMap |
addAll(MultiMap map)
Adds all the entries from another MultiMap to this one
|
static MultiMap |
caseInsensitiveMultiMap()
Create a multi-map implementation with case insensitive keys, for instance it can be used to hold some HTTP headers.
|
MultiMap |
clear()
Removes all
|
boolean |
contains(String name)
Checks to see if there is a value with the specified name
|
String |
get(String name)
Returns the value of with the specified name.
|
List<String> |
getAll(String name)
Returns the values with the specified name
|
Object |
getDelegate() |
boolean |
isEmpty()
Return true if empty
|
Set<String> |
names()
Gets a immutable
Set of all names |
static MultiMap |
newInstance(MultiMap arg) |
MultiMap |
remove(String name)
Removes the value with the given name
|
MultiMap |
set(String name,
String value)
Sets a value under the specified name.
|
MultiMap |
setAll(MultiMap map)
Cleans this instance.
|
int |
size()
Return the number of keys.
|
public MultiMap(MultiMap delegate)
public Object getDelegate()
public static MultiMap caseInsensitiveMultiMap()
public String get(String name)
name
- The name of the header to searchnull
if there is no such entrypublic List<String> getAll(String name)
name
- The name to searchList
of values which will be empty if no values are foundpublic boolean contains(String name)
name
- The name to search forpublic boolean isEmpty()
public MultiMap add(String name, String value)
name
- The namevalue
- The value being addedpublic MultiMap addAll(MultiMap map)
map
- public MultiMap set(String name, String value)
If there is an existing header with the same name, it is removed.
name
- The namevalue
- The valuepublic MultiMap setAll(MultiMap map)
map
- public MultiMap remove(String name)
name
- The name of the value to removepublic MultiMap clear()
public int size()
Copyright © 2016. All rights reserved.