Package com.yahoo.prelude.hitfield
Class XMLString
- java.lang.Object
-
- com.yahoo.prelude.hitfield.XMLString
-
- All Implemented Interfaces:
XmlProducer
public class XMLString extends Object implements XmlProducer
A representation of an XML chunk.- Author:
- Steinar Knutsen
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
toString()
String
toXML()
Convenience method equivalent to: writeXML(new StringBuilder()).toString()StringBuilder
writeXML(StringBuilder target)
Append the XML representation of this object's data to a StringBuilder.
-
-
-
Constructor Detail
-
XMLString
public XMLString(String content)
-
-
Method Detail
-
writeXML
public StringBuilder writeXML(StringBuilder target)
Description copied from interface:XmlProducer
Append the XML representation of this object's data to a StringBuilder.- Specified by:
writeXML
in interfaceXmlProducer
- Parameters:
target
- the StringBuilder to append to.- Returns:
- the target passed in is also returned (to allow chaining).
-
toXML
public String toXML()
Description copied from interface:XmlProducer
Convenience method equivalent to: writeXML(new StringBuilder()).toString()- Specified by:
toXML
in interfaceXmlProducer
- Returns:
- String containing XML representation of this object's data.
-
-