/**
  * @return array
  */
 public function jsonSerialize()
 {
     $json = parent::jsonSerialize();
     if (null !== $this->status) {
         $json['status'] = $this->status->jsonSerialize();
     }
     if (null !== $this->description) {
         $json['description'] = $this->description->jsonSerialize();
     }
     if (null !== $this->dateTime) {
         $json['dateTime'] = $this->dateTime->jsonSerialize();
     }
     if (null !== $this->actor) {
         $json['actor'] = $this->actor->jsonSerialize();
     }
     return $json;
 }
 /**
  * @return array
  */
 public function jsonSerialize()
 {
     $json = parent::jsonSerialize();
     if (null !== $this->code) {
         $json['code'] = $this->code->jsonSerialize();
     }
     if (0 < count($this->specimen)) {
         $json['specimen'] = array();
         foreach ($this->specimen as $specimen) {
             $json['specimen'][] = $specimen->jsonSerialize();
         }
     }
     if (null !== $this->bodySite) {
         $json['bodySite'] = $this->bodySite->jsonSerialize();
     }
     if (null !== $this->status) {
         $json['status'] = $this->status->jsonSerialize();
     }
     if (0 < count($this->event)) {
         $json['event'] = array();
         foreach ($this->event as $event) {
             $json['event'][] = $event->jsonSerialize();
         }
     }
     return $json;
 }
 /**
  * @return array
  */
 public function jsonSerialize()
 {
     $json = parent::jsonSerialize();
     $json['resourceType'] = $this->_fhirElementName;
     if (null !== $this->subject) {
         $json['subject'] = $this->subject->jsonSerialize();
     }
     if (null !== $this->orderer) {
         $json['orderer'] = $this->orderer->jsonSerialize();
     }
     if (0 < count($this->identifier)) {
         $json['identifier'] = array();
         foreach ($this->identifier as $identifier) {
             $json['identifier'][] = $identifier->jsonSerialize();
         }
     }
     if (null !== $this->encounter) {
         $json['encounter'] = $this->encounter->jsonSerialize();
     }
     if (0 < count($this->reason)) {
         $json['reason'] = array();
         foreach ($this->reason as $reason) {
             $json['reason'][] = $reason->jsonSerialize();
         }
     }
     if (0 < count($this->supportingInformation)) {
         $json['supportingInformation'] = array();
         foreach ($this->supportingInformation as $supportingInformation) {
             $json['supportingInformation'][] = $supportingInformation->jsonSerialize();
         }
     }
     if (0 < count($this->specimen)) {
         $json['specimen'] = array();
         foreach ($this->specimen as $specimen) {
             $json['specimen'][] = $specimen->jsonSerialize();
         }
     }
     if (null !== $this->status) {
         $json['status'] = $this->status->jsonSerialize();
     }
     if (null !== $this->priority) {
         $json['priority'] = $this->priority->jsonSerialize();
     }
     if (0 < count($this->event)) {
         $json['event'] = array();
         foreach ($this->event as $event) {
             $json['event'][] = $event->jsonSerialize();
         }
     }
     if (0 < count($this->item)) {
         $json['item'] = array();
         foreach ($this->item as $item) {
             $json['item'][] = $item->jsonSerialize();
         }
     }
     if (0 < count($this->note)) {
         $json['note'] = array();
         foreach ($this->note as $note) {
             $json['note'][] = $note->jsonSerialize();
         }
     }
     return $json;
 }