|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dspace.content.packager.AbstractMETSIngester
org.dspace.content.packager.DSpaceMETSIngester
public class DSpaceMETSIngester
Packager plugin to ingest a METS (Metadata Encoding & Transmission Standard) package that conforms to the DSpace METS SIP (Submission Information Package) Profile. See http://www.loc.gov/standards/mets/ for more information on METS, and http://www.dspace.org/standards/METS/SIP/profilev0p9p1/metssipv0p9p1.pdf (or a similar file in the /standards/METS/SIP resource hierarchy) for more information about the DSpace METS SIP profile.
METSManifest| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.dspace.content.packager.AbstractMETSIngester |
|---|
AbstractMETSIngester.MdrefManager |
| Field Summary |
|---|
| Fields inherited from class org.dspace.content.packager.AbstractMETSIngester |
|---|
MANIFEST_FILE |
| Constructor Summary | |
|---|---|
DSpaceMETSIngester()
|
|
| Method Summary | |
|---|---|
void |
addLicense(Context context,
Collection collection,
Item item,
METSManifest manifest,
AbstractMETSIngester.MdrefManager callback,
String license)
Policy: For DSpace deposit license, take deposit license supplied by explicit argument first, else use collection's default deposit license. |
void |
checkPackageFiles(Set packageFiles,
Set missingFiles,
METSManifest manifest)
Hook for subclass to modify the test of the package's integrity, and add other tests. |
void |
chooseItemDmd(Context context,
Item item,
METSManifest manifest,
AbstractMETSIngester.MdrefManager callback,
org.jdom.Element[] dmds,
PackageParameters params)
Choose DMD section(s) to crosswalk. |
void |
finishItem(Context context,
Item item)
Hook for final "finishing" operations on the new Item. |
| Methods inherited from class org.dspace.content.packager.AbstractMETSIngester |
|---|
ingest, replace |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DSpaceMETSIngester()
| Method Detail |
|---|
public void checkPackageFiles(Set packageFiles,
Set missingFiles,
METSManifest manifest)
throws PackageValidationException,
CrosswalkException
AbstractMETSIngester
The packageFiles contains "extra" files that were in
the package but were not referenced by the METS manifest (either as
content or metadata (mdRefs)).
The implementation of this method should look for any "extra" files
uses (e.g. a checksum or cryptographic signature for the manifest
itself) and remove them from the Set.
The missingFiles set is for
any files
referenced by the manifest but not found in the package.
The implementation can check it for "false positives", or add
other missing files it knows of.
If either of the Sets missingFiles
or packageFiles
is not empty, the ingest will fail.
checkPackageFiles in class AbstractMETSIngesterpackageFiles - files in package but not referenced by METSmissingFiles - files referenced by manifest but not in package
PackageValidationException
CrosswalkException
public void chooseItemDmd(Context context,
Item item,
METSManifest manifest,
AbstractMETSIngester.MdrefManager callback,
org.jdom.Element[] dmds,
PackageParameters params)
throws CrosswalkException,
AuthorizeException,
SQLException,
IOException
The algorithm is:
1. Use whatever the dmd parameter specifies as the primary DMD.
2. If (1) is unspecified, find MODS (preferably) or DC as primary DMD.
3. If (1) or (2) succeeds, crosswalk it and ignore all other DMDs with
same GROUPID
4. Crosswalk remaining DMDs not eliminated already.
chooseItemDmd in class AbstractMETSIngestercontext - the DSpace contextitem - the DSpace itemmanifest - the METSManifestcallback - the MdrefManager (manages all external metadata files referenced by METS mdref elements)dmds - array of Elements, each a METS dmdSec that applies to the Item as a whole.params - any user parameters passed to the Packager script
CrosswalkException
AuthorizeException
SQLException
IOException
public void addLicense(Context context,
Collection collection,
Item item,
METSManifest manifest,
AbstractMETSIngester.MdrefManager callback,
String license)
throws PackageValidationException,
CrosswalkException,
AuthorizeException,
SQLException,
IOException
addLicense in class AbstractMETSIngestercontext - the DSpace contextcollection - DSpace Collection to which the item is being submitted.license - optional user-supplied Deposit License text (may be null)
PackageValidationException
CrosswalkException
AuthorizeException
SQLException
IOException
public void finishItem(Context context,
Item item)
throws PackageValidationException,
CrosswalkException,
AuthorizeException,
SQLException,
IOException
AbstractMETSIngester
finishItem in class AbstractMETSIngestercontext - the DSpace context
PackageValidationException
CrosswalkException
AuthorizeException
SQLException
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||