Package: io.vertx.groovy.core

## [Groovy] Class MultiMap

- io.vertx.groovy.core.MultiMap

- This class represents a MultiMap of String keys to a List of String values.

  It's useful in Vert.x to represent things in Vert.x like HTTP headers and HTTP parameters which allow multiple values for keys.

- - ### Constructor Summary

    Constructors
    Constructor and description
    `MultiMap (java.lang.Object delegate)`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `MultiMap` | `add(java.lang.String name, java.lang.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(java.lang.String name)` Checks to see if there is a value with the specified name
    `java.lang.String` | `get(java.lang.String name)` Returns the value of with the specified name.
    `java.util.List<java.lang.String>` | `getAll(java.lang.String name)` Returns the values with the specified name
    `java.lang.Object` | `getDelegate()`
    `boolean` | `isEmpty()` Return true if empty @return
    `java.util.Set<java.lang.String>` | `names()` Gets a immutable java.util.Set of all names
    `MultiMap` | `remove(java.lang.String name)` Removes the value with the given name
    `MultiMap` | `set(java.lang.String name, java.lang.String value)` Sets a value under the specified name.
    `MultiMap` | `setAll(MultiMap map)` Cleans this instance.
    `int` | `size()` Return the number of keys.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class java.lang.Object` | `java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()`

- - ### Constructor Detail

    - #### MultiMap(java.lang.Object delegate)

  - ### Method Detail

    - #### MultiMap add(java.lang.String name, java.lang.String value)

      Adds a new value with the specified name and value.

      Returns:
        a reference to this, so the API can be used fluently
      Parameters:
        `name` - The name
        `value` - The value being added

    - #### MultiMap addAll(MultiMap map)

      Adds all the entries from another MultiMap to this one

      Returns:
        a reference to this, so the API can be used fluently
      Parameters:
        map

    - #### static MultiMap caseInsensitiveMultiMap()

      Create a multi-map implementation with case insensitive keys, for instance it can be used to hold some HTTP headers.

      Returns:
        the multi-map

    - #### MultiMap clear()

      Removes all

      Returns:
        a reference to this, so the API can be used fluently

    - #### boolean contains(java.lang.String name)

      Checks to see if there is a value with the specified name

      Returns:
        true if at least one entry is found
      Parameters:
        `name` - The name to search for

    - #### java.lang.String get(java.lang.String name)

      Returns the value of with the specified name. If there are more than one values for the specified name, the first value is returned.

      Returns:
        The first header value or `null` if there is no such entry
      Parameters:
        `name` - The name of the header to search

    - #### java.util.List<java.lang.String> getAll(java.lang.String name)

      Returns the values with the specified name

      Returns:
        A immutable java.util.List of values which will be empty if no values are found
      Parameters:
        `name` - The name to search

    - #### java.lang.Object getDelegate()

    - #### boolean isEmpty()

      Return true if empty

      Returns:

    - #### java.util.Set<java.lang.String> names()

      Gets a immutable java.util.Set of all names

      Returns:
        A java.util.Set of all names

    - #### MultiMap remove(java.lang.String name)

      Removes the value with the given name

      Returns:
        a reference to this, so the API can be used fluently
      Parameters:
        `name` - The name of the value to remove

    - #### MultiMap set(java.lang.String name, java.lang.String value)

      Sets a value under the specified name.

      If there is an existing header with the same name, it is removed.

      Returns:
        a reference to this, so the API can be used fluently
      Parameters:
        `name` - The name
        `value` - The value

    - #### MultiMap setAll(MultiMap map)

      Cleans this instance.

      Returns:
        a reference to this, so the API can be used fluently
      Parameters:
        map

    - #### int size()

      Return the number of keys.

      Returns: