gnu.xml

Class TextUtils

public class TextUtils extends Object

Method Summary
static StringasString(Object node)
static StringreplaceWhitespace(String str, boolean collapse)
Create a normalized string.
static StringstringValue(Object node)
static voidstringValue(Object node, StringBuffer sbuf)
static voidtextValue(Object arg, Consumer out)

Method Detail

asString

public static String asString(Object node)

replaceWhitespace

public static String replaceWhitespace(String str, boolean collapse)
Create a normalized string.

Returns: the original string if it was normalized; otherwise a fresh one. (XStringType.matcyhes assumes the above.)

stringValue

public static String stringValue(Object node)

stringValue

public static void stringValue(Object node, StringBuffer sbuf)

textValue

public static void textValue(Object arg, Consumer out)