|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.matthiasmann.twl.utils.ParameterStringParser
public class ParameterStringParser
A utility class to parse parameter lists in string form like the query part of an Url or CSS styles.
| Constructor Summary | |
|---|---|
ParameterStringParser(java.lang.String str,
char parameterSeparator,
char keyValueSeparator)
Creates a new parser object. |
|
| Method Summary | |
|---|---|
java.lang.String |
getKey()
Returns the current key |
java.lang.String |
getValue()
Returns the current value |
boolean |
isTrim()
|
boolean |
next()
Extract the next key-value pair |
void |
setTrim(boolean trim)
Enables trimming of white spaces on key and values |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ParameterStringParser(java.lang.String str,
char parameterSeparator,
char keyValueSeparator)
str - the String to parseparameterSeparator - the character which separates key-value pairs from each otherkeyValueSeparator - the character which separates key and value from each other| Method Detail |
|---|
public boolean isTrim()
public void setTrim(boolean trim)
trim - true if white spaces should be trimmedCharacter.isWhitespace(char)public boolean next()
public java.lang.String getKey()
next()public java.lang.String getValue()
next()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||