Hazelcast C++ Client
ItemListener.h
1 /*
2  * Copyright (c) 2008-2019, 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 //
17 // Created by sancar koyunlu on 04/09/14.
18 //
19 
20 
21 #ifndef HAZELCAST_ItemListener
22 #define HAZELCAST_ItemListener
23 
24 #include "hazelcast/client/ItemEvent.h"
25 #include "hazelcast/client/TypedData.h"
26 
27 namespace hazelcast {
28  namespace client {
29 
40  template<typename E>
41  class ItemListener {
42  public:
43  virtual ~ItemListener() {
44  }
45 
51  virtual void itemAdded(const ItemEvent<E>& item) = 0;
52 
58  virtual void itemRemoved(const ItemEvent<E>& item) = 0;
59  };
60 
61  namespace mixedtype {
62  typedef ItemListener<TypedData> MixedItemListener;
63  }
64  }
65 }
66 
67 
68 #endif //HAZELCAST_ItemListener
Item listener for IQueue, ISet and IList.
Definition: ItemListener.h:41
virtual void itemAdded(const ItemEvent< E > &item)=0
Invoked when an item is added.
PN (Positive-Negative) CRDT counter.
Definition: MapEntryView.h:32
virtual void itemRemoved(const ItemEvent< E > &item)=0
Invoked when an item is removed.
Definition: ItemEvent.h:113