mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
be able to skip automatic closing of a hash resource
This commit is contained in:
@@ -181,6 +181,7 @@ public final class ChronicleMapBuilder<K, V> implements
|
||||
MapEntryOperations<K, V, ?> entryOperations = mapEntryOperations();
|
||||
MapRemoteOperations<K, V, ?> remoteOperations = mapRemoteOperations();
|
||||
Runnable preShutdownAction;
|
||||
boolean skipCloseOnExitHook = false;
|
||||
private String name;
|
||||
// not final because of cloning
|
||||
private ChronicleMapBuilderPrivateAPI<K, V> privateAPI =
|
||||
@@ -1607,6 +1608,12 @@ public final class ChronicleMapBuilder<K, V> implements
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ChronicleMapBuilder<K, V> skipCloseOnExitHook(boolean skipCloseOnExitHook) {
|
||||
this.skipCloseOnExitHook = skipCloseOnExitHook;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ChronicleMap<K, V> create() {
|
||||
// clone() to make this builder instance thread-safe, because createWithoutFile() method
|
||||
|
||||
Reference in New Issue
Block a user