private Date dateChanged(BaseOpenmrsMetadata d){
  Date dateChanged=d.getDateChanged();
  if (dateChanged != null)   return dateChanged;
  return d.getDateCreated();
}

private Date dateChanged ( BaseOpenmrsMetadata d ) { Date dateChanged = d . getDateChanged ( ) ; if ( dateChanged != null ) return dateChanged ; return d . getDateCreated ( ) ; }
returns the actual last modification time of an openmrs object . because openmrs doesn ' t set the modification time upon initial creation ( sigh ) we have to check both datechanged and datecreated .
