com.ibm.mm.sdk.common
Interface dkXDO
-
- All Superinterfaces:
- dkDataObjectBase, dkXDOBase
- All Known Implementing Classes:
- DKLobICM, dkResource
public interface dkXDO extends dkXDOBase
Interface for extended data objects (XDO) with content operations in CM8.An extended data object represents a content-bearing object such as a document with binary content. This interface extends
dkXDOBaseand adds operations for managing content and MIME types.Key Operations:
- Set binary content data
- Set MIME type for content
- Add/persist the object to the datastore
Example usage:
dkXDO xdo = (dkXDO) datastore.createDDO("ResourceDocument"); xdo.setContent(fileBytes); xdo.setMimeType("application/pdf"); xdo.add();- See Also:
dkXDOBase,dkResource,DKDDO
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidadd()Adds this extended data object to the datastore, persisting it.voidsetContent(byte[] aByteArr)Sets the binary content for this extended data object.voidsetMimeType(java.lang.String string)Sets the MIME type for the content of this extended data object.
-
-
-
Method Detail
-
setContent
void setContent(byte[] aByteArr) throws DKExceptionSets the binary content for this extended data object.- Parameters:
aByteArr- the byte array containing the content data- Throws:
DKException- if the content cannot be set
-
add
void add() throws DKException, java.lang.Exception
Adds this extended data object to the datastore, persisting it.- Throws:
DKException- if the add operation failsjava.lang.Exception- for other errors during persistence
-
setMimeType
void setMimeType(java.lang.String string) throws DKException, java.lang.ExceptionSets the MIME type for the content of this extended data object.- Parameters:
string- the MIME type (e.g., "application/pdf", "image/jpeg")- Throws:
DKException- if the MIME type cannot be setjava.lang.Exception- for other errors
-
-