Package nl.knaw.dans.layerstore
Class LayerManagerImpl
java.lang.Object
nl.knaw.dans.layerstore.LayerManagerImpl
- All Implemented Interfaces:
LayerManager
-
Constructor Summary
ConstructorDescriptionLayerManagerImpl
(@NonNull Path stagingRoot, @NonNull ArchiveProvider archiveProvider) LayerManagerImpl
(@NonNull Path stagingRoot, @NonNull ArchiveProvider archiveProvider, Executor archivingExecutor) -
Method Summary
Modifier and TypeMethodDescriptiongetLayer
(long id) Returns the layer with the given id.void
Closes the current top layer and creates a new top layer.
-
Constructor Details
-
LayerManagerImpl
public LayerManagerImpl(@NonNull @NonNull Path stagingRoot, @NonNull @NonNull ArchiveProvider archiveProvider, Executor archivingExecutor) throws IOException - Throws:
IOException
-
LayerManagerImpl
public LayerManagerImpl(@NonNull @NonNull Path stagingRoot, @NonNull @NonNull ArchiveProvider archiveProvider) throws IOException - Throws:
IOException
-
-
Method Details
-
newTopLayer
public void newTopLayer()Description copied from interface:LayerManager
Closes the current top layer and creates a new top layer. The old top layer will be scheduled for archiving.- Specified by:
newTopLayer
in interfaceLayerManager
-
getLayer
Description copied from interface:LayerManager
Returns the layer with the given id.- Specified by:
getLayer
in interfaceLayerManager
- Parameters:
id
- the id of the layer- Returns:
- the layer
-
getTopLayer
- Specified by:
getTopLayer
in interfaceLayerManager
-