edu.uiuc.ndiipp.hubandspoke.profile
Class HaSMETSValidator

java.lang.Object
  extended by edu.uiuc.ndiipp.hubandspoke.profile.HaSMETSValidator
Direct Known Subclasses:
HaSMETSWebValidator

public class HaSMETSValidator
extends java.lang.Object

Class with methods used to validate whether a METS document conforms to the Hub and Spoke METS profile or not

Author:
thabing

Constructor Summary
HaSMETSValidator()
           
 
Method Summary
 HaSMETSAppender getValidationProfileAppender()
           
 void setValidationProfileAppender(HaSMETSAppender app)
           
 boolean validateAquiferModsDocument(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mods.ModsModsDocument modsDoc)
          Validate the primary dmdSec MODS against the Aquifer MODS profile
 boolean validateDigiprovMDPremisEventForDmdSec(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsMdSecType dmd)
          Validate the digiprovMD Premis event for a dmdSec against the requirements of the METS HaS Profile
 boolean validateDigiprovMDPremisEventForFile(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsFileType ft)
          Validate the digiprovMD Premis event for a file against the requirements of the METS HaS Profile
 boolean validateDigiprovMDPremisEventForStructMap(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsStructMapType smap)
          Validate the digiprovMD Premis event for a structMap against the requirements of the METS HaS Profile
 boolean validateFiles(HaSMETSProfile metsP, METSProfile.PackageType pt, boolean openEachFile)
          Validate the file elements against the requirements of the METS HaS Profile
 boolean validatePrimaryStructMap(HaSMETSProfile metsP, METSProfile.PackageType pt)
          Validate the primary structMap against the requirements of the METS HaS Profile This always returns true because the base profile has no specific requirements for the primary structMap
 boolean validatePrimaryStructMapFptr(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsDivType div)
          Validate that the div of the PRIMARY_STRUCTMAP contains a valid fptr This always returns true because the base profile has no specific requirements for the primary structMap Fptrs
 boolean validateProfile(HaSMETSProfile metsP, METSProfile.PackageType pt)
          Validate the METS document against the requirements of the METS HaS Profile
 boolean validateProfile(HaSMETSProfile metsP, METSProfile.PackageType pt, boolean openEachFile)
          Validate the METS document against the requirements of the METS HaS Profile
 boolean validateTechMDPremisObjectForFile(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsFileType ft)
          Validate the techMD Premis object for a file against the requirements of the METS HaS Profile
 boolean validateTechMDPremisObjectForStructMap(HaSMETSProfile metsP, METSProfile.PackageType pt, gov.loc.mets.MetsStructMapType smap)
          Validate the techMD Premis object for a structMap against the requirements of the METS HaS Profile
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HaSMETSValidator

public HaSMETSValidator()
Method Detail

validateAquiferModsDocument

public boolean validateAquiferModsDocument(HaSMETSProfile metsP,
                                           METSProfile.PackageType pt,
                                           gov.loc.mods.ModsModsDocument modsDoc)
Validate the primary dmdSec MODS against the Aquifer MODS profile

Parameters:
metsP -
pt -
modsDoc -

validateProfile

public boolean validateProfile(HaSMETSProfile metsP,
                               METSProfile.PackageType pt)
Validate the METS document against the requirements of the METS HaS Profile

Parameters:
pt - The package type for the METS document, AIP, SIP, or DIP
Returns:
true if it is valid, else false

validateTechMDPremisObjectForStructMap

public boolean validateTechMDPremisObjectForStructMap(HaSMETSProfile metsP,
                                                      METSProfile.PackageType pt,
                                                      gov.loc.mets.MetsStructMapType smap)
Validate the techMD Premis object for a structMap against the requirements of the METS HaS Profile

Parameters:
smap - the MetsStructMapType for the structMap which references the techMD
Returns:
true if it is valid, else false

validateTechMDPremisObjectForFile

public boolean validateTechMDPremisObjectForFile(HaSMETSProfile metsP,
                                                 METSProfile.PackageType pt,
                                                 gov.loc.mets.MetsFileType ft)
Validate the techMD Premis object for a file against the requirements of the METS HaS Profile

Parameters:
ft - the MetsFileType for the file which references the techMD
Returns:
true if it is valid, else false

validatePrimaryStructMapFptr

public boolean validatePrimaryStructMapFptr(HaSMETSProfile metsP,
                                            METSProfile.PackageType pt,
                                            gov.loc.mets.MetsDivType div)
Validate that the div of the PRIMARY_STRUCTMAP contains a valid fptr This always returns true because the base profile has no specific requirements for the primary structMap Fptrs

Parameters:
div - the div whose fptr is neing validated
Returns:
true if it is valid, else false

validatePrimaryStructMap

public boolean validatePrimaryStructMap(HaSMETSProfile metsP,
                                        METSProfile.PackageType pt)
Validate the primary structMap against the requirements of the METS HaS Profile This always returns true because the base profile has no specific requirements for the primary structMap

Returns:
true if it is valid, else false

validateFiles

public boolean validateFiles(HaSMETSProfile metsP,
                             METSProfile.PackageType pt,
                             boolean openEachFile)
Validate the file elements against the requirements of the METS HaS Profile

Returns:
true if it is valid, else false

validateDigiprovMDPremisEventForStructMap

public boolean validateDigiprovMDPremisEventForStructMap(HaSMETSProfile metsP,
                                                         METSProfile.PackageType pt,
                                                         gov.loc.mets.MetsStructMapType smap)
Validate the digiprovMD Premis event for a structMap against the requirements of the METS HaS Profile

Parameters:
smap - the MetsStructMapType for the structMap which references the techMD
Returns:
true if it is valid, else false

validateDigiprovMDPremisEventForFile

public boolean validateDigiprovMDPremisEventForFile(HaSMETSProfile metsP,
                                                    METSProfile.PackageType pt,
                                                    gov.loc.mets.MetsFileType ft)
Validate the digiprovMD Premis event for a file against the requirements of the METS HaS Profile

Parameters:
ft - the MetsFileType for the file which references the techMD
Returns:
true if it is valid, else false

validateDigiprovMDPremisEventForDmdSec

public boolean validateDigiprovMDPremisEventForDmdSec(HaSMETSProfile metsP,
                                                      METSProfile.PackageType pt,
                                                      gov.loc.mets.MetsMdSecType dmd)
Validate the digiprovMD Premis event for a dmdSec against the requirements of the METS HaS Profile

Parameters:
dmd - the MetsMdSecType for the dmdSec which references the digiprovMD
Returns:
true if it is valid, else false

validateProfile

public boolean validateProfile(HaSMETSProfile metsP,
                               METSProfile.PackageType pt,
                               boolean openEachFile)
Validate the METS document against the requirements of the METS HaS Profile

Parameters:
pt - The package type for the METS document, AIP, SIP, or DIP
Returns:
true if it is valid, else false

setValidationProfileAppender

public void setValidationProfileAppender(HaSMETSAppender app)

getValidationProfileAppender

public HaSMETSAppender getValidationProfileAppender()


Copyright © 2006, University of Illinois.