public interface Attachment
Modifier and Type | Method and Description |
---|---|
long |
getChecksum()
Return the checksum of the attachment
|
java.io.InputStream |
getContent()
Returns an input stream of the data
|
java.lang.String |
getContentType()
Return the content type of the attachment
|
java.lang.String |
getName()
Return the name of the attachment
|
long |
getSize()
Return the size of the attachment in bytes
|
void |
setChecksum(long checksum)
Sets the checksum of the attachment.
|
void |
setContent(java.io.InputStream content)
Sets the contents of the attachment as an input stream
|
void |
setContentType(java.lang.String type)
Set the content type of the attachment
|
void |
setName(java.lang.String name)
Set the name of the attachment
|
void |
setSize(long size)
Sets the size of the attachment in bytes.
|
com.ibm.json.java.JSONObject |
toJSON()
Output the attributes of the repository object in JSON format
|
java.lang.String |
toString()
Output the attributes of the repository object in
java.lang.String |
java.lang.String getName()
void setName(java.lang.String name)
name
- java.lang.String getContentType()
void setContentType(java.lang.String type)
type
- the content typelong getSize()
void setSize(long size)
the
- size of the attachmentlong getChecksum()
void setChecksum(long checksum)
the
- checksum of the attachmentjava.io.InputStream getContent() throws BuildException
BuildException
- an exception occurredvoid setContent(java.io.InputStream content) throws BuildException
content
- Input stream of the attachment dataBuildException
- an exception occurredcom.ibm.json.java.JSONObject toJSON()
java.lang.String toString()
java.lang.String
toString
in class java.lang.Object
<IBM Copyright © 2018 IBM Corp. All Rights Reserved.