public class MmdRec
extends java.lang.Object
implements java.lang.Comparable
Modifier and Type | Field and Description |
---|---|
static java.lang.String[] |
metastyleNames |
static int |
MS_ADN
Metadata style: adn
|
static int |
MS_BRIEFMETA
Metadata style: briefmeta
|
static int |
MS_DC_QUAL
Metadata style: dc_qual
|
static int |
MS_DC_SIMPLE
Metadata style: dc_simple
|
static int |
MS_DLESE_ANNO
Metadata style: dlese_anno
|
static int |
MS_DLESE_COLLECT
Metadata style: dlese_collect
|
static int |
MS_DLESE_IMS
Metadata style: dlese_ims
|
static int |
MS_NEWS_OPPS
Metadata style: news_opps
|
static int |
MS_NSDL_DC
Metadata style: nsdl_dc
|
static int |
MS_OAI_DC
Metadata style: oai_dc
|
static int |
MS_UNKNOWN
Metadata style: unknown (error)
|
static int |
STATUS_ACCESSIONED_DISCOVERABLE
Record status: accessioned and discoverable
|
static int |
STATUS_ACCESSIONED_NONDISCOVERABLE
Record status: accessioned and not discoverable
|
static int |
STATUS_DEACCESSIONED
Record status: deaccessioned
|
static int |
STATUS_NEW
Record status: new
|
static int |
STATUS_REJECTED
Record status: rejected
|
static int |
STATUS_UNKNOWN
Record status: unknown (error)
|
static java.lang.String[] |
statusNames |
Constructor and Description |
---|
MmdRec(java.lang.String collKey,
java.lang.String id,
java.lang.String fileName,
java.lang.String statusStg,
java.lang.String metastyleStg,
long firstAccessionDate,
long lastMetaModDate,
long recCheckDate,
java.lang.String primaryContent,
java.lang.String primarycontentType,
MmdWarning[] warnings)
Creates new MmdRec with the specified values.
|
Modifier and Type | Method and Description |
---|---|
static void |
checkStatusString(java.lang.String nm)
Checks that the specified nm is valid; if not throws MmdException.
|
int |
compareTo(java.lang.Object obj)
Implement Comparable interface
|
boolean |
equals(java.lang.Object obj)
Define equality for HashMap
|
java.lang.String |
getCollKey()
Returns the collection key.
|
java.lang.String |
getFileName()
Returns the file name of the record's XML file.
|
long |
getFirstAccessionDate()
Returns the date this record was first accessioned.
|
java.lang.String |
getId()
Returns the record id.
|
long |
getLastMetaModDate()
Returns the date this record was last changed.
|
int |
getMetastyle()
Returns the metadata format: for example, MS_ADN.
|
java.lang.String |
getMetastyleString()
Returns a string representing the metadata style, for example, "adn".
|
java.lang.String |
getPrimaryContent()
Gets the primaryContent attribute of the MmdRec object
and returns it after cleaning up the illegal character sequences "0x000d" and "0x0009"
|
java.lang.String |
getPrimaryContentType()
Gets the primaryContentType attribute of the MmdRec object
|
long |
getRecCheckDate()
Returns the date this record was last checked by the idmapper.
|
int |
getStatus()
Returns the record status: for example, STATUS_ACCESSIONED_DISCOVERABLE.
|
java.lang.String |
getStatusString()
Returns a string representing the record status, for example,
"accessioneddiscoverable".
|
MmdWarning[] |
getWarnings()
Returns an array of MmdWarning for messages generated during the most recent Idmapper
run.
|
java.lang.String |
toString() |
public static final int STATUS_UNKNOWN
public static final int STATUS_ACCESSIONED_DISCOVERABLE
public static final int STATUS_ACCESSIONED_NONDISCOVERABLE
public static final int STATUS_DEACCESSIONED
public static final int STATUS_NEW
public static final int STATUS_REJECTED
public static final java.lang.String[] statusNames
public static final int MS_UNKNOWN
public static final int MS_ADN
public static final int MS_BRIEFMETA
public static final int MS_DC_QUAL
public static final int MS_DC_SIMPLE
public static final int MS_DLESE_ANNO
public static final int MS_DLESE_COLLECT
public static final int MS_DLESE_IMS
public static final int MS_NSDL_DC
public static final int MS_NEWS_OPPS
public static final int MS_OAI_DC
public static final java.lang.String[] metastyleNames
public MmdRec(java.lang.String collKey, java.lang.String id, java.lang.String fileName, java.lang.String statusStg, java.lang.String metastyleStg, long firstAccessionDate, long lastMetaModDate, long recCheckDate, java.lang.String primaryContent, java.lang.String primarycontentType, MmdWarning[] warnings) throws MmdException
collKey
- DESCRIPTIONid
- DESCRIPTIONfileName
- DESCRIPTIONstatusStg
- DESCRIPTIONmetastyleStg
- DESCRIPTIONfirstAccessionDate
- DESCRIPTIONlastMetaModDate
- DESCRIPTIONrecCheckDate
- DESCRIPTIONprimaryContent
- DESCRIPTIONprimarycontentType
- DESCRIPTIONwarnings
- DESCRIPTIONMmdException
- DESCRIPTIONpublic java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String getPrimaryContent()
public java.lang.String getPrimaryContentType()
public java.lang.String getCollKey()
public java.lang.String getId()
public java.lang.String getFileName()
public int getStatus()
public java.lang.String getStatusString()
public static void checkStatusString(java.lang.String nm) throws MmdException
nm
- DESCRIPTIONMmdException
- DESCRIPTIONpublic int getMetastyle()
public java.lang.String getMetastyleString()
public long getFirstAccessionDate()
public long getLastMetaModDate()
public long getRecCheckDate()
public MmdWarning[] getWarnings()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- DESCRIPTIONpublic int compareTo(java.lang.Object obj)
compareTo
in interface java.lang.Comparable
obj
- DESCRIPTION