|
Project JXTA | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A simple typed container for data. A Document
is presented as a
byte stream with an associated type. The data type is specified using a
MIME Media Type (as defined by
IETF RFC 2046 MIME : Media Types).
MimeMediaType
,
StructuredDocument
,
StructuredDocumentFactory
Method Summary | |
String |
getFileExtension()
Returns the file extension type used by this Document . |
MimeMediaType |
getMimeType()
Returns the MIME Media type of this Document per
IETF RFC 2046 MIME : Media Types.
|
InputStream |
getStream()
Returns the stream of bytes which represents the content of this Document . |
void |
sendToStream(OutputStream stream)
Send the contents of this Document to the specified stream. |
Method Detail |
public MimeMediaType getMimeType()
Document
per
IETF RFC 2046 MIME : Media Types.
JXTA does not currently support the 'Multipart
' or
'Message
' media types.
Document
.public String getFileExtension()
Document
. This
value is usually chosen based upon the MIME Media Type.
Document
.public InputStream getStream() throws IOException
Document
.
InputStream
containing the bytes
of this Document
.
IOException
- if an I/O error occurs.public void sendToStream(OutputStream stream) throws IOException
Document
to the specified stream.
stream
- The OutputStream to which the Document
will
be written.
IOException
- if an I/O error occurs.
|
JXTA J2SE | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |