net.jxta.document
Interface TextDocument
- All Superinterfaces:
- Document
- All Known Subinterfaces:
- StructuredTextDocument
- All Known Implementing Classes:
- NewTextMessageElement
- public interface TextDocument
- extends Document
This interface represents a Text based Document. Extends Document by
adding character oriented output features.
- Since:
- JXTA 1.0
- Version:
- $Revision: 1.9 $
- See Also:
Document,
TextElement,
StructuredTextDocument,
StructuredDocumentFactory,
MimeMediaType,
StructuredDocument
|
Method Summary |
java.io.Reader |
getReader()
Returns a stream of characters which represent the content of this Document. |
void |
sendToWriter(java.io.Writer stream)
Rather than returning an InputStream, send the document to the specified
stream. |
getReader
public java.io.Reader getReader()
throws java.io.IOException
- Returns a stream of characters which represent the content of this Document.
- Returns:
- Reader A
Reader containting the characters
of this Document. - Throws:
java.io.IOException - if an I/O error occurs.- Since:
- JXTA 1.0
sendToWriter
public void sendToWriter(java.io.Writer stream)
throws java.io.IOException
- Rather than returning an InputStream, send the document to the specified
stream.
- Parameters:
stream - The OutputStream to which the document will be written.- Throws:
java.io.IOException - if an I/O error occurs.- Since:
- JXTA 1.0