Class BasicMapId
java.lang.Object
org.springframework.data.cassandra.core.mapping.BasicMapId
Simple implementation of
MapId.
Note: This could be extended in various cool ways, like one that takes a type and validates that the given
name corresponds to an actual field or bean property on that type. There could also be another one that uses a
CassandraPersistentEntity and CassandraPersistentProperty instead of a String name.
- Author:
- Matthew T. Adams, Mark Paluch
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new and emptyBasicMapId.BasicMapId(Map<String, Object> map) Create a newBasicMapIdgiven aMapof key-value tuples. -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()booleancontainsKey(Object name) booleancontainsValue(Object value) entrySet()boolean@Nullable ObjectinthashCode()static MapIdid()Factory method.static MapIdFactory method.static MapIdFactory method.booleanisEmpty()keySet()voidintsize()toString()values()Builder method that adds the value for the named property, then returnsthis.Methods inherited from interface Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Constructor Details
-
BasicMapId
public BasicMapId()Create a new and emptyBasicMapId. -
BasicMapId
Create a newBasicMapIdgiven aMapof key-value tuples.- Parameters:
map- must not be null.
-
-
Method Details
-
id
-
id
Factory method. Convenient if imported statically.- Returns:
BasicMapId
-
id
Factory method. Convenient if imported statically.- Returns:
BasicMapId
-
with
Description copied from interface:MapIdBuilder method that adds the value for the named property, then returnsthis. -
clear
-
containsKey
- Specified by:
containsKeyin interfaceMap<String, @Nullable Object>
-
containsValue
- Specified by:
containsValuein interfaceMap<String, @Nullable Object>
-
entrySet
-
equals
-
get
-
hashCode
-
isEmpty
-
keySet
-
put
-
putAll
-
remove
-
size
-
values
-
toString
-