Package org.dspace.content
Class InstallItemServiceImpl
java.lang.Object
org.dspace.content.InstallItemServiceImpl
- All Implemented Interfaces:
InstallItemService
Support to install an Item in the archive.
- Version:
- $Revision$
- Author:
- dstuve
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected CollectionServiceprotected ConfigurationServiceprotected ContentServiceFactoryprotected EmbargoServiceprotected IdentifierServiceprotected ItemServiceprotected SupervisionOrderService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ItemfinishItem(Context c, Item item, InProgressSubmission is) Final housekeeping when adding a new Item into the archive.getBitstreamProvenanceMessage(Context context, Item myitem) Generate provenance-worthy description of the bitstreams contained in an item.getSubmittedByProvenanceMessage(Context context, Item item) Generate provenance description of direct item submission (not through workflow).Take an InProgressSubmission and turn it into a fully-archived Item, creating a new Handle.installItem(Context c, InProgressSubmission is, String suppliedHandle) Take an InProgressSubmission and turn it into a fully-archived Item.protected voidpopulateMetadata(Context c, Item item) restoreItem(Context c, InProgressSubmission is, String suppliedHandle) Turn an InProgressSubmission into a fully-archived Item, for a "restore" operation such as ingestion of an AIP to recreate an archive.
-
Field Details
-
contentServiceFactory
-
collectionService
-
embargoService
-
identifierService
-
itemService
-
supervisionOrderService
-
configurationService
-
-
Constructor Details
-
InstallItemServiceImpl
protected InstallItemServiceImpl()
-
-
Method Details
-
installItem
Description copied from interface:InstallItemServiceTake an InProgressSubmission and turn it into a fully-archived Item, creating a new Handle.- Specified by:
installItemin interfaceInstallItemService- Parameters:
c- DSpace Contextis- submission to install- Returns:
- the fully archived Item
- Throws:
SQLException- if database errorAuthorizeException- if authorization error
-
installItem
public Item installItem(Context c, InProgressSubmission is, String suppliedHandle) throws SQLException, AuthorizeException Description copied from interface:InstallItemServiceTake an InProgressSubmission and turn it into a fully-archived Item.- Specified by:
installItemin interfaceInstallItemService- Parameters:
c- current contextis- submission to installsuppliedHandle- the existing Handle to give to the installed item- Returns:
- the fully archived Item
- Throws:
SQLException- if database errorAuthorizeException- if authorization error
-
restoreItem
public Item restoreItem(Context c, InProgressSubmission is, String suppliedHandle) throws SQLException, IOException, AuthorizeException Description copied from interface:InstallItemServiceTurn an InProgressSubmission into a fully-archived Item, for a "restore" operation such as ingestion of an AIP to recreate an archive. This does NOT add any descriptive metadata (e.g. for provenance) to preserve the transparency of the ingest. The ingest mechanism is assumed to have set all relevant technical and administrative metadata fields.- Specified by:
restoreItemin interfaceInstallItemService- Parameters:
c- current contextis- submission to installsuppliedHandle- the existing Handle to give the installed item, or null to create a new one.- Returns:
- the fully archived Item
- Throws:
SQLException- if database errorIOException- if IO errorAuthorizeException- if authorization error
-
populateMetadata
- Throws:
SQLExceptionAuthorizeException
-
finishItem
protected Item finishItem(Context c, Item item, InProgressSubmission is) throws SQLException, AuthorizeException Final housekeeping when adding a new Item into the archive. This method is used by *both* installItem() and restoreItem(), so all actions here will be run for a newly added item or a restored item.- Parameters:
c- DSpace Contextitem- Item in questionis- InProgressSubmission object- Returns:
- final "archived" Item
- Throws:
SQLException- if database errorAuthorizeException- if authorization error
-
getBitstreamProvenanceMessage
Description copied from interface:InstallItemServiceGenerate provenance-worthy description of the bitstreams contained in an item.- Specified by:
getBitstreamProvenanceMessagein interfaceInstallItemService- Parameters:
context- contextmyitem- the item to generate description for- Returns:
- provenance description
- Throws:
SQLException- if database error
-
getSubmittedByProvenanceMessage
Description copied from interface:InstallItemServiceGenerate provenance description of direct item submission (not through workflow).- Specified by:
getSubmittedByProvenanceMessagein interfaceInstallItemService- Parameters:
context- contextitem- the item to generate description for- Returns:
- provenance description
- Throws:
SQLException- if database error
-