public class StringSource extends StreamSource
StreamSource that reads from a StringReader. The string to be read
can be set via the constructor.FEATURE| Constructor and Description |
|---|
StringSource(String content)
Initializes a new instance of the
StringSource with the given string content. |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
getInputStream()
Returns
null. |
Reader |
getReader() |
void |
setInputStream(InputStream inputStream)
Throws
UnsupportedOperationException. |
void |
setReader(Reader reader)
Throws
UnsupportedOperationException. |
String |
toString() |
getPublicId, getSystemId, setPublicId, setSystemId, setSystemIdpublic StringSource(String content)
StringSource with the given string content.content - the contentpublic Reader getReader()
getReader in class StreamSourcepublic void setInputStream(InputStream inputStream)
UnsupportedOperationException.setInputStream in class StreamSourceUnsupportedOperationException - alwayspublic InputStream getInputStream()
null.getInputStream in class StreamSourcenullpublic void setReader(Reader reader)
UnsupportedOperationException.setReader in class StreamSourceUnsupportedOperationException - always