edu.uiuc.ndiipp.hubandspoke.utils.jhove
Class TrivialPremisIDGenerator
java.lang.Object
edu.uiuc.ndiipp.hubandspoke.utils.jhove.PremisIDGenerator
edu.uiuc.ndiipp.hubandspoke.utils.jhove.TrivialPremisIDGenerator
public class TrivialPremisIDGenerator
- extends PremisIDGenerator
This is a trivial PREMIS id generator. For the id type it always returns "FilePath"
and for the actual id just the path of the file.
Note that it does _not_ use the OBJECTID if present in the file section (which technically
should happen, but doesn't really make sense unless we also actually know how to
get the id type).
This is really only intended for testing; for real use you need to subclass
PremisIDGenerator yourself and make it work correctly for your situation.
- Author:
- Howard Ding
|
Method Summary |
java.lang.String |
idType(java.lang.String filePath,
edu.harvard.hul.ois.mets.File file)
|
java.lang.String |
idValue(java.lang.String filePath,
edu.harvard.hul.ois.mets.File file)
|
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TrivialPremisIDGenerator
public TrivialPremisIDGenerator()
idType
public java.lang.String idType(java.lang.String filePath,
edu.harvard.hul.ois.mets.File file)
- Specified by:
idType in class PremisIDGenerator
- Parameters:
filePath - - path to the filefile - - Harvard METS API File object from the METS file
- Returns:
- - PREMIS id type - here trivially "FilePath"
idValue
public java.lang.String idValue(java.lang.String filePath,
edu.harvard.hul.ois.mets.File file)
- Specified by:
idValue in class PremisIDGenerator
- Parameters:
filePath - - path to the filefile - - Harvard METS API File object from the METS file
- Returns:
- - PREMIS id value - here trivially the path to the file
Copyright © 2006, University of Illinois.