|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.parboiled.common.Reference<T>
org.parboiled.support.Var<java.lang.String>
org.parboiled.support.StringVar
public class StringVar
Simple specialization of a Var
for Strings. Provides a few convenience helper methods.
Constructor Summary | |
---|---|
StringVar()
Initializes a new StringVar with a null initial value. |
|
StringVar(java.lang.String value)
Initializes a new StringVar with the given initial value. |
Method Summary | |
---|---|
boolean |
append(char c)
Appends the given char. |
boolean |
append(java.lang.String text)
Appends the given string. |
boolean |
append(java.lang.String text1,
java.lang.String text2)
Appends the given strings. |
StringVar |
appended(char c)
Appends the given char. |
StringVar |
appended(java.lang.String text)
Appends the given string. |
StringVar |
appended(java.lang.String text1,
java.lang.String text2)
Appends the given strings. |
boolean |
isEmpty()
Returns true if the wrapped string is either null or empty. |
Methods inherited from class org.parboiled.support.Var |
---|
enterFrame, exitFrame, getLevel, getName, setName, toString |
Methods inherited from class org.parboiled.common.Reference |
---|
clear, get, getAndClear, getAndSet, isNotSet, isSet, set, setAndGet |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public StringVar()
public StringVar(java.lang.String value)
value
- the initial valueMethod Detail |
---|
public boolean isEmpty()
public boolean append(java.lang.String text)
text
- the text to append
public StringVar appended(java.lang.String text)
text
- the text to append
public boolean append(char c)
c
- the char to append
public StringVar appended(char c)
c
- the char to append
public boolean append(java.lang.String text1, java.lang.String text2)
text1
- the first text to appendtext2
- the second text to append
public StringVar appended(java.lang.String text1, java.lang.String text2)
text1
- the first text to appendtext2
- the second text to append
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |