code: public ReportedData submitSearch(DomainBareJid serviceJID, Form completedForm) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
          TranscriptSearch search = new TranscriptSearch();
          search.setType(IQ.Type.get);
          search.setTo(serviceJID);
          search.addExtension(completedForm.getDataFormToSend());
  
          TranscriptSearch response = connection.createStanzaCollectorAndSend(
                          search).nextResultOrThrow();
          return ReportedData.getReportedDataFrom(response);
      }
docs: Submits the completed form and returns the result of the transcript search. The result
  will include all the data returned from the server so be careful with the amount of
  data that the search may return.
  
  @param serviceJID    the address of the workgroup service.
  @param completedForm the filled out search form.
  @return the result of the transcript search.
  @throws XMPPErrorException
  @throws NoResponseException
  @throws NotConnectedException
  @throws InterruptedException