com.ibm.websphere.management.repository
Class DocumentContentSource
- java.lang.Object
com.ibm.websphere.management.repository.DocumentContentSource
All implemented interfaces:
java.io.Serializable
- public class DocumentContentSource
- extends java.lang.Object
- implements java.io.Serializable
Document
object with identifying information.
See Also:
Constructor Summary
Constructor and Description |
---|
DocumentContentSource(Document doc,byte[] data)
Creates a
DocumentContentSource instance given a document
and a byte array.
|
DocumentContentSource(Document doc,java.io.File file)
Creates a
DocumentContentSource instance given a document
and a file.
|
DocumentContentSource(Document doc,java.io.InputStream src)
Creates a
DocumentContentSource instance given a document
and an input stream.
|
Method Summary
Modifier and Type | Method and Description |
---|---|
getDocument()
Retrieves the document in this object.
|
|
|
getLastModified()
Retrieves the last modified time of this document.
|
|
getSource()
Gets the document source as an input stream.
|
|
setDocument(Document document)
Sets the document.
|
|
setLastModified(long t)
Sets the last modified time for this document.
|
|
setSource(byte[] data)
Sets a byte array as the document source.
|
|
setSource(java.io.File file)
Sets a
File instance as the document source.
|
|
setSource(java.io.InputStream source)
Sets an input stream as the document source.
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail
DocumentContentSource
- public DocumentContentSource(Document doc,
- java.io.InputStream src)
Parameters:
doc
- the document instance src
- input stream containing the document contents DocumentContentSource
- public DocumentContentSource(Document doc,
- byte[] data)
Creates a
DocumentContentSource
instance given a document
and a byte array.
Parameters:
doc
- the document instance data
- byte array containing the document contents DocumentContentSource
- public DocumentContentSource(Document doc,
- java.io.File file)
Creates a
DocumentContentSource
instance given a document
and a file.
Parameters:
doc
- the document instance file
- file that contains the document contents Method Detail
getDocument
- public Document getDocument()
Retrieves the document in this object.
Returns:
the document for this object
setDocument
- public void setDocument(Document document)
Sets the document.
Parameters:
document
- the document to be set for this object getSource
- public java.io.InputStream getSource( )
Gets the document source as an input stream.
Returns:
an input stream containing the document source
setSource
- public void setSource(java.io.InputStream source)
Sets an input stream as the document source.
Parameters:
source
- the input stream to use as the document source setSource
- public void setSource(byte[] data)
Sets a byte array as the document source.
Parameters:
data
- byte array to use as the document source setSource
- public void setSource(java.io.File file)
Sets a
File
instance as the document source.
Parameters:
file
- file to use as the document source getLastModified
- public long getLastModified()
Retrieves the last modified time of this document.
Returns:
the last modified time for this document
setLastModified
- public void setLastModified(long t)
Sets the last modified time for this document.
Parameters:
t
- last modified time
DocumentContentSource
instance given a document and an input stream.