private void buildRequesters() {
   requesters = sampleRequesterDAO.getRequestersForSampleId(sampleId);
   for (SampleRequester requester : requesters) {
     if (requester.getRequesterTypeId() == Requester.PERSON.getId()) {
       Person person = personDAO.getPersonById(String.valueOf(requester.getRequesterId()));
       personService = new PersonService(person);
     } else if (requester.getRequesterTypeId() == Requester.ORGANIZATION.getId()) {
       organization =
           organizationDAO.getOrganizationById(String.valueOf(requester.getRequesterId()));
     }
   }
 }
  private String createSearchResultXML(String sampleId, StringBuilder xml) {
    String success = VALID;
    Sample sample = sampleDao.getSampleByID(sampleId);
    List<SampleRequester> requesters = sampleRequesterDAO.getRequestersForSampleId(sampleId);

    xml.append("<sampleDetails>");
    XMLUtil.appendKeyValue("sampleSource", sample.getSampleSource().getId(), xml);
    XMLUtil.appendKeyValue("sampleReceivedDateForDisplay", sample.getReceivedDateForDisplay(), xml);
    if (requesters.size() > 0) {
      XMLUtil.appendKeyValue(
          "sampleRequester", String.valueOf(requesters.get(0).getRequesterId()), xml);
    }
    xml.append("</sampleDetails>");

    return success;
  }