DLESE Tools
v1.2

org.dlese.dpc.services.mmd
Class MmdRecord

java.lang.Object
  extended byorg.dlese.dpc.services.mmd.MmdRecord
All Implemented Interfaces:
Comparable

public class MmdRecord
extends Object
implements Comparable

Describes a single Id.


Field Summary
static int CHANGE_ADDED
           
static int CHANGE_ASSOC
           
static int CHANGE_DELETED
           
static int CHANGE_MMD
           
static int CHANGE_NONE
           
static String MS_ADN
           
static String MS_BRIEFMETA
           
static String MS_DC_QUAL
           
static String MS_DC_SIMPLE
           
static String MS_DLESE_ANNO
           
static String MS_DLESE_COLLECT
           
static String MS_DLESE_IMS
           
static String MS_NEWS_OPPS
           
static String MS_NSDL_DC
           
static String MS_OAI_DC
           
static String STATUS_ACCESSIONED
           
static String STATUS_DEACCESSIONED
           
static String STATUS_HOLDING
           
static String STATUS_REWORK
           
static String STATUS_SUBMITTED
           
static String[] validStatus
           
 
Constructor Summary
MmdRecord(int changeType, String collKey, String id, String fileName, String statusStg, String metastyleStg, long firstAccessionDate, long lastMetaModDate, long recCheckDate, ErrorDesc[] errs)
           
MmdRecord(String collKey, String id, String fileName, String statusStg, String metastyleStg, long firstAccessionDate, long lastMetaModDate, long recCheckDate, ErrorDesc[] errs)
           
 
Method Summary
static void checkMetastyle(String testmetastyle)
           
static void checkStatus(String teststatus)
           
 int compareTo(Object obj)
           
 boolean equals(Object obj)
           
 int getChangeType()
           
 String getCollKey()
          Returns the collection key.
 ErrorDesc[] getErrors()
          Returns an array of ErrorDesc for messages generated during the most recent Idmapper run.
 String getFileName()
          Returns the file name of the record's XML file.
 long getFirstAccessionDate()
          Returns the date it was first accessioned.
 String getId()
          Returns the record id.
 long getLastMetaModDate()
          Returns the date it was last changed.
 String getMetastyle()
          Returns the metadata format: "adn", etc.
 long getRecCheckDate()
          Returns the date it was last checked by the idmapper.
 String getStatus()
          Returns the record status: "submitted", etc.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CHANGE_NONE

public static final int CHANGE_NONE
See Also:
Constant Field Values

CHANGE_ADDED

public static final int CHANGE_ADDED
See Also:
Constant Field Values

CHANGE_DELETED

public static final int CHANGE_DELETED
See Also:
Constant Field Values

CHANGE_MMD

public static final int CHANGE_MMD
See Also:
Constant Field Values

CHANGE_ASSOC

public static final int CHANGE_ASSOC
See Also:
Constant Field Values

STATUS_SUBMITTED

public static final String STATUS_SUBMITTED
See Also:
Constant Field Values

STATUS_ACCESSIONED

public static final String STATUS_ACCESSIONED
See Also:
Constant Field Values

STATUS_HOLDING

public static final String STATUS_HOLDING
See Also:
Constant Field Values

STATUS_REWORK

public static final String STATUS_REWORK
See Also:
Constant Field Values

STATUS_DEACCESSIONED

public static final String STATUS_DEACCESSIONED
See Also:
Constant Field Values

validStatus

public static final String[] validStatus

MS_ADN

public static final String MS_ADN
See Also:
Constant Field Values

MS_BRIEFMETA

public static final String MS_BRIEFMETA
See Also:
Constant Field Values

MS_DC_QUAL

public static final String MS_DC_QUAL
See Also:
Constant Field Values

MS_DC_SIMPLE

public static final String MS_DC_SIMPLE
See Also:
Constant Field Values

MS_DLESE_ANNO

public static final String MS_DLESE_ANNO
See Also:
Constant Field Values

MS_DLESE_COLLECT

public static final String MS_DLESE_COLLECT
See Also:
Constant Field Values

MS_DLESE_IMS

public static final String MS_DLESE_IMS
See Also:
Constant Field Values

MS_NSDL_DC

public static final String MS_NSDL_DC
See Also:
Constant Field Values

MS_NEWS_OPPS

public static final String MS_NEWS_OPPS
See Also:
Constant Field Values

MS_OAI_DC

public static final String MS_OAI_DC
See Also:
Constant Field Values
Constructor Detail

MmdRecord

public MmdRecord(int changeType,
                 String collKey,
                 String id,
                 String fileName,
                 String statusStg,
                 String metastyleStg,
                 long firstAccessionDate,
                 long lastMetaModDate,
                 long recCheckDate,
                 ErrorDesc[] errs)
          throws MmdException

MmdRecord

public MmdRecord(String collKey,
                 String id,
                 String fileName,
                 String statusStg,
                 String metastyleStg,
                 long firstAccessionDate,
                 long lastMetaModDate,
                 long recCheckDate,
                 ErrorDesc[] errs)
          throws MmdException
Method Detail

toString

public String toString()

getChangeType

public int getChangeType()

getCollKey

public String getCollKey()
Returns the collection key.


getId

public String getId()
Returns the record id.


getFileName

public String getFileName()
Returns the file name of the record's XML file.


getStatus

public String getStatus()
Returns the record status: "submitted", etc. Must be one of the STATUS_ values above.


getMetastyle

public String getMetastyle()
Returns the metadata format: "adn", etc. Must be one of the MS_ values above.


getFirstAccessionDate

public long getFirstAccessionDate()
Returns the date it was first accessioned.


getLastMetaModDate

public long getLastMetaModDate()
Returns the date it was last changed.


getRecCheckDate

public long getRecCheckDate()
Returns the date it was last checked by the idmapper.


getErrors

public ErrorDesc[] getErrors()
Returns an array of ErrorDesc for messages generated during the most recent Idmapper run.


checkStatus

public static void checkStatus(String teststatus)
                        throws MmdException
Throws:
MmdException

checkMetastyle

public static void checkMetastyle(String testmetastyle)
                           throws MmdException
Throws:
MmdException

equals

public boolean equals(Object obj)

compareTo

public int compareTo(Object obj)
Specified by:
compareTo in interface Comparable

DLESE Tools
v1.2