public class MemoryKVImplementation extends KVImplementation<Boolean>
log, XML_DESCRIPTOR_RESOURCE
Constructor and Description |
---|
MemoryKVImplementation() |
Modifier and Type | Method and Description |
---|---|
SimpleKVDatabase |
createKVDatabase(Boolean config,
KVDatabase kvdb,
AtomicKVStore kvstore)
Create an
KVDatabase using the specified configuration. |
String[][] |
getCommandLineOptions()
Get the command line options supported by this implementation, suitable for display in a usage help message.
|
String |
getDescription(Boolean config)
Generate a short, human-readable description of the
KVDatabase instance configured as given. |
Boolean |
parseCommandLineOptions(ArrayDeque<String> options)
Parse the specified command line options and return the resulting configuration, if possible.
|
createAtomicKVStore, getConfigType, getImplementations, getUsageText, parseCommandLineFlag, parseCommandLineOption, requiresAtomicKVStore, requiresKVDatabase
public String[][] getCommandLineOptions()
KVImplementation
There must be at least one option, to indicate that this implementation is to be used.
getCommandLineOptions
in class KVImplementation<Boolean>
public Boolean parseCommandLineOptions(ArrayDeque<String> options)
KVImplementation
At least one option must be recognized, indicating that this implementation is to be used, otherwise null should be returned.
parseCommandLineOptions
in class KVImplementation<Boolean>
options
- all command line options; upon return, recognized options should be removedpublic SimpleKVDatabase createKVDatabase(Boolean config, KVDatabase kvdb, AtomicKVStore kvstore)
KVImplementation
KVDatabase
using the specified configuration.createKVDatabase
in class KVImplementation<Boolean>
config
- implementation configuration returned by parseCommandLineOptions()
kvdb
- required KVDatabase
; will be null unless KVImplementation.requiresKVDatabase(C)
returned truekvstore
- required AtomicKVStore
; will be null unless KVImplementation.requiresAtomicKVStore(C)
returned trueKVDatabase
instancepublic String getDescription(Boolean config)
KVImplementation
KVDatabase
instance configured as given.getDescription
in class KVImplementation<Boolean>
config
- implementation configuration returned by parseCommandLineOptions()
Copyright © 2022. All rights reserved.