Package org.onosproject.persistence
Interface PersistentMapBuilder<K,V>
-
public interface PersistentMapBuilder<K,V>
The interface for a persistent map builder for use with mapDB.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<K,V>
build()
Validates the map settings and then builds this map in the database.PersistentMapBuilder<K,V>
withName(java.lang.String name)
Sets the name of this map.PersistentMapBuilder<K,V>
withSerializer(Serializer serializer)
Sets the key serializer to be used to serialize this map, this is a required parameter.
-
-
-
Method Detail
-
withName
PersistentMapBuilder<K,V> withName(java.lang.String name)
Sets the name of this map.- Parameters:
name
- the string name of this map- Returns:
- a persistent map builder with the name option now set
-
withSerializer
PersistentMapBuilder<K,V> withSerializer(Serializer serializer)
Sets the key serializer to be used to serialize this map, this is a required parameter.- Parameters:
serializer
- the serializer to be used for keys- Returns:
- a persistent map builder with the key serializer set
-
-