T - The contained typepublic abstract class Series<T extends NamedValue<java.lang.String>> extends WrapperList<T>
Parameter, 
Collections, 
List| Modifier and Type | Field and Description | 
|---|---|
static java.lang.Object | 
EMPTY_VALUE
A marker for empty values to differentiate from non existing values
 (null). 
 | 
| Constructor and Description | 
|---|
Series(java.lang.Class<T> entryClass)
Constructor. 
 | 
Series(java.lang.Class<T> entryClass,
      int initialCapacity)
Constructor. 
 | 
Series(java.lang.Class<T> entryClass,
      java.util.List<T> delegate)
Constructor. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
boolean | 
add(java.lang.String name,
   java.lang.String value)
Creates then adds a parameter at the end of the list. 
 | 
void | 
copyTo(java.util.Map<java.lang.String,java.lang.Object> params)
Copies the parameters whose name is a key in the given map. 
 | 
abstract T | 
createEntry(java.lang.String name,
           java.lang.String value)
Creates a new entry. 
 | 
abstract Series<T> | 
createSeries(java.util.List<T> delegate)
Creates a new series. 
 | 
T | 
getFirst(java.lang.String name)
Returns the first parameter found with the given name. 
 | 
T | 
getFirst(java.lang.String name,
        boolean ignoreCase)
Returns the first parameter found with the given name. 
 | 
java.lang.String | 
getFirstValue(java.lang.String name)
Returns the value of the first parameter found with the given name. 
 | 
java.lang.String | 
getFirstValue(java.lang.String name,
             boolean ignoreCase)
Returns the value of the first parameter found with the given name. 
 | 
java.lang.String | 
getFirstValue(java.lang.String name,
             boolean ignoreCase,
             java.lang.String defaultValue)
Returns the value of the first parameter found with the given name. 
 | 
java.lang.String | 
getFirstValue(java.lang.String name,
             java.lang.String defaultValue)
Returns the value of the first parameter found with the given name. 
 | 
java.util.Set<java.lang.String> | 
getNames()
Returns the set of parameter names (case sensitive). 
 | 
java.lang.String | 
getValues(java.lang.String name)
Returns the values of the parameters with a given name. 
 | 
java.lang.String | 
getValues(java.lang.String name,
         java.lang.String separator,
         boolean ignoreCase)
Returns the parameter values with a given name. 
 | 
java.lang.String[] | 
getValuesArray(java.lang.String name)
Returns an array of all the values associated to the given parameter
 name. 
 | 
java.lang.String[] | 
getValuesArray(java.lang.String name,
              boolean ignoreCase)
Returns an array of all the values associated to the given parameter
 name. 
 | 
java.lang.String[] | 
getValuesArray(java.lang.String name,
              boolean ignoreCase,
              java.lang.String defaultValue)
Returns an array of all the values associated to the given parameter
 name. 
 | 
java.lang.String[] | 
getValuesArray(java.lang.String name,
              java.lang.String defaultValue)
Returns an array of all the values associated to the given parameter
 name. 
 | 
java.util.Map<java.lang.String,java.lang.String> | 
getValuesMap()
Returns a map of name, value pairs. 
 | 
boolean | 
removeAll(java.lang.String name)
Removes all the parameters with a given name. 
 | 
boolean | 
removeAll(java.lang.String name,
         boolean ignoreCase)
Removes all the parameters with a given name. 
 | 
boolean | 
removeFirst(java.lang.String name)
Removes from this list the first entry whose name equals the specified
 name ignoring the case. 
 | 
boolean | 
removeFirst(java.lang.String name,
           boolean ignoreCase)
Removes from this list the first entry whose name equals the specified
 name ignoring the case or not. 
 | 
T | 
set(java.lang.String name,
   java.lang.String value)
Replaces the value of the first parameter with the given name and removes
 all other parameters with the same name. 
 | 
T | 
set(java.lang.String name,
   java.lang.String value,
   boolean ignoreCase)
Replaces the value of the first parameter with the given name and removes
 all other parameters with the same name. 
 | 
Series<T> | 
subList(int fromIndex,
       int toIndex)
Returns a view of the portion of this list between the specified
 fromIndex, inclusive, and toIndex, exclusive. 
 | 
Series<T> | 
subList(java.lang.String name)
Returns a list of all the values associated to the parameter name. 
 | 
