17 #ifndef HAZELCAST_CLIENT_REPLICATED_MAP_H_ 18 #define HAZELCAST_CLIENT_REPLICATED_MAP_H_ 23 #include <boost/shared_ptr.hpp> 25 #include "hazelcast/client/DistributedObject.h" 26 #include "hazelcast/client/EntryListener.h" 27 #include "hazelcast/client/query/Predicate.h" 28 #include "hazelcast/client/DataArray.h" 29 #include "hazelcast/client/LazyEntryArray.h" 31 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) 33 #pragma warning(disable: 4251) //for dll export 52 template <
typename K,
typename V>
67 virtual boost::shared_ptr<V>
put(
const K &key,
const V &value, int64_t ttl) = 0;
79 virtual void putAll(
const std::map<K, V> &entries) = 0;
86 virtual void clear() = 0;
153 virtual boost::shared_ptr<DataArray<V> >
values() = 0;
167 virtual boost::shared_ptr<LazyEntryArray<K, V> >
entrySet() = 0;
181 virtual boost::shared_ptr<DataArray<K> >
keySet() = 0;
187 virtual int32_t
size() = 0;
214 virtual boost::shared_ptr<V>
get(
const K &key) = 0;
222 virtual boost::shared_ptr<V>
put(
const K &key,
const V &value) = 0;
229 virtual boost::shared_ptr<V>
remove(
const K &key) = 0;
234 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) 238 #endif //HAZELCAST_CLIENT_REPLICATED_MAP_H_ Map Entry listener to get notified when a map entry is added, removed, updated or evicted...
Definition: EntryListener.h:45
virtual boost::shared_ptr< DataArray< K > > keySet()=0
Returns a lazy DataArray view of the key contained in this map.
virtual boost::shared_ptr< DataArray< V > > values()=0
Due to the lazy nature of the returned array, changes to the map (addition, removal, update) might be reflected on the collection.
Definition: ReplicatedMap.h:53
Base class for all distributed objects.
Definition: DistributedObject.h:58
virtual std::string addEntryListener(const boost::shared_ptr< EntryListener< K, V > > &listener)=0
Adds an entry listener for this map.
virtual bool removeEntryListener(const std::string ®istrationId)=0
Removes the specified entry listener.
virtual boost::shared_ptr< LazyEntryArray< K, V > > entrySet()=0
Returns a lazy LazyEntryArray view of the mappings contained in this map.
This is a marker class for Predicate classes.
Definition: Predicate.h:36
virtual bool containsKey(const K &key)=0
PN (Positive-Negative) CRDT counter.
Definition: MapEntryView.h:32
virtual bool containsValue(const V &value)=0
virtual void putAll(const std::map< K, V > &entries)=0
Copies all of the mappings from the specified map to this map (optional operation).
virtual boost::shared_ptr< V > put(const K &key, const V &value, int64_t ttl)=0