edu.harvard.hul.ois.mets
Class Div

java.lang.Object
  extended byedu.harvard.hul.ois.mets.helper.MetsElement
      extended byedu.harvard.hul.ois.mets.helper.MetsVElement
          extended byedu.harvard.hul.ois.mets.helper.MetsIDElement
              extended byedu.harvard.hul.ois.mets.Div
All Implemented Interfaces:
MetsIdentifiable, MetsSerializable, MetsValidatable

public class Div
extends MetsIDElement

This class encapsulates the <div> element. See <http://www.loc.gov/standards/mets/>.


Field Summary
 
Fields inherited from class edu.harvard.hul.ois.mets.helper.MetsIDElement
_ID
 
Fields inherited from class edu.harvard.hul.ois.mets.helper.MetsVElement
_valid
 
Fields inherited from class edu.harvard.hul.ois.mets.helper.MetsElement
_attrs, _content, _localName, _namespace, _qName, _schema
 
Constructor Summary
Div()
          Instantiate a new Div object.
 
Method Summary
 java.util.Map getADMID()
          Return map of IDREFS to administrative metadata.
 java.util.List getCONTENTIDS()
          Return list of CONTENTIDS.
 java.util.Map getDMDID()
          Return map of IDREFS to descriptive metadata.
 java.lang.String getLABEL()
          Return division label.
 int getORDER()
          Return division order in integer representation.
 java.lang.String getORDERLABEL()
          Return division order label in string representation.
 java.lang.String getTYPE()
          Return division type.
 void read(MetsReader r)
          De-serialize the content of the file into this element using the given reader.
static Div reader(MetsReader r)
          Instantiate a Div object de-serialized from the input stream.
 void setADMID(java.lang.String ADMID)
          Set ADMID of AmdSec element.
 void setADMID(java.lang.String ADMID, MetsIDElement elem)
          Set ADMID of AmdSec element, with referenced element.
 void setCONTENTIDS(java.lang.String CONTENTIDS)
          Set CONTENTIDS.
 void setDMDID(java.lang.String DMDID)
          Set DMDID of DmdSec element.
 void setDMDID(java.lang.String DMDID, DmdSec elem)
          Set DMDID of DmdSec element, with referenced element.
 void setLABEL(java.lang.String LABEL)
          Set division label.
 void setORDER(int ORDER)
          Set division order label with integer representation.
 void setORDERLABEL(java.lang.String ORDERLABEL)
          Set division order label with string representation.
 void setTYPE(java.lang.String TYPE)
          Set division type.
 void validateThisIDREFs(MetsValidator v)
          Validate ID/IDREF consistency with the given validator.
 void write(MetsWriter w)
          Serialize the content of this element using the given writer.
 
Methods inherited from class edu.harvard.hul.ois.mets.helper.MetsIDElement
getID, setID
 
Methods inherited from class edu.harvard.hul.ois.mets.helper.MetsVElement
isValid, validate, validateIDREFs, validateThis
 
Methods inherited from class edu.harvard.hul.ois.mets.helper.MetsElement
getContent, getLocalName, getNamespace, getQName, getSchemas, init, setSchema, setSchema, writeSchemas
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Div

public Div()
Instantiate a new Div object.

Method Detail

getADMID

public java.util.Map getADMID()
Return map of IDREFS to administrative metadata.

Returns:
Map

getCONTENTIDS

public java.util.List getCONTENTIDS()
Return list of CONTENTIDS.

Returns:
List

getDMDID

public java.util.Map getDMDID()
Return map of IDREFS to descriptive metadata.

Returns:
Map

getLABEL

public java.lang.String getLABEL()
Return division label.

Returns:
Label

getORDER

public int getORDER()
             throws MetsException
Return division order in integer representation.

Returns:
Order
Throws:
MetsException

getORDERLABEL

public java.lang.String getORDERLABEL()
Return division order label in string representation.

Returns:
Label

getTYPE

public java.lang.String getTYPE()
Return division type.

Returns:
Type

setADMID

public void setADMID(java.lang.String ADMID)
Set ADMID of AmdSec element.

Parameters:
ADMID - Element IDREF

setADMID

public void setADMID(java.lang.String ADMID,
                     MetsIDElement elem)
Set ADMID of AmdSec element, with referenced element.

Parameters:
ADMID - Element IDREF
elem - Element (or NULL)

setCONTENTIDS

public void setCONTENTIDS(java.lang.String CONTENTIDS)
Set CONTENTIDS. Note: Currently there is no encoding/decoding being performed on the URIs. They are assummed to already be in appropriate form.

Parameters:
CONTENTIDS -

setDMDID

public void setDMDID(java.lang.String DMDID)
Set DMDID of DmdSec element.

Parameters:
DMDID - Element IDREF

setDMDID

public void setDMDID(java.lang.String DMDID,
                     DmdSec elem)
Set DMDID of DmdSec element, with referenced element.

Parameters:
DMDID - Element IDREF
elem - Element (or NULL)

setLABEL

public void setLABEL(java.lang.String LABEL)
Set division label.

Parameters:
LABEL - Label

setORDER

public void setORDER(int ORDER)
Set division order label with integer representation.

Parameters:
ORDER - Order

setORDERLABEL

public void setORDERLABEL(java.lang.String ORDERLABEL)
Set division order label with string representation.

Parameters:
ORDERLABEL - Label

setTYPE

public void setTYPE(java.lang.String TYPE)
Set division type.

Parameters:
TYPE - Type

reader

public static Div reader(MetsReader r)
                  throws MetsException
Instantiate a Div object de-serialized from the input stream.

Parameters:
r - Reader
Returns:
Div object
Throws:
MetsException - De-serializing exception

read

public void read(MetsReader r)
          throws MetsException
De-serialize the content of the file into this element using the given reader.

Specified by:
read in interface MetsSerializable
Specified by:
read in class MetsElement
Parameters:
r - Reader
Throws:
MetsException

write

public void write(MetsWriter w)
           throws MetsException
Serialize the content of this element using the given writer.

Specified by:
write in interface MetsSerializable
Specified by:
write in class MetsElement
Parameters:
w - Writer
Throws:
MetsException

validateThisIDREFs

public void validateThisIDREFs(MetsValidator v)
                        throws MetsException
Validate ID/IDREF consistency with the given validator.

Overrides:
validateThisIDREFs in class MetsVElement
Parameters:
v - Validator
Throws:
MetsException - Validation exception