Series<T> | 
subList(java.lang.String name,
       boolean ignoreCase)
Returns a list of all the values associated to the parameter name. 
 | 
add, add, addAll, addAll, clear, contains, containsAll, equals, get, getDelegate, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, toArray, toArray, toStringpublic static final java.lang.Object EMPTY_VALUE
public Series(java.lang.Class<T> entryClass)
public Series(java.lang.Class<T> entryClass, int initialCapacity)
initialCapacity - The initial list capacity.public boolean add(java.lang.String name,
                   java.lang.String value)
name - The parameter name.value - The parameter value.public void copyTo(java.util.Map<java.lang.String,java.lang.Object> params)
params - The map controlling the copy.public abstract T createEntry(java.lang.String name, java.lang.String value)
name - The name of the entry.value - The value of the entry.public abstract Series<T> createSeries(java.util.List<T> delegate)
delegate - Optional delegate series.public T getFirst(java.lang.String name)
name - The parameter name (case sensitive).public T getFirst(java.lang.String name, boolean ignoreCase)
name - The parameter name.ignoreCase - Indicates if the name comparison is case insensitive.public java.lang.String getFirstValue(java.lang.String name)
name - The parameter name (case sensitive).public java.lang.String getFirstValue(java.lang.String name,
                                      boolean ignoreCase)
name - The parameter name.ignoreCase - Indicates if the name comparison is case sensitive.public java.lang.String getFirstValue(java.lang.String name,
                                      boolean ignoreCase,
                                      java.lang.String defaultValue)
name - The parameter name.ignoreCase - Indicates if the name comparison is case sensitive.defaultValue - The default value to return if no matching parameter found or
            if the parameter has a null value.public java.lang.String getFirstValue(java.lang.String name,
                                      java.lang.String defaultValue)
name - The parameter name (case sensitive).defaultValue - The default value to return if no matching parameter found or
            if the parameter has a null value.public java.util.Set<java.lang.String> getNames()
public java.lang.String getValues(java.lang.String name)
name - The parameter name (case insensitive).public java.lang.String getValues(java.lang.String name,
                                  java.lang.String separator,
                                  boolean ignoreCase)
name - The parameter name.separator - The separator character.ignoreCase - Indicates if the name comparison is case sensitive.public java.lang.String[] getValuesArray(java.lang.String name)
name - The parameter name to match (case sensitive).public java.lang.String[] getValuesArray(java.lang.String name,
                                         boolean ignoreCase)
name - The parameter name to match.ignoreCase - Indicates if the name comparison is case sensitive.public java.lang.String[] getValuesArray(java.lang.String name,
                                         boolean ignoreCase,
                                         java.lang.String defaultValue)
name - The parameter name to match.ignoreCase - Indicates if the name comparison is case sensitive.defaultValue - The default value to return if no matching parameter found or
            if the parameter has a null value.public java.lang.String[] getValuesArray(java.lang.String name,
                                         java.lang.String defaultValue)
name - The parameter name to match.defaultValue - The default value to return if no matching parameter found or
            if the parameter has a null value.public java.util.Map<java.lang.String,java.lang.String> getValuesMap()
public boolean removeAll(java.lang.String name)
name - The parameter name (case sensitive).public boolean removeAll(java.lang.String name,
                         boolean ignoreCase)
name - The parameter name.ignoreCase - Indicates if the name comparison is case insensitive.public boolean removeFirst(java.lang.String name)
name - The name of the entries to be removed (case sensitive).public boolean removeFirst(java.lang.String name,
                           boolean ignoreCase)
name - The name of the entries to be removed.ignoreCase - Indicates if the name comparison is case insensitive.public T set(java.lang.String name, java.lang.String value)
name - The parameter name.value - The value to set.public T set(java.lang.String name, java.lang.String value, boolean ignoreCase)
name - The parameter name.value - The value to set.ignoreCase - Indicates if the name comparison is case insensitive.public Series<T> subList(int fromIndex, int toIndex)
subList in interface java.util.List<T extends NamedValue<java.lang.String>>subList in class WrapperList<T extends NamedValue<java.lang.String>>fromIndex - The start position.toIndex - The end position (exclusive).public Series<T> subList(java.lang.String name)
name - The parameter name (case sensitive).Copyright © 2005-2024 Restlet.