Class FhirSearch

java.lang.Object
org.apache.camel.component.fhir.api.FhirSearch

public class FhirSearch extends Object
API to search for resources matching a given set of criteria. Searching is a very powerful feature in FHIR with many features for specifying exactly what should be searched for and how it should be returned. See the specification on search for more information.
  • Constructor Details

    • FhirSearch

      public FhirSearch(ca.uhn.fhir.rest.client.api.IGenericClient client)
  • Method Details

    • searchByUrl

      public org.hl7.fhir.instance.model.api.IBaseBundle searchByUrl(String url, Map<ExtraParameters,Object> extraParameters)
      Perform a search directly by URL.
      Parameters:
      url - The URL to search for. Note that this URL may be complete (e.g. "http://example.com/base/Patient?name=foo") in which case the client's base URL will be ignored. Or it can be relative (e.g. "Patient?name=foo") in which case the client's base URL will be used.
      extraParameters - see ExtraParameters for a full list of parameters that can be passed, may be NULL
      Returns:
      the IBaseBundle
    • searchByResource

      public org.hl7.fhir.instance.model.api.IBaseBundle searchByResource(String resourceName, Map<String,List<String>> searchParameters, ca.uhn.fhir.rest.api.SearchStyleEnum searchStyle, Map<ExtraParameters,Object> extraParameters)
      Perform a search by resource name.
      Parameters:
      resourceName - The resource to search for.
      searchParameters - A set of search parameters to the query.
      searchStyle - Forces the query to perform the search using the given method (allowable methods are described in the FHIR Search Specification). The default search style is HTTP POST.
      extraParameters - see ExtraParameters for a full list of parameters that can be passed, may be NULL
      Returns:
      the IBaseBundle