org.openmrs
Class BaseOpenmrsMetadata

java.lang.Object
  extended by org.openmrs.BaseOpenmrsObject
      extended by org.openmrs.BaseOpenmrsMetadata
All Implemented Interfaces:
Auditable, OpenmrsMetadata, OpenmrsObject, Retireable
Direct Known Subclasses:
ActiveListType, ConceptClass, ConceptDatatype, ConceptSource, Drug, EncounterType, Field, FieldType, Form, FormField, HL7Source, Location, LocationTag, MimeType, OrderType, PatientIdentifierType, PersonAttributeType, Privilege, Program, ProgramWorkflow, ProgramWorkflowState, RelationshipType, ReportSchema, Role, SerializedObject, TaskDefinition, User

public abstract class BaseOpenmrsMetadata
extends BaseOpenmrsObject
implements OpenmrsMetadata

In OpenMRS, we distinguish between data and metadata within our data model. Metadata represent system and descriptive data such as data types — a relationship type or encounter type. Metadata are generally referenced by clinical data but don't represent patient-specific data themselves. This provides a default abstract implementation of the OpenmrsMetadata interface

Since:
1.5
See Also:
OpenmrsMetadata

Constructor Summary
BaseOpenmrsMetadata()
          Default Constructor
 
Method Summary
 User getChangedBy()
           
 User getCreator()
           
 java.util.Date getDateChanged()
           
 java.util.Date getDateCreated()
           
 java.util.Date getDateRetired()
           
 java.lang.String getDescription()
           
 java.lang.String getName()
           
 java.lang.Boolean getRetired()
          This method delegates to isRetired().
 User getRetiredBy()
           
 java.lang.String getRetireReason()
           
 java.lang.Boolean isRetired()
           
 void setChangedBy(User changedBy)
           
 void setCreator(User creator)
           
 void setDateChanged(java.util.Date dateChanged)
           
 void setDateCreated(java.util.Date dateCreated)
           
 void setDateRetired(java.util.Date dateRetired)
           
 void setDescription(java.lang.String description)
           
 void setName(java.lang.String name)
           
 void setRetired(java.lang.Boolean retired)
           
 void setRetiredBy(User retiredBy)
           
 void setRetireReason(java.lang.String retireReason)
           
 
Methods inherited from class org.openmrs.BaseOpenmrsObject
getUuid, setUuid
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.openmrs.OpenmrsObject
getId, getUuid, setId, setUuid
 

Constructor Detail

BaseOpenmrsMetadata

public BaseOpenmrsMetadata()
Default Constructor

Method Detail

getName

public java.lang.String getName()
Specified by:
getName in interface OpenmrsMetadata
Returns:
the name

setName

public void setName(java.lang.String name)
Specified by:
setName in interface OpenmrsMetadata
Parameters:
name - the name to set

getDescription

public java.lang.String getDescription()
Specified by:
getDescription in interface OpenmrsMetadata
Returns:
the description

setDescription

public void setDescription(java.lang.String description)
Specified by:
setDescription in interface OpenmrsMetadata
Parameters:
description - the description to set

getCreator

public User getCreator()
Specified by:
getCreator in interface Auditable
Returns:
User - the user who created the object
See Also:
Auditable.getCreator()

setCreator

public void setCreator(User creator)
Specified by:
setCreator in interface Auditable
Parameters:
creator - - the user who created the object
See Also:
Auditable.setCreator(org.openmrs.User)

getDateCreated

public java.util.Date getDateCreated()
Specified by:
getDateCreated in interface Auditable
Returns:
Date - the date the object was created
See Also:
Auditable.getDateCreated()

setDateCreated

public void setDateCreated(java.util.Date dateCreated)
Specified by:
setDateCreated in interface Auditable
Parameters:
dateCreated - - the date the object was created
See Also:
Auditable.setDateCreated(java.util.Date)

getChangedBy

public User getChangedBy()
Specified by:
getChangedBy in interface Auditable
Returns:
User - the user who last changed the object
See Also:
Auditable.getChangedBy()

setChangedBy

public void setChangedBy(User changedBy)
Specified by:
setChangedBy in interface Auditable
Parameters:
changedBy - - the user who last changed the object
See Also:
Auditable.setChangedBy(org.openmrs.User)

getDateChanged

public java.util.Date getDateChanged()
Specified by:
getDateChanged in interface Auditable
Returns:
Date - the date the object was last changed
See Also:
Auditable.getDateChanged()

setDateChanged

public void setDateChanged(java.util.Date dateChanged)
Specified by:
setDateChanged in interface Auditable
Parameters:
dateChanged - - the date the object was last changed
See Also:
Auditable.setDateChanged(java.util.Date)

isRetired

public java.lang.Boolean isRetired()
Specified by:
isRetired in interface Retireable
Returns:
Boolean - whether of not this object is retired
See Also:
Retireable.isRetired()

getRetired

public java.lang.Boolean getRetired()
This method delegates to isRetired(). This is only needed for jstl syntax like ${fieldType.retired} because the return type is a Boolean object instead of a boolean primitive type.

See Also:
Retireable.isRetired()

setRetired

public void setRetired(java.lang.Boolean retired)
Specified by:
setRetired in interface Retireable
Parameters:
retired - - whether of not this object is retired
See Also:
Retireable.setRetired(java.lang.Boolean)

getDateRetired

public java.util.Date getDateRetired()
Specified by:
getDateRetired in interface Retireable
Returns:
Date - the date the object was retired
See Also:
Retireable.getDateRetired()

setDateRetired

public void setDateRetired(java.util.Date dateRetired)
Specified by:
setDateRetired in interface Retireable
Parameters:
dateRetired - - the date the object was retired
See Also:
Retireable.setDateRetired(java.util.Date)

getRetiredBy

public User getRetiredBy()
Specified by:
getRetiredBy in interface Retireable
Returns:
User - the user who retired the object
See Also:
Retireable.getRetiredBy()

setRetiredBy

public void setRetiredBy(User retiredBy)
Specified by:
setRetiredBy in interface Retireable
Parameters:
retiredBy - - the user who retired the object
See Also:
Retireable.setRetiredBy(org.openmrs.User)

getRetireReason

public java.lang.String getRetireReason()
Specified by:
getRetireReason in interface Retireable
Returns:
String - the reason the object was retired
See Also:
Retireable.getRetireReason()

setRetireReason

public void setRetireReason(java.lang.String retireReason)
Specified by:
setRetireReason in interface Retireable
Parameters:
retireReason - - the reason the object was retired
See Also:
Retireable.setRetireReason(java.lang.String)

OpenMRS-1.7.x

Generated Apr 27 2012 10:06 PM. NOTE - these libraries are in active development and subject to change