public class WikiParameters extends Object implements Iterable<WikiParameter>
WikiParameter
s.Modifier and Type | Field and Description |
---|---|
static char |
DEFAULT_ESCAPECHAR
The default character to use has escaping char.
|
static WikiParameters |
EMPTY
An empty parameter list
|
protected List<WikiParameter> |
fList |
Constructor and Description |
---|
WikiParameters() |
WikiParameters(Collection<WikiParameter> list) |
WikiParameters(String str) |
WikiParameters(String str,
char escapeChar) |
WikiParameters(String str,
String delimiter) |
WikiParameters(WikiParameters parameters) |
Modifier and Type | Method and Description |
---|---|
WikiParameters |
addParameter(String key,
String value)
Creates a new copy of this parameter object with new specified key/value
pair.
|
WikiParameters |
addParameters(WikiParameters parameters) |
boolean |
equals(Object obj) |
WikiParameter |
getParameter(int pos) |
WikiParameter |
getParameter(String key) |
WikiParameter[] |
getParameters(String key)
Returns all parameters with this key
|
int |
getSize()
Returns the number of parameters in the internal list.
|
int |
hashCode() |
Iterator<WikiParameter> |
iterator() |
static WikiParameters |
newWikiParameters(String str) |
static WikiParameters |
newWikiParameters(String str,
char escapeChar) |
WikiParameters |
remove(String key) |
WikiParameters |
setParameter(String key,
String value) |
List<WikiParameter> |
toList()
Returns a new list containing all parameters defined in this object.
|
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, spliterator
public static final char DEFAULT_ESCAPECHAR
public static final WikiParameters EMPTY
protected final List<WikiParameter> fList
public WikiParameters()
public WikiParameters(Collection<WikiParameter> list)
list
- public WikiParameters(String str)
str
- public WikiParameters(String str, char escapeChar)
public WikiParameters(WikiParameters parameters)
public static WikiParameters newWikiParameters(String str)
public static WikiParameters newWikiParameters(String str, char escapeChar)
public WikiParameters addParameter(String key, String value)
key
- the parameter namevalue
- the value of the parameterpublic WikiParameters addParameters(WikiParameters parameters)
public WikiParameters setParameter(String key, String value)
public boolean equals(Object obj)
equals
in class Object
Object.equals(java.lang.Object)
public WikiParameter getParameter(int pos)
pos
- the position of the parameterpublic WikiParameter getParameter(String key)
key
- the key of the parameterpublic WikiParameter[] getParameters(String key)
key
- the key of the parameterpublic int getSize()
public int hashCode()
hashCode
in class Object
Object.hashCode()
public Iterator<WikiParameter> iterator()
iterator
in interface Iterable<WikiParameter>
public WikiParameters remove(String key)
key
- the key of the parameter to removepublic List<WikiParameter> toList()
public String toString()
toString
in class Object
Object.toString()
Copyright © 2004–2021 XWiki. All rights reserved.