public enum StoreConfig extends java.lang.Enum<StoreConfig>
duplicates and prefixing. If duplicates is true, then the Store
can save several values for a single key. If prefixing is true, then the Store uses
Patricia trie as a search tree, rather than
B+Tree. Patricia tries tend to perform better and save
physical space of the database if the keys tend to have common prefixes. Also these types of search tree differ in
performance characteristics: stores with key prefixing has better random key access, whereas stores without key
prefixing are preferable for sequential access in order of keys.
| With duplicates | Without duplicates | |
|---|---|---|
| With key prefixing | WITH_DUPLICATES_WITH_PREFIXING | WITH_DUPLICATES_WITH_PREFIXING |
| Without key prefixing | WITH_DUPLICATES | WITHOUT_DUPLICATES |
| Enum Constant and Description |
|---|
TEMPORARY_EMPTY
Please don't use it in your applications.
|
USE_EXISTING
If it is known that a Store definitely exists it can be opened with the
StoreConfig.USE_EXISTING configuration. |
WITH_DUPLICATES
Store with this config has key duplicates and doesn't support key prefixing.
|
WITH_DUPLICATES_WITH_PREFIXING
Store with this config has no key duplicates and supports key prefixing.
|
WITHOUT_DUPLICATES
Store with this config has no key duplicates and doesn't support key prefixing.
|
WITHOUT_DUPLICATES_WITH_PREFIXING
Store with this config has no key duplicates and supports key prefixing.
|
| Modifier and Type | Field and Description |
|---|---|
boolean |
duplicates |
int |
id |
boolean |
prefixing |
boolean |
temporaryEmpty |
boolean |
useExisting |
| Modifier and Type | Method and Description |
|---|---|
static StoreConfig |
getStoreConfig(boolean duplicates,
boolean prefixing)
Returns
StoreConfig value corresponding to the specified Store attributes. |
java.lang.String |
toString() |
static StoreConfig |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static StoreConfig[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StoreConfig WITHOUT_DUPLICATES
public static final StoreConfig WITH_DUPLICATES
public static final StoreConfig WITHOUT_DUPLICATES_WITH_PREFIXING
public static final StoreConfig WITH_DUPLICATES_WITH_PREFIXING
public static final StoreConfig TEMPORARY_EMPTY
public static final StoreConfig USE_EXISTING
public final int id
public final boolean duplicates
public final boolean prefixing
public final boolean temporaryEmpty
public final boolean useExisting
public static StoreConfig[] values()
for (StoreConfig c : StoreConfig.values()) System.out.println(c);
public static StoreConfig valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic java.lang.String toString()
toString in class java.lang.Enum<StoreConfig>public static StoreConfig getStoreConfig(boolean duplicates, boolean prefixing)
StoreConfig value corresponding to the specified Store attributes.
| With duplicates | Without duplicates | |
|---|---|---|
| With key prefixing | WITH_DUPLICATES_WITH_PREFIXING | WITH_DUPLICATES_WITH_PREFIXING |
| Without key prefixing | WITH_DUPLICATES | WITHOUT_DUPLICATES |
duplicates - true if key duplicates are allowedprefixing - true if key prefixing is desiredStoreConfig value corresponding to the specified Store attributes