Ice 3.7 C++98 API Reference
Loading...
Searching...
No Matches
ObjectAdapter.h
Go to the documentation of this file.
1//
2// Copyright (c) ZeroC, Inc. All rights reserved.
3//
4//
5// Ice version 3.7.11
6//
7// <auto-generated>
8//
9// Generated from file `ObjectAdapter.ice'
10//
11// Warning: do not edit this file.
12//
13// </auto-generated>
14//
15
16#ifndef __Ice_ObjectAdapter_h__
17#define __Ice_ObjectAdapter_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 <Ice/Proxy.h>
28#include <Ice/Object.h>
29#include <Ice/GCObject.h>
30#include <Ice/Value.h>
31#include <Ice/Incoming.h>
32#include <Ice/IncomingAsync.h>
34#include <IceUtil/ScopedArray.h>
35#include <Ice/Optional.h>
37#include <Ice/CommunicatorF.h>
38#include <Ice/ServantLocatorF.h>
39#include <Ice/Locator.h>
40#include <Ice/FacetMap.h>
41#include <Ice/Endpoint.h>
43
44#ifndef ICE_IGNORE_VERSION
45# if ICE_INT_VERSION / 100 != 307
46# error Ice version mismatch!
47# endif
48# if ICE_INT_VERSION % 100 >= 50
49# error Beta header file detected
50# endif
51# if ICE_INT_VERSION % 100 < 11
52# error Ice patch level mismatch!
53# endif
54#endif
55
56#ifndef ICE_API
57# if defined(ICE_STATIC_LIBS)
58# define ICE_API /**/
59# elif defined(ICE_API_EXPORTS)
60# define ICE_API ICE_DECLSPEC_EXPORT
61# else
62# define ICE_API ICE_DECLSPEC_IMPORT
63# endif
64#endif
65
66#ifdef ICE_CPP11_MAPPING // C++11 mapping
67
68namespace Ice
69{
70
71class ObjectAdapter;
72
73}
74
75namespace Ice
76{
77
89class ICE_CLASS(ICE_API) ObjectAdapter
90{
91public:
92
93 ICE_MEMBER(ICE_API) virtual ~ObjectAdapter();
94
99 virtual ::std::string getName() const noexcept = 0;
100
106 virtual ::std::shared_ptr<::Ice::Communicator> getCommunicator() const noexcept = 0;
107
115 virtual void activate() = 0;
116
129 virtual void hold() = 0;
130
139 virtual void waitForHold() = 0;
140
163 virtual void deactivate() noexcept = 0;
164
174 virtual void waitForDeactivate() noexcept = 0;
175
181 virtual bool isDeactivated() const noexcept = 0;
182
194 virtual void destroy() noexcept = 0;
195
212 virtual ::std::shared_ptr<::Ice::ObjectPrx> add(const ::std::shared_ptr<Object>& servant, const Identity& id) = 0;
213
229 virtual ::std::shared_ptr<::Ice::ObjectPrx> addFacet(const ::std::shared_ptr<Object>& servant, const Identity& id, const ::std::string& facet) = 0;
230
245 virtual ::std::shared_ptr<::Ice::ObjectPrx> addWithUUID(const ::std::shared_ptr<Object>& servant) = 0;
246
262 virtual ::std::shared_ptr<::Ice::ObjectPrx> addFacetWithUUID(const ::std::shared_ptr<Object>& servant, const ::std::string& facet) = 0;
263
297 virtual void addDefaultServant(const ::std::shared_ptr<Object>& servant, const ::std::string& category) = 0;
298
312 virtual ::std::shared_ptr<::Ice::Object> remove(const Identity& id) = 0;
313
325 virtual ::std::shared_ptr<::Ice::Object> removeFacet(const Identity& id, const ::std::string& facet) = 0;
326
338 virtual ::Ice::FacetMap removeAllFacets(const Identity& id) = 0;
339
349 virtual ::std::shared_ptr<::Ice::Object> removeDefaultServant(const ::std::string& category) = 0;
350
366 virtual ::std::shared_ptr<::Ice::Object> find(const Identity& id) const = 0;
367
383 virtual ::std::shared_ptr<::Ice::Object> findFacet(const Identity& id, const ::std::string& facet) const = 0;
384
396 virtual ::Ice::FacetMap findAllFacets(const Identity& id) const = 0;
397
411 virtual ::std::shared_ptr<::Ice::Object> findByProxy(const ::std::shared_ptr<ObjectPrx>& proxy) const = 0;
412
454 virtual void addServantLocator(const ::std::shared_ptr<ServantLocator>& locator, const ::std::string& category) = 0;
455
468 virtual ::std::shared_ptr<::Ice::ServantLocator> removeServantLocator(const ::std::string& category) = 0;
469
482 virtual ::std::shared_ptr<::Ice::ServantLocator> findServantLocator(const ::std::string& category) const = 0;
483
492 virtual ::std::shared_ptr<::Ice::Object> findDefaultServant(const ::std::string& category) const = 0;
493
506 virtual ::std::shared_ptr<::Ice::ObjectPrx> createProxy(const Identity& id) const = 0;
507
516 virtual ::std::shared_ptr<::Ice::ObjectPrx> createDirectProxy(const Identity& id) const = 0;
517
527 virtual ::std::shared_ptr<::Ice::ObjectPrx> createIndirectProxy(const Identity& id) const = 0;
528
541 virtual void setLocator(const ::std::shared_ptr<LocatorPrx>& loc) = 0;
542
550 virtual ::std::shared_ptr<::Ice::LocatorPrx> getLocator() const noexcept = 0;
551
557 virtual ::Ice::EndpointSeq getEndpoints() const noexcept = 0;
558
567 virtual void refreshPublishedEndpoints() = 0;
568
576 virtual ::Ice::EndpointSeq getPublishedEndpoints() const noexcept = 0;
577
585 virtual void setPublishedEndpoints(const EndpointSeq& newEndpoints) = 0;
586};
587
588}
589
591namespace Ice
592{
593
594}
596
598namespace Ice
599{
600
601using ObjectAdapterPtr = ::std::shared_ptr<ObjectAdapter>;
602
603}
605
606#else // C++98 mapping
607
608namespace IceProxy
609{
610
611}
612
613namespace Ice
614{
615
616class ObjectAdapter;
618ICE_API LocalObject* upCast(ObjectAdapter*);
620typedef ::IceInternal::Handle< ObjectAdapter> ObjectAdapterPtr;
621
622}
623
625namespace IceAsync
626{
627
628}
630
631namespace IceProxy
632{
633
634}
635
636namespace Ice
637{
638
650class ICE_API ObjectAdapter : public virtual LocalObject
651{
652public:
653
655
656 virtual ~ObjectAdapter();
657
658#ifdef ICE_CPP11_COMPILER
659 ObjectAdapter() = default;
660 ObjectAdapter(const ObjectAdapter&) = default;
661 ObjectAdapter& operator=(const ObjectAdapter&) = default;
662#endif
663
668 virtual ::std::string getName() const ICE_NOEXCEPT = 0;
669
676
684 virtual void activate() = 0;
685
698 virtual void hold() = 0;
699
708 virtual void waitForHold() = 0;
709
732 virtual void deactivate() ICE_NOEXCEPT = 0;
733
743 virtual void waitForDeactivate() ICE_NOEXCEPT = 0;
744
750 virtual bool isDeactivated() const ICE_NOEXCEPT = 0;
751
763 virtual void destroy() ICE_NOEXCEPT = 0;
764
781 virtual ObjectPrx add(const ObjectPtr& servant, const Identity& id) = 0;
782
798 virtual ObjectPrx addFacet(const ObjectPtr& servant, const Identity& id, const ::std::string& facet) = 0;
799
814 virtual ObjectPrx addWithUUID(const ObjectPtr& servant) = 0;
815
831 virtual ObjectPrx addFacetWithUUID(const ObjectPtr& servant, const ::std::string& facet) = 0;
832
866 virtual void addDefaultServant(const ObjectPtr& servant, const ::std::string& category) = 0;
867
881 virtual ObjectPtr remove(const Identity& id) = 0;
882
894 virtual ObjectPtr removeFacet(const Identity& id, const ::std::string& facet) = 0;
895
907 virtual FacetMap removeAllFacets(const Identity& id) = 0;
908
918 virtual ObjectPtr removeDefaultServant(const ::std::string& category) = 0;
919
935 virtual ObjectPtr find(const Identity& id) const = 0;
936
952 virtual ObjectPtr findFacet(const Identity& id, const ::std::string& facet) const = 0;
953
965 virtual FacetMap findAllFacets(const Identity& id) const = 0;
966
980 virtual ObjectPtr findByProxy(const ObjectPrx& proxy) const = 0;
981
1023 virtual void addServantLocator(const ServantLocatorPtr& locator, const ::std::string& category) = 0;
1024
1037 virtual ServantLocatorPtr removeServantLocator(const ::std::string& category) = 0;
1038
1051 virtual ServantLocatorPtr findServantLocator(const ::std::string& category) const = 0;
1052
1061 virtual ObjectPtr findDefaultServant(const ::std::string& category) const = 0;
1062
1075 virtual ObjectPrx createProxy(const Identity& id) const = 0;
1076
1085 virtual ObjectPrx createDirectProxy(const Identity& id) const = 0;
1086
1096 virtual ObjectPrx createIndirectProxy(const Identity& id) const = 0;
1097
1110 virtual void setLocator(const LocatorPrx& loc) = 0;
1111
1120
1127
1136 virtual void refreshPublishedEndpoints() = 0;
1137
1146
1154 virtual void setPublishedEndpoints(const EndpointSeq& newEndpoints) = 0;
1155};
1156
1158inline bool operator==(const ObjectAdapter& lhs, const ObjectAdapter& rhs)
1159{
1160 return static_cast<const LocalObject&>(lhs) == static_cast<const LocalObject&>(rhs);
1161}
1162
1163inline bool operator<(const ObjectAdapter& lhs, const ObjectAdapter& rhs)
1164{
1165 return static_cast<const LocalObject&>(lhs) < static_cast<const LocalObject&>(rhs);
1166}
1168
1169}
1170
1172namespace Ice
1173{
1174
1175}
1177
1178#endif
1179
1181#endif
#define ICE_API
Definition Config.h:197
#define ICE_NOEXCEPT
Definition Config.h:128
#define ICE_MEMBER(API)
Definition Config.h:177
Shared & operator=(const Shared &)
Definition Shared.h:94
Base class for local Slice classes and interfaces.
Definition LocalObject.h:25
The object adapter provides an up-call interface from the Ice run time to the implementation of Ice o...
Definition ObjectAdapter.h:651
virtual::std::string getName() const =0
Get the name of this object adapter.
virtual ObjectPrx addFacet(const ObjectPtr &servant, const Identity &id, const ::std::string &facet)=0
Like add, but with a facet.
virtual ServantLocatorPtr findServantLocator(const ::std::string &category) const =0
Find a Servant Locator installed with this object adapter.
virtual EndpointSeq getPublishedEndpoints() const =0
Get the set of endpoints that proxies created by this object adapter will contain.
virtual ObjectPtr remove(const Identity &id)=0
Remove a servant (that is, the default facet) from the object adapter's Active Servant Map.
virtual ObjectPrx add(const ObjectPtr &servant, const Identity &id)=0
Add a servant to this object adapter's Active Servant Map.
ObjectAdapterPtr PointerType
Definition ObjectAdapter.h:654
virtual void addDefaultServant(const ObjectPtr &servant, const ::std::string &category)=0
Add a default servant to handle requests for a specific category.
virtual LocatorPrx getLocator() const =0
Get the Ice locator used by this object adapter.
virtual ObjectPrx addFacetWithUUID(const ObjectPtr &servant, const ::std::string &facet)=0
Like addWithUUID, but with a facet.
virtual ObjectPtr removeFacet(const Identity &id, const ::std::string &facet)=0
Like remove, but with a facet.
virtual void waitForDeactivate()=0
Wait until the object adapter has deactivated.
virtual EndpointSeq getEndpoints() const =0
Get the set of endpoints configured with this object adapter.
virtual ObjectPtr removeDefaultServant(const ::std::string &category)=0
Remove the default servant for a specific category.
virtual ~ObjectAdapter()
virtual void destroy()=0
Destroys the object adapter and cleans up all resources held by the object adapter.
virtual void activate()=0
Activate all endpoints that belong to this object adapter.
virtual CommunicatorPtr getCommunicator() const =0
Get the communicator this object adapter belongs to.
virtual void hold()=0
Temporarily hold receiving and dispatching requests.
virtual ObjectPrx createIndirectProxy(const Identity &id) const =0
Create an indirect proxy for the object with the given identity.
virtual void waitForHold()=0
Wait until the object adapter holds requests.
virtual void setLocator(const LocatorPrx &loc)=0
Set an Ice locator for this object adapter.
virtual ObjectPtr findFacet(const Identity &id, const ::std::string &facet) const =0
Like find, but with a facet.
virtual FacetMap findAllFacets(const Identity &id) const =0
Find all facets with the given identity in the Active Servant Map.
virtual void deactivate()=0
Deactivate all endpoints that belong to this object adapter.
virtual FacetMap removeAllFacets(const Identity &id)=0
Remove all facets with the given identity from the Active Servant Map.
virtual ObjectPrx createProxy(const Identity &id) const =0
Create a proxy for the object with the given identity.
virtual void refreshPublishedEndpoints()=0
Refresh the set of published endpoints.
virtual ObjectPrx addWithUUID(const ObjectPtr &servant)=0
Add a servant to this object adapter's Active Servant Map, using an automatically generated UUID as i...
virtual void addServantLocator(const ServantLocatorPtr &locator, const ::std::string &category)=0
Add a Servant Locator to this object adapter.
virtual ObjectPrx createDirectProxy(const Identity &id) const =0
Create a direct proxy for the object with the given identity.
virtual void setPublishedEndpoints(const EndpointSeq &newEndpoints)=0
Set of the endpoints that proxies created by this object adapter will contain.
virtual ObjectPtr find(const Identity &id) const =0
Look up a servant in this object adapter's Active Servant Map by the identity of the Ice object it im...
virtual ObjectPtr findByProxy(const ObjectPrx &proxy) const =0
Look up a servant in this object adapter's Active Servant Map, given a proxy.
virtual ServantLocatorPtr removeServantLocator(const ::std::string &category)=0
Remove a Servant Locator from this object adapter.
virtual bool isDeactivated() const =0
Check whether object adapter has been deactivated.
virtual ObjectPtr findDefaultServant(const ::std::string &category) const =0
Find the default servant for a specific category.
Definition BuiltinSequences.h:113
IceInternal::Handle< Object > ObjectPtr
Definition ObjectF.h:21
::IceInternal::Handle< ServantLocator > ServantLocatorPtr
Definition ServantLocator.h:180
IceInternal::ProxyHandle< ::IceProxy::Ice::Object > ObjectPrx
Smart pointer for an object proxy.
Definition ProxyF.h:47
::std::map< ::std::string, ObjectPtr > FacetMap
A mapping from facet name to servant.
Definition FacetMap.h:73
::std::vector< EndpointPtr > EndpointSeq
A sequence of endpoints.
Definition EndpointF.h:152
::IceInternal::Handle< ObjectAdapter > ObjectAdapterPtr
Definition ObjectAdapter.h:620
::IceInternal::Handle< Communicator > CommunicatorPtr
Definition Communicator.h:608
IceUtil::Shared * upCast(::Ice::AsyncResult *)
::IceInternal::ProxyHandle< ::IceProxy::Ice::Locator > LocatorPrx
Definition Locator.h:1043
The identity of an Ice object.
Definition Identity.h:144