Class StorageCRUDUtils
- java.lang.Object
-
- fr.gouv.vitam.ihmrecette.appserver.StorageCRUDUtils
-
public class StorageCRUDUtils extends java.lang.Object
StorageCRUDUtils class this class is a tool for crud operation for storage
-
-
Constructor Summary
Constructors Constructor Description StorageCRUDUtils(StorageClient storageClient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
deleteFile(DataCategory dataCategory, java.lang.String uid, java.lang.String strategyId, java.lang.String offerId)
deleteFileRequestResponse<StorageStrategy>
getStrategies()
get the list of strategies containing the offersvoid
storeInOffer(DataCategory dataCategory, java.lang.String uid, java.lang.String strategyId, java.lang.String offerId, java.lang.Long size, java.io.InputStream stream)
Create file or erase it if exists
-
-
-
Constructor Detail
-
StorageCRUDUtils
public StorageCRUDUtils(StorageClient storageClient)
-
-
Method Detail
-
getStrategies
public RequestResponse<StorageStrategy> getStrategies() throws StorageServerClientException
get the list of strategies containing the offers- Throws:
StorageServerClientException
-
deleteFile
public boolean deleteFile(DataCategory dataCategory, java.lang.String uid, java.lang.String strategyId, java.lang.String offerId) throws StorageServerClientException
deleteFile- Parameters:
dataCategory
- categoryuid
- uid of filestrategyId
- strategy identifierofferId
- offer identifier- Throws:
StorageServerClientException
-
storeInOffer
public void storeInOffer(DataCategory dataCategory, java.lang.String uid, java.lang.String strategyId, java.lang.String offerId, java.lang.Long size, java.io.InputStream stream) throws BackupServiceException
Create file or erase it if exists- Parameters:
dataCategory
- dataCategoryuid
- uidstrategyId
- strategyIDofferId
- offerIDstream
- stream- Throws:
BackupServiceException
-
-