public class PatientState extends BaseOpenmrsData implements java.io.Serializable, java.lang.Comparable<PatientState>
| Modifier and Type | Field and Description |
|---|---|
static long |
serialVersionUID |
creator| Constructor and Description |
|---|
PatientState()
Default Constructor
|
PatientState(java.lang.Integer patientStateId)
Constructor with id
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(PatientState o)
Compares by startDate with null as earliest and endDate with null as latest.
|
PatientState |
copy()
Does a shallow copy of this PatientState.
|
protected PatientState |
copyHelper(PatientState target)
The purpose of this method is to allow subclasses of PatientState to delegate a portion of
their copy() method back to the superclass, in case the base class implementation changes.
|
boolean |
getActive()
Returns true if this
PatientState is currently active |
boolean |
getActive(java.util.Date onDate)
Returns true if this
PatientState is active as of the passed Date |
java.util.Date |
getEndDate() |
java.lang.Integer |
getId() |
PatientProgram |
getPatientProgram() |
java.lang.Integer |
getPatientStateId() |
java.util.Date |
getStartDate() |
ProgramWorkflowState |
getState() |
void |
setEndDate(java.util.Date endDate) |
void |
setId(java.lang.Integer id) |
void |
setPatientProgram(PatientProgram patientProgram) |
void |
setPatientStateId(java.lang.Integer patientStatusId) |
void |
setStartDate(java.util.Date startDate) |
void |
setState(ProgramWorkflowState state) |
java.lang.String |
toString()
Returns a string consisting of the name of the class of which the object is an instance and
the
uuid field surrounded by [ and ]. |
getChangedBy, getCreator, getDateChanged, getDateCreated, getDateVoided, getVoided, getVoidedBy, getVoidReason, isVoided, setChangedBy, setCreator, setDateChanged, setDateCreated, setDateVoided, setVoided, setVoidedBy, setVoidReasonequals, getUuid, hashCode, setUuidclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetUuid, setUuidpublic static final long serialVersionUID
public PatientState()
public PatientState(java.lang.Integer patientStateId)
public PatientState copy()
protected PatientState copyHelper(PatientState target)
target - a PatientState that will have the state of this copied into itpublic boolean getActive(java.util.Date onDate)
PatientState is active as of the passed DateonDate - - Date to check for PatientState enrollmentPatientState is active as of the passed Datepublic boolean getActive()
PatientState is currently activePatientState is currently activepublic java.lang.String toString()
BaseOpenmrsObjectuuid field surrounded by [ and ]. In other words,
this method returns a string equal to the value of: getClass().getName() + '[' + uuid + ']'
If the uuid field is null, it delegates to
Object.toString()
toString in class BaseOpenmrsObjectObject.toString()public PatientProgram getPatientProgram()
public void setPatientProgram(PatientProgram patientProgram)
public java.lang.Integer getPatientStateId()
public void setPatientStateId(java.lang.Integer patientStatusId)
public ProgramWorkflowState getState()
public void setState(ProgramWorkflowState state)
public java.util.Date getEndDate()
public void setEndDate(java.util.Date endDate)
public java.util.Date getStartDate()
public void setStartDate(java.util.Date startDate)
public java.lang.Integer getId()
getId in interface OpenmrsObjectOpenmrsObject.getId()public void setId(java.lang.Integer id)
setId in interface OpenmrsObjectid - - The unique Identifier for the objectOpenmrsObject.setId(java.lang.Integer)public int compareTo(PatientState o)
compareTo in interface java.lang.Comparable<PatientState>Comparable.compareTo(java.lang.Object)Copyright © 2018 OpenMRS Inc.. All Rights Reserved.