diff options
Diffstat (limited to 'cpp/include/Ice/Incoming.h')
-rw-r--r-- | cpp/include/Ice/Incoming.h | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/cpp/include/Ice/Incoming.h b/cpp/include/Ice/Incoming.h index 8279f7d18cf..03193854195 100644 --- a/cpp/include/Ice/Incoming.h +++ b/cpp/include/Ice/Incoming.h @@ -14,7 +14,8 @@ #include <Ice/ConnectionIF.h> #include <Ice/ServantLocatorF.h> #include <Ice/ServantManagerF.h> -#include <Ice/BasicStream.h> +#include <Ice/OutputStream.h> +#include <Ice/InputStream.h> #include <Ice/Object.h> #include <Ice/Current.h> #include <Ice/IncomingAsyncF.h> @@ -32,7 +33,7 @@ public: void __adopt(IncomingBase&); - BasicStream* __startWriteParams(Ice::FormatType); + Ice::OutputStream* __startWriteParams(Ice::FormatType); void __endWriteParams(bool); void __writeEmptyParams(); void __writeParamEncaps(const Ice::Byte*, Ice::Int, bool); @@ -40,7 +41,7 @@ public: protected: - IncomingBase(Instance*, ResponseHandler*, Ice::Connection*, const Ice::ObjectAdapterPtr&, bool, Ice::Byte, + IncomingBase(Instance*, ResponseHandler*, Ice::Connection*, const Ice::ObjectAdapterPtr&, bool, Ice::Byte, Ice::Int); IncomingBase(IncomingBase&); // Adopts the argument. It must not be used afterwards. @@ -55,12 +56,16 @@ protected: Ice::Current _current; Ice::ObjectPtr _servant; Ice::ServantLocatorPtr _locator; +#ifdef ICE_CPP11_MAPPING + ::std::shared_ptr<void> _cookie; +#else Ice::LocalObjectPtr _cookie; +#endif DispatchObserver _observer; bool _response; Ice::Byte _compress; - BasicStream _os; + Ice::OutputStream _os; // // Optimization. The request handler may not be deleted while a @@ -86,42 +91,42 @@ public: void pop(); void startOver(); void killAsync(); - void setActive(IncomingAsync&); - + void setActive(IncomingAsyncPtr); + bool isRetriable() { return _inParamPos != 0; } - void invoke(const ServantManagerPtr&, BasicStream*); + void invoke(const ServantManagerPtr&, Ice::InputStream*); // Inlined for speed optimization. - BasicStream* startReadParams() + Ice::InputStream* startReadParams() { // // Remember the encoding used by the input parameters, we'll // encode the response parameters with the same encoding. // - _current.encoding = _is->startReadEncaps(); + _current.encoding = _is->startEncapsulation(); return _is; } void endReadParams() const { - _is->endReadEncaps(); + _is->endEncapsulation(); } void readEmptyParams() { - _current.encoding = _is->skipEmptyEncaps(); + _current.encoding = _is->skipEmptyEncapsulation(); } void readParamEncaps(const Ice::Byte*& v, Ice::Int& sz) { - _current.encoding = _is->readEncaps(v, sz); + _current.encoding = _is->readEncapsulation(v, sz); } private: - BasicStream* _is; - + Ice::InputStream* _is; + IncomingAsyncPtr _cb; Ice::Byte* _inParamPos; }; |