Interface CollectInternalClient

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      javax.ws.rs.core.Response abortTransaction​(java.lang.String transactionId)
      Abort Transaction Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> addBinary​(java.lang.String unitId, java.lang.Integer version, java.io.InputStream inputStreamUploaded, java.lang.String usage)
      ADD Binary Consume and produce MediaType.OCTET_STREAM
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> addObjectGroup​(java.lang.String unitId, java.lang.Integer version, com.fasterxml.jackson.databind.JsonNode objectJsonNode, java.lang.String usage)
      ADD Object Group Consume and produce MediaType.APPLICATION_JSON
      javax.ws.rs.core.Response attachVitamOperationId​(java.lang.String transactionId, java.lang.String operationId)
      Attach Vitam Operation Id To Transaction Consume and produce MediaType.APPLICATION_JSON
      javax.ws.rs.core.Response changeTransactionStatus​(java.lang.String transactionId, TransactionStatus transactionStatus)
      Change Transaction Status Consume and produce MediaType.APPLICATION_JSON
      javax.ws.rs.core.Response closeTransaction​(java.lang.String transactionId)
      Close Transaction Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> deleteProjectById​(java.lang.String projectId)
      delete a collect project produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> deleteTransactionById​(java.lang.String transactionId)
      delete a collect transaction produce MediaType.APPLICATION_JSON
      java.io.InputStream generateSip​(java.lang.String transactionId)
      Generate SIP + Send to Vitam produce and InputStream
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getObjectById​(java.lang.String gotId)
      get an object group by Id Consume and produce MediaType.APPLICATION_JSON
      javax.ws.rs.core.Response getObjectStreamByUnitId​(java.lang.String unitId, java.lang.String usage, int version)
      Get all AU attached to transactions related to project Id param
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> getProjectById​(java.lang.String projectId)
      get a collect project Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> getProjects()
      get all collect project by tenant Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> getTransactionById​(java.lang.String transactionId)
      get a collect transaction by ID Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> getTransactionByProjectId​(java.lang.String projectId)
      get a collect transaction Consume and produce MediaType.APPLICATION_JSON
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitById​(java.lang.String unitId)
      get an archive unit by Id Consume and produce MediaType.APPLICATION_JSON
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitsByProjectId​(java.lang.String projectId, com.fasterxml.jackson.databind.JsonNode dslQuery)
      Get all AU attached to transactions related to project Id param
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitsByTransaction​(java.lang.String transactionId, com.fasterxml.jackson.databind.JsonNode query)
      get an archive unit by transaction Id Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> initProject​(ProjectDto projectDto)
      Initialize a collect project Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> initTransaction​(TransactionDto transactionDto, java.lang.String projectId)
      Initialize a collect transaction Consume and produce MediaType.APPLICATION_JSON
      javax.ws.rs.core.Response reopenTransaction​(java.lang.String transactionId)
      Reopen Transaction Consume and produce MediaType.APPLICATION_JSON
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> searchProject​(CriteriaProjectDto criteria)
      get all projects by criteria Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> selectUnitsWithInheritedRules​(java.lang.String transactionId, com.fasterxml.jackson.databind.JsonNode selectQuery)
      select Units With Inherited Rules
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> updateProject​(ProjectDto projectDto)
      Update a collect project Consume and produce MediaType.APPLICATION_JSON
      RequestResponse<com.fasterxml.jackson.databind.JsonNode> updateTransaction​(TransactionDto transactionDto)
      Update a collect transaction Consume and produce MediaType.APPLICATION_JSON
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> updateUnits​(java.lang.String transactionId, java.io.InputStream is)  
      RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> uploadArchiveUnit​(com.fasterxml.jackson.databind.JsonNode unitJsonNode, java.lang.String transactionId)
      ADD Archive Unit Consume and produce MediaType.APPLICATION_JSON
      void uploadTransactionZip​(java.lang.String transactionId, java.io.InputStream inputStreamUploaded)
      Upload zip and consume Consume and produce CommonMediaType.ZIP
    • Method Detail

      • getProjectById

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> getProjectById​(java.lang.String projectId)
                                                                         throws VitamClientException
        get a collect project Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getTransactionByProjectId

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> getTransactionByProjectId​(java.lang.String projectId)
                                                                                    throws VitamClientException
        get a collect transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getTransactionById

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> getTransactionById​(java.lang.String transactionId)
                                                                             throws VitamClientException
        get a collect transaction by ID Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getProjects

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> getProjects()
                                                                      throws VitamClientException
        get all collect project by tenant Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • deleteTransactionById

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> deleteTransactionById​(java.lang.String transactionId)
                                                                                throws VitamClientException
        delete a collect transaction produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • deleteProjectById

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> deleteProjectById​(java.lang.String projectId)
                                                                            throws VitamClientException
        delete a collect project produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getUnitById

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitById​(java.lang.String unitId)
                                                                        throws VitamClientException
        get an archive unit by Id Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponseOK
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getUnitsByTransaction

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitsByTransaction​(java.lang.String transactionId,
                                                                                         com.fasterxml.jackson.databind.JsonNode query)
                                                                                  throws VitamClientException
        get an archive unit by transaction Id Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getObjectById

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getObjectById​(java.lang.String gotId)
                                                                          throws VitamClientException
        get an object group by Id Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponseOK
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • initTransaction

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> initTransaction​(TransactionDto transactionDto,
                                                                                 java.lang.String projectId)
                                                                          throws VitamClientException
        Initialize a collect transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse guid created for the transaction
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • uploadArchiveUnit

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> uploadArchiveUnit​(com.fasterxml.jackson.databind.JsonNode unitJsonNode,
                                                                                     java.lang.String transactionId)
                                                                              throws VitamClientException
        ADD Archive Unit Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse Archive Unit saved
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • addObjectGroup

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> addObjectGroup​(java.lang.String unitId,
                                                                                  java.lang.Integer version,
                                                                                  com.fasterxml.jackson.databind.JsonNode objectJsonNode,
                                                                                  java.lang.String usage)
                                                                           throws VitamClientException
        ADD Object Group Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponse objectgroup saved
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • addBinary

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> addBinary​(java.lang.String unitId,
                                                                           java.lang.Integer version,
                                                                           java.io.InputStream inputStreamUploaded,
                                                                           java.lang.String usage)
                                                                    throws VitamClientException
        ADD Binary Consume and produce MediaType.OCTET_STREAM
        Returns:
        Response
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • closeTransaction

        javax.ws.rs.core.Response closeTransaction​(java.lang.String transactionId)
                                            throws VitamClientException
        Close Transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        Response
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • generateSip

        java.io.InputStream generateSip​(java.lang.String transactionId)
                                 throws VitamClientException
        Generate SIP + Send to Vitam produce and InputStream
        Returns:
        InputStream
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • abortTransaction

        javax.ws.rs.core.Response abortTransaction​(java.lang.String transactionId)
                                            throws VitamClientException
        Abort Transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        Response
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • reopenTransaction

        javax.ws.rs.core.Response reopenTransaction​(java.lang.String transactionId)
                                             throws VitamClientException
        Reopen Transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        RequestResponseOK
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • uploadTransactionZip

        void uploadTransactionZip​(java.lang.String transactionId,
                                  java.io.InputStream inputStreamUploaded)
                           throws VitamClientException
        Upload zip and consume Consume and produce CommonMediaType.ZIP
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • getUnitsByProjectId

        RequestResponseOK<com.fasterxml.jackson.databind.JsonNode> getUnitsByProjectId​(java.lang.String projectId,
                                                                                       com.fasterxml.jackson.databind.JsonNode dslQuery)
                                                                                throws VitamClientException
        Get all AU attached to transactions related to project Id param
        Parameters:
        projectId -
        dslQuery -
        Returns:
        Throws:
        VitamClientException
      • getObjectStreamByUnitId

        javax.ws.rs.core.Response getObjectStreamByUnitId​(java.lang.String unitId,
                                                          java.lang.String usage,
                                                          int version)
                                                   throws VitamClientException
        Get all AU attached to transactions related to project Id param
        Parameters:
        unitId - unit id
        usage - usage
        version - version
        Returns:
        Response
        Throws:
        VitamClientException - Thrown exception
      • changeTransactionStatus

        javax.ws.rs.core.Response changeTransactionStatus​(java.lang.String transactionId,
                                                          TransactionStatus transactionStatus)
                                                   throws VitamClientException
        Change Transaction Status Consume and produce MediaType.APPLICATION_JSON
        Returns:
        Response
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • attachVitamOperationId

        javax.ws.rs.core.Response attachVitamOperationId​(java.lang.String transactionId,
                                                         java.lang.String operationId)
                                                  throws VitamClientException
        Attach Vitam Operation Id To Transaction Consume and produce MediaType.APPLICATION_JSON
        Returns:
        Response
        Throws:
        VitamClientException - exception occurs when parse operation failed
      • selectUnitsWithInheritedRules

        RequestResponse<com.fasterxml.jackson.databind.JsonNode> selectUnitsWithInheritedRules​(java.lang.String transactionId,
                                                                                               com.fasterxml.jackson.databind.JsonNode selectQuery)
                                                                                        throws VitamClientException
        select Units With Inherited Rules
        Parameters:
        transactionId - transaction Id
        selectQuery - dsl query
        Returns:
        Response
        Throws:
        VitamClientException - exception