@Override
  public String execute() {

    ContactListHandler contactListHandler = new ContactListHandler();
    contactListHandler.setContactDao(new ContactDao());
    try {
      contactListHandler.executeSearch();
      int currentPage = getCurrentPage(commandParameter.getRequestParameter(COMMAND_PARAM), commandParameter.getRequestParameter(CURRENT_PAGE_PARAM));
      List<Contact> contacts = null;
      for (int i = 0; i < currentPage; i++) {
        contacts = contactListHandler.getNextElements(RECORDS_PER_PAGE);
      }
      ContactsDto contactsDto = new ContactsDto();
      contactsDto.setContacts(new ContactToContactDtoConverter().convert(contacts));
      contactsDto.setPath(commandParameter.getRequestURI());
      int numOfPages = getNumberOfPages(contactListHandler.getSize());
      contactsDto.setNumOfPages(numOfPages);
      contactsDto.setCurrentPage(currentPage);
      String xml = new ContactsDtoToXmlConverter().convertToXml(contactsDto);
      ApplictionResources applictionResources = ApplictionResources.getInstance();
      InputStream xsltInputStream = applictionResources.getResourceAsStream(XSLT_SCRIPT_PATH);
      XSLTTransformer transformer = new XSLTTransformer();
      transformer.transform(IOUtils.toInputStream(xml), xsltInputStream, commandParameter.getOutputStream());
    } catch (IOException e) {
      e.printStackTrace();
    } catch (ListHandlerException e) {
      e.printStackTrace();
    } catch (IteratorException e) {
      e.printStackTrace();
    }
    return UrlUtil.getPage(commandParameter);
  }