Interface StorageService

    • Method Detail

      • getName

        String getName()
        Returns:
        the name of the storage service
      • isApplicable

        boolean isApplicable​(String type)
        Parameters:
        type - study element type
        Returns:
        true, if storage service is applicable for the given study element type
      • store

        void store​(StorageContext storageContext)
        Stores a study element.
        Parameters:
        storageContext - a contect including the study element
      • exists

        boolean exists​(String id,
                       String type)
        Parameters:
        id - study element id
        type - study element type
        Returns:
        true, if the study element defined by type and id exists in the storage
      • get

        <T> T get​(String id,
                  String type,
                  Class<T> clazz)
        Get one element from storage.
        Type Parameters:
        T - study element or null
        Parameters:
        id - study element id
        type - study element type
        Returns:
      • search

        <T> StorageSearchResult<T> search​(StorageQuery query,
                                          Class<T> clazz)
        Query study elements from the storage
        Type Parameters:
        T - the type used for representing the study elements
        Parameters:
        query - the query object
        clazz - the class used for representing study elements
        Returns:
        the result of the query in a result object