Package org.h2.mvstore
Class MVMap.BasicBuilder<M extends MVMap<K,V>,K,V>
- java.lang.Object
-
- org.h2.mvstore.MVMap.BasicBuilder<M,K,V>
-
- Type Parameters:
K- the key typeV- the value type
- All Implemented Interfaces:
MVMap.MapBuilder<M,K,V>
- Direct Known Subclasses:
MVMap.Builder,MVRTreeMap.Builder
public abstract static class MVMap.BasicBuilder<M extends MVMap<K,V>,K,V> extends java.lang.Object implements MVMap.MapBuilder<M,K,V>
A builder for this class.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBasicBuilder()Create a new builder with the default key and value data types.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract Mcreate(java.util.Map<java.lang.String,java.lang.Object> config)Create map from config.Mcreate(MVStore store, java.util.Map<java.lang.String,java.lang.Object> config)Create a new map of the given type.DataType<K>getKeyType()DataType<V>getValueType()MVMap.BasicBuilder<M,K,V>keyType(DataType<? super K> keyType)Set the key data type.voidsetKeyType(DataType<? super K> keyType)voidsetValueType(DataType<? super V> valueType)MVMap.BasicBuilder<M,K,V>valueType(DataType<? super V> valueType)Set the value data type.
-
-
-
Method Detail
-
getKeyType
public DataType<K> getKeyType()
- Specified by:
getKeyTypein interfaceMVMap.MapBuilder<M extends MVMap<K,V>,K,V>
-
getValueType
public DataType<V> getValueType()
- Specified by:
getValueTypein interfaceMVMap.MapBuilder<M extends MVMap<K,V>,K,V>
-
setKeyType
public void setKeyType(DataType<? super K> keyType)
- Specified by:
setKeyTypein interfaceMVMap.MapBuilder<M extends MVMap<K,V>,K,V>
-
setValueType
public void setValueType(DataType<? super V> valueType)
- Specified by:
setValueTypein interfaceMVMap.MapBuilder<M extends MVMap<K,V>,K,V>
-
keyType
public MVMap.BasicBuilder<M,K,V> keyType(DataType<? super K> keyType)
Set the key data type.- Parameters:
keyType- the key type- Returns:
- this
-
valueType
public MVMap.BasicBuilder<M,K,V> valueType(DataType<? super V> valueType)
Set the value data type.- Parameters:
valueType- the value type- Returns:
- this
-
create
public M create(MVStore store, java.util.Map<java.lang.String,java.lang.Object> config)
Description copied from interface:MVMap.MapBuilderCreate a new map of the given type.
-
create
protected abstract M create(java.util.Map<java.lang.String,java.lang.Object> config)
Create map from config.- Parameters:
config- config map- Returns:
- new map
-
-