public interface DOWriter extends DOReader
A DOWriter instance is a handle on a Fedora digital object,
and is obtained via a getWriter(String) call on a
DOManager.
Work with a DOWriter ends with either commit() or cancel().
| Modifier and Type | Method and Description |
|---|---|
void |
addDatastream(Datastream datastream,
boolean addNewVersion)
Adds a datastream to the object.
|
boolean |
addRelationship(String subject,
String relationship,
String object,
boolean isLiteral,
String datatype)
Adds a RDF triple to a reserved datastream (based on the subject)
|
boolean |
addRelationship(String dsId,
String subject,
String relationship,
String object,
boolean isLiteral,
String datatype)
Adds a RDF triple to the specified (RDF) datastream
|
void |
commit(String logMessage)
Saves the changes thus far to the permanent copy of the digital object.
|
void |
invalidate()
Marks this DOWriter handle invalid (unusable).
|
boolean |
isCommitted()
Marks whether the object has been successfully committed.
|
boolean |
isNew()
Marks whether the object is new.
|
String |
newAuditRecordID()
Generate a unique id for an audit record.
|
String |
newDatastreamID()
Generate a unique id for a datastream.
|
String |
newDatastreamID(String dsID)
Generate a unique id for a datastream version.
|
boolean |
purgeRelationship(String subject,
String relationship,
String object,
boolean isLiteral,
String datatype)
Purges a RDF triple from a reserved datastream (based on the subject)
|
boolean |
purgeRelationship(String dsId,
String subject,
String relationship,
String object,
boolean isLiteral,
String datatype)
Purges a RDF triple from the specified (RDF) datastream
|
void |
remove()
Removes the entire digital object.
|
Date[] |
removeDatastream(String id,
Date start,
Date end)
Removes a range of datastream versions from an object without leaving
anything behind.
|
void |
setDatastreamState(String id,
String state)
Sets the state for all versions of the specified datastream.
|
void |
setDatastreamVersionable(String id,
boolean versionable)
Sets the indicator as to whether the datastream is subject to versioning.
|
void |
setLabel(String label)
Sets the label of the digital object.
|
void |
setOwnerId(String ownerId)
Sets the ownerId for the digital object.
|
void |
setState(String state)
Sets the state of the entire digital object.
|
Export, ExportObject, getAuditRecords, getContentModels, getCreateDate, GetDatastream, getDatastream, GetDatastreams, getDatastreamVersions, getLastModDate, getObject, getObjectHistory, GetObjectLabel, GetObjectPID, GetObjectState, GetObjectXML, getOwnerId, getRelationships, getRelationships, getRelationships, hasContentModel, hasRelationship, hasRelationship, ListDatastreamIDs, listMethodsvoid setState(String state) throws ServerException
state - The state.ServerException - If any type of error occurred fulfilling the request.void setOwnerId(String ownerId) throws ServerException
ownerId - The ownerId.ServerException - If any type of error occurred fulfilling the request.void setDatastreamState(String id, String state) throws ServerException
id - The datastream id.state - The state.ServerException - If any type of error occurred fulfilling the request.void setDatastreamVersionable(String id, boolean versionable) throws ServerException
id - The datastream id.versionable - a boolean indicating if versionableServerException - If any type of error occurred fulfilling the request.void setLabel(String label) throws ServerException
label - The label.ServerException - If any type of error occurred fulfilling the request.void remove()
throws ServerException
ServerException - If any type of error occurred fulfilling the request.void addDatastream(Datastream datastream, boolean addNewVersion) throws ServerException
datastream - The datastream.ServerException - If any type of error occurred fulfilling the request.Date[] removeDatastream(String id, Date start, Date end) throws ServerException
id - The id of the datastream.start - The start date (inclusive) of versions to remove. If
null, this is taken to be the smallest possible
value.end - The end date (inclusive) of versions to remove. If
null, this is taken to be the greatest possible
value.ServerException - If any type of error occurred fulfilling the request.void commit(String logMessage) throws ServerException
logMessage - An explanation of the change(s).ServerException - If any type of error occurred fulfilling the request.void invalidate()
String newDatastreamID()
String newAuditRecordID()
boolean isCommitted()
boolean isNew()
boolean addRelationship(String subject, String relationship, String object, boolean isLiteral, String datatype) throws ServerException
ServerExceptionboolean addRelationship(String dsId, String subject, String relationship, String object, boolean isLiteral, String datatype) throws ServerException
ServerExceptionboolean purgeRelationship(String subject, String relationship, String object, boolean isLiteral, String datatype) throws ServerException
ServerExceptionboolean purgeRelationship(String dsId, String subject, String relationship, String object, boolean isLiteral, String datatype) throws ServerException
ServerExceptionCopyright © 2013 DuraSpace. All Rights Reserved.