edu.harvard.hul.ois.mets
Class Behavior

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.Behavior
All Implemented Interfaces:
MetsIdentifiable, MetsSerializable, MetsValidatable

public class Behavior
extends MetsIDElement

This class encapsulates the <behavior> 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
Behavior()
          Instantiate a new behavior object.
 
Method Summary
 java.util.Map getADMID()
          Return map of IDREFS to amdSecs.
 java.lang.String getBTYPE()
          Return behavior type.
 java.util.Date getCREATED()
          Return creation date/time of this behavior.
 java.lang.String getGROUPID()
          Return behavior group ID.
 java.lang.String getLABEL()
          Return behavior label.
 java.util.Map getSTRUCTID()
          Return map of IDREFS to structMap and divs.
 void read(MetsReader r)
          De-serialize the content of the file into this element using the given reader.
static Behavior reader(MetsReader r)
          Instantiate a Behavior 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 setBTYPE(java.lang.String type)
          Set behavior type.
 void setCREATED(java.util.Date date)
          Set creation date/time of this behavior.
 void setGROUPID(java.lang.String id)
          Set behavior group ID.
 void setLABEL(java.lang.String label)
          Set behavior label.
 void setSTRUCTID(java.lang.String STRUCTID)
          Set STRUCTID of StructMap.
 void setSTRUCTID(java.lang.String STRUCTID, MetsIDElement elem)
          Set STRUCTID of StructMap element, with referenced element.
 void validateThis(MetsValidator v)
          Validate this element and its content model using the given validator.
 void validateThisIDREFs(MetsValidator v)
          Validate ID/IDREF consistency using the given validator.
 void write(MetsWriter w)
          Serialize this element and its content model 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
 
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

Behavior

public Behavior()
Instantiate a new behavior object.

Method Detail

getADMID

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

Returns:
Map

getBTYPE

public java.lang.String getBTYPE()
Return behavior type.

Returns:
Type

getSTRUCTID

public java.util.Map getSTRUCTID()
Return map of IDREFS to structMap and divs.

Returns:
Map

getCREATED

public java.util.Date getCREATED()
Return creation date/time of this behavior.

Returns:
Date/time

getGROUPID

public java.lang.String getGROUPID()
Return behavior group ID.

Returns:
Group ID

getLABEL

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

Returns:
Label

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)

setBTYPE

public void setBTYPE(java.lang.String type)
Set behavior type.

Parameters:
type - Type

setCREATED

public void setCREATED(java.util.Date date)
Set creation date/time of this behavior.

Parameters:
date - Date/time

setGROUPID

public void setGROUPID(java.lang.String id)
Set behavior group ID.

Parameters:
id - Group ID

setLABEL

public void setLABEL(java.lang.String label)
Set behavior label.

Parameters:
label - Label

setSTRUCTID

public void setSTRUCTID(java.lang.String STRUCTID)
Set STRUCTID of StructMap.

Parameters:
STRUCTID - StructMap IDREF

setSTRUCTID

public void setSTRUCTID(java.lang.String STRUCTID,
                        MetsIDElement elem)
Set STRUCTID of StructMap element, with referenced element.

Parameters:
STRUCTID - StructMap element IDREF
elem - Element (or NULL)

reader

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

Parameters:
r - Reader
Returns:
Behaviour 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 this element and its content model using the given writer

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

validateThis

public void validateThis(MetsValidator v)
                  throws MetsException
Validate this element and its content model using the given validator.

Specified by:
validateThis in interface MetsValidatable
Overrides:
validateThis in class MetsVElement
Parameters:
v - Validator
Throws:
MetsException - Validation exception

validateThisIDREFs

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

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