Hazelcast C++ Client
LazyEntryArray.h
1 /*
2  * Copyright (c) 2008-2018, Hazelcast, Inc. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 #ifndef HAZELCAST_CLIENT_LAZYENTRYARRAY_H_
17 #define HAZELCAST_CLIENT_LAZYENTRYARRAY_H_
18 
19 #include <memory>
20 
21 namespace hazelcast {
22  namespace client {
23  template<typename K, typename V>
25  public:
26  virtual ~LazyEntryArray() {}
27 
31  virtual size_t size() const = 0;
32 
40  virtual const K *getKey(size_t index) = 0;
41 
50  virtual std::auto_ptr<K> releaseKey(size_t index) = 0;
51 
59  virtual const V *getValue(size_t index) = 0;
60 
68  virtual std::auto_ptr<V> releaseValue(size_t index) = 0;
69 
74  virtual std::pair<const K *, const V *> operator[](size_t index) = 0;
75  };
76  }
77 }
78 
79 #endif //HAZELCAST_CLIENT_LAZYENTRYARRAY_H_
80 
virtual const K * getKey(size_t index)=0
Please note that this operation is costly due to de-serialization.
virtual const V * getValue(size_t index)=0
Please note that this operation is costly due to de-serialization.
virtual size_t size() const =0
virtual std::auto_ptr< K > releaseKey(size_t index)=0
Please note that this operation MAY(if not deserialized previously) be costly due to de-serialization...
virtual std::auto_ptr< V > releaseValue(size_t index)=0
Please note that this operation is costly due to de-serialization.
Definition: LazyEntryArray.h:24
PN (Positive-Negative) CRDT counter.
Definition: MapEntryView.h:32
virtual std::pair< const K *, const V * > operator[](size_t index)=0