Class ObjectReferentialRepository
- java.lang.Object
-
- fr.gouv.vitam.storage.offers.tape.cas.ObjectReferentialRepository
-
public class ObjectReferentialRepository extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ObjectReferentialRepository(com.mongodb.client.MongoCollection<org.bson.Document> collection)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<TapeObjectReferentialEntity>
bulkFind(java.lang.String containerName, java.util.Set<java.lang.String> objectNames)
boolean
delete(TapeLibraryObjectReferentialId tapeLibraryObjectReferentialId)
java.util.Optional<TapeObjectReferentialEntity>
find(java.lang.String containerName, java.lang.String objectName)
void
insertOrUpdate(TapeObjectReferentialEntity tapeObjectReferentialEntity)
CloseableIterator<ObjectEntry>
listContainerObjectEntries(java.lang.String containerName)
java.util.Set<java.lang.String>
selectArchiveIdsByObjectIds(java.util.Iterator<TapeLibraryObjectReferentialId> objectIdIterator)
void
updateStorageLocation(java.lang.String containerName, java.lang.String objectName, java.lang.String storageId, TapeLibraryTarObjectStorageLocation tapeLibraryTarStorageLocation)
-
-
-
Method Detail
-
insertOrUpdate
public void insertOrUpdate(TapeObjectReferentialEntity tapeObjectReferentialEntity) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
find
public java.util.Optional<TapeObjectReferentialEntity> find(java.lang.String containerName, java.lang.String objectName) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
bulkFind
public java.util.List<TapeObjectReferentialEntity> bulkFind(java.lang.String containerName, java.util.Set<java.lang.String> objectNames) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
updateStorageLocation
public void updateStorageLocation(java.lang.String containerName, java.lang.String objectName, java.lang.String storageId, TapeLibraryTarObjectStorageLocation tapeLibraryTarStorageLocation) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
delete
public boolean delete(TapeLibraryObjectReferentialId tapeLibraryObjectReferentialId) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
selectArchiveIdsByObjectIds
public java.util.Set<java.lang.String> selectArchiveIdsByObjectIds(java.util.Iterator<TapeLibraryObjectReferentialId> objectIdIterator) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
listContainerObjectEntries
public CloseableIterator<ObjectEntry> listContainerObjectEntries(java.lang.String containerName) throws ObjectReferentialException
- Throws:
ObjectReferentialException
-
-