Interface ResourceDAO

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      List<Resource> history​(String resourceType, String logicalId, Timestamp fromDateTime, int offset, int maxResults)
      Reads and returns all versions of the Resource with the passed logicalId, ordered by descending version id.
      int historyCount​(String resourceType, String logicalId, Timestamp fromDateTime)
      Reads and returns the COUNT of all versions of the Resource with the passed logicalId.
      Resource insert​(Resource resource, List<ExtractedParameterValue> parameters, String parameterHashB64, ParameterDAO parameterDao, Integer ifNoneMatch)
      Inserts the passed Resource DTO and its associated search parameters to the appropriate FHIR resource tables.
      Resource read​(String logicalId, String resourceType)
      Reads and returns the latest version of the Resource with the passed logical id and resource type.
      Map<String,​Integer> readAllResourceTypeNames()
      Reads all rows in the resource_types table and returns the data as a Map
      Integer readResourceTypeId​(String parameterName)
      Reads the id associated with the name of the passed Resource type from the Resource_Types table.
      List<Resource> search​(com.ibm.fhir.database.utils.query.Select select)
      Executes the search contained in the passed Select, using its encapsulated search string and bind variables.
      List<Resource> search​(String sqlSelect)
      Executes the passed fully-formed SQL Select statement and returns the results If no matching resources are found, an empty collection is returned.
      List<Resource> searchByIds​(String resourceType, List<Long> resourceIds)
      Searches for Resources that contain one of the passed ids.
      int searchCount​(com.ibm.fhir.database.utils.query.Select countQuery)
      Executes a count query based on the data contained in the passed Select statement, using its encapsulated search string and bind variables.
      int searchCount​(String sqlSelectCount)
      Executes the passed fully-formed SQL Select COUNT statement and returns the integer count.
      List<Long> searchForIds​(com.ibm.fhir.database.utils.query.Select dataQuery)
      This method supports the execution of a specialized query designed to return Resource ids, based on the contents of the passed select statement.
      Map<Integer,​List<Long>> searchWholeSystem​(com.ibm.fhir.database.utils.query.Select select)
      Executes the whole-system filter search contained in the passed Select, using its encapsulated search string and bind variables.
      void setPersistenceContext​(com.ibm.fhir.persistence.context.FHIRPersistenceContext context)
      Sets the current persistence context
      Resource versionRead​(String logicalId, String resourceType, int versionId)
      Reads and returns the version of the Resource with the passed logical id, resource type, and version id.