Ice 3.7 C++11 API Reference
ObjectFactory.h
Go to the documentation of this file.
1 //
2 // Copyright (c) ZeroC, Inc. All rights reserved.
3 //
4 //
5 // Ice version 3.7.10
6 //
7 // <auto-generated>
8 //
9 // Generated from file `ObjectFactory.ice'
10 //
11 // Warning: do not edit this file.
12 //
13 // </auto-generated>
14 //
15 
16 #ifndef __Ice_ObjectFactory_h__
17 #define __Ice_ObjectFactory_h__
18 
20 #include <Ice/ProxyF.h>
21 #include <Ice/ObjectF.h>
22 #include <Ice/ValueF.h>
23 #include <Ice/Exception.h>
24 #include <Ice/LocalObject.h>
25 #include <Ice/StreamHelpers.h>
26 #include <Ice/Comparable.h>
27 #include <IceUtil/ScopedArray.h>
28 #include <Ice/Optional.h>
29 #include <IceUtil/UndefSysMacros.h>
30 
31 #ifndef ICE_IGNORE_VERSION
32 # if ICE_INT_VERSION / 100 != 307
33 # error Ice version mismatch!
34 # endif
35 # if ICE_INT_VERSION % 100 >= 50
36 # error Beta header file detected
37 # endif
38 # if ICE_INT_VERSION % 100 < 10
39 # error Ice patch level mismatch!
40 # endif
41 #endif
42 
43 #ifndef ICE_API
44 # if defined(ICE_STATIC_LIBS)
45 # define ICE_API
46 # elif defined(ICE_API_EXPORTS)
47 # define ICE_API ICE_DECLSPEC_EXPORT
48 # else
49 # define ICE_API ICE_DECLSPEC_IMPORT
50 # endif
51 #endif
52 
53 #ifdef ICE_CPP11_MAPPING // C++11 mapping
54 
55 namespace Ice
56 {
57 
58 class ObjectFactory;
59 
60 }
61 
62 namespace Ice
63 {
64 
73 class ICE_CLASS(ICE_API) ObjectFactory
74 {
75 public:
76 
78 
91  ICE_DEPRECATED_API("ObjectFactory has been deprecated, use ValueFactory instead.") virtual ::std::shared_ptr<::Ice::Value> create(const ::std::string& type) = 0;
92 
98  ICE_DEPRECATED_API("ObjectFactory has been deprecated, use ValueFactory instead.") virtual void destroy() = 0;
99 };
100 
101 }
102 
104 namespace Ice
105 {
106 
107 }
109 
111 namespace Ice
112 {
113 
114 using ObjectFactoryPtr = ::std::shared_ptr<ObjectFactory>;
115 
116 }
118 
119 #else // C++98 mapping
120 
121 namespace Ice
122 {
123 
124 class ObjectFactory;
126 ICE_API LocalObject* upCast(ObjectFactory*);
128 typedef ::IceInternal::Handle< ObjectFactory> ObjectFactoryPtr;
129 
130 }
131 
132 namespace Ice
133 {
134 
143 class ICE_API ObjectFactory : public virtual LocalObject
144 {
145 public:
146 
147  typedef ObjectFactoryPtr PointerType;
148 
149  virtual ~ObjectFactory();
150 
151 #ifdef ICE_CPP11_COMPILER
152  ObjectFactory() = default;
153  ObjectFactory(const ObjectFactory&) = default;
154  ObjectFactory& operator=(const ObjectFactory&) = default;
155 #endif
156 
169  ICE_DEPRECATED_API("ObjectFactory has been deprecated, use ValueFactory instead.") virtual ValuePtr create(const ::std::string& type) = 0;
170 
176  ICE_DEPRECATED_API("ObjectFactory has been deprecated, use ValueFactory instead.") virtual void destroy() = 0;
177 };
178 
180 inline bool operator==(const ObjectFactory& lhs, const ObjectFactory& rhs)
181 {
182  return static_cast<const LocalObject&>(lhs) == static_cast<const LocalObject&>(rhs);
183 }
184 
185 inline bool operator<(const ObjectFactory& lhs, const ObjectFactory& rhs)
186 {
187  return static_cast<const LocalObject&>(lhs) < static_cast<const LocalObject&>(rhs);
188 }
190 
191 }
192 
194 namespace Ice
195 {
196 
197 }
199 
200 #endif
201 
203 #endif
Optional.h
StreamHelpers.h
ICE_DEPRECATED_API
#define ICE_DEPRECATED_API(msg)
Definition: Config.h:217
Ice::upCast
IceUtil::Shared * upCast(::Ice::LocalObject *)
ICE_API
#define ICE_API
Definition: Config.h:197
ICE_MEMBER
#define ICE_MEMBER(API)
Definition: Config.h:177
Ice::Value
The base class for instances of Slice classes.
Definition: Value.h:24
LocalObject.h
PushDisableWarnings.h
Ice::ObjectFactory
A factory for objects.
Definition: ObjectFactory.h:74
ProxyF.h
Ice::operator<
bool operator<(const C &lhs, const C &rhs)
Relational operator for generated structs and classes.
Definition: Comparable.h:136
Ice::ValueFactory
::std::function<::std::shared_ptr< Value >(const ::std::string &type)> ValueFactory
Create a new value for a given value type.
Definition: ValueFactory.h:77
UndefSysMacros.h
ObjectF.h
Ice
Definition: BuiltinSequences.h:56
Comparable.h
ScopedArray.h
Exception.h
ValueF.h
Ice::ObjectFactory::~ObjectFactory
virtual ~ObjectFactory()
PopDisableWarnings.h