Interface DatasetService

    • Method Detail

      • listConstituents

        PagingResponse<DatasetlistConstituents​(UUID datasetKey,
                                                 @Nullable
                                                 Pageable page)
        Pages through constituents of a dataset, i.e. returns datasets which have a parentDatasetKey equals to the one requested.
        Parameters:
        datasetKey - the parent datasets key
      • listByCountry

        PagingResponse<DatasetlistByCountry​(Country country,
                                              @Nullable
                                              DatasetType type,
                                              @Nullable
                                              Pageable page)
        Provides paging service to list datasets published, i.e. owned by organizations from a given country.
        Parameters:
        country - the hosting country
        type - the optional dataset type filter
        Returns:
        list of datasets ordered by creation date with latest coming first
      • listByType

        PagingResponse<DatasetlistByType​(DatasetType type,
                                           @Nullable
                                           Pageable page)
        Provides paging service to list datasets published filtered by a particular dataset type.
        Parameters:
        type - the dataset type filter
        Returns:
        list of datasets ordered by creation date with latest coming first
      • listMetadata

        List<MetadatalistMetadata​(UUID datasetKey,
                                    @Nullable
                                    MetadataType type)
        Lists all metadata descriptions available for a dataset and optionally filters them by document type. The list is sorted by priority with the first result ranking highest. Highest priority in this sense means most relevant for augmenting/updating a dataset with EML being the most relevant cause informative type.
        Returns:
        the list of metadata entries sorted by priority
      • listNetworks

        List<NetworklistNetworks​(UUID datasetKey)
        Lists all networks that this dataset is a constituent of.
        Parameters:
        datasetKey - the dataset in question
        Returns:
        list of networks that have this dataset as a constituent
      • getMetadata

        Metadata getMetadata​(int metadataKey)
        Get a metadata description by its key.
      • deleteMetadata

        void deleteMetadata​(int metadataKey)
        Removes a metadata entry and its document by its key.
      • insertMetadata

        Metadata insertMetadata​(UUID datasetKey,
                                InputStream document)
        Inserts a metadata document, replacing any previously existing document of the same type. Updates dataset from metadata document, but only if metadata document does not exist already. The document type is discovered by the service and returned in the Metadata instance.
        Parameters:
        datasetKey - the dataset in question
        document - metadata document to insert
        Throws:
        IllegalArgumentException - if document is not parsable
      • getMetadataDocument

        InputStream getMetadataDocument​(UUID datasetKey)
        Retrieves a GBIF generated EML document overlaying GBIF information with any existing metadata document data.
      • listDuplicates

        PagingResponse<DatasetlistDuplicates​(@Nullable
                                               Pageable page)
        Provides access to datasets that are marked as a duplicate of another. When 2 datasets are considered duplicates, one is marked as a duplicate of the other. Only the marked dataset is returned in this call.
      • listByDOI

        PagingResponse<DatasetlistByDOI​(String doi,
                                          @Nullable
                                          Pageable page)
        Get a Dataset list from a DOI. GBIF assigned DOIs and alternate identifiers are returned. Multiple dataset could share the same DOI since this is not enforced.
      • listGrids

        List<GridlistGrids​(UUID datasetKey)
        Get gridded datasets processing info
        Parameters:
        datasetKey - the dataset in question
        Returns:
        List of grids