Hazelcast C++ Client
 All Classes Functions Variables Enumerations Pages
DistributedObject.h
1 /*
2  * Copyright (c) 2008-2015, 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 12/11/13.
18 
19 
20 
21 
22 #ifndef HAZELCAST_DistributedObject
23 #define HAZELCAST_DistributedObject
24 
25 #include "hazelcast/util/HazelcastDll.h"
26 #include "hazelcast/client/impl/DistributedObjectInfo.h"
27 #include <string>
28 
29 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)
30 #pragma warning(push)
31 #pragma warning(disable: 4251) //for dll export
32 #endif
33 
34 namespace hazelcast {
35  namespace client {
36  namespace impl {
37  class BaseEventHandler;
38 
39  class BaseRemoveListenerRequest;
40 
41  class ClientRequest;
42  }
43 
44  namespace serialization {
45  namespace pimpl {
46  class Data;
47  }
48  }
49 
70  class HAZELCAST_API DistributedObject {
71  friend class HazelcastClient;
72 
73  public:
77  const std::string& getServiceName() const;
78 
84  const std::string& getName() const;
85 
90  virtual void destroy() = 0;
91 
95  virtual ~DistributedObject();
96 
97  protected:
101  DistributedObject(const std::string& serviceName, const std::string& objectName);
102 
106  virtual void onDestroy();
107 
108  impl::DistributedObjectInfo info;
109  };
110 
111  }
112 }
113 
114 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)
115 #pragma warning(pop)
116 #endif
117 
118 #endif //HAZELCAST_DistributedObject
119 
Base class for all distributed objects.
Definition: DistributedObject.h:70
Hazelcast Client enables you to do all Hazelcast operations without being a member of the cluster...
Definition: HazelcastClient.h:410