diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2006-03-16 13:53:32 +0000 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2006-03-16 13:53:32 +0000 |
commit | 8bcf04a19c9f6c44bd38bef47ee1b557f40fb72f (patch) | |
tree | 8cfd4780df192fd3678697ebd75c2ab54f22a631 /cpp/src/Ice/Object.cpp | |
parent | more attack test (diff) | |
download | ice-8bcf04a19c9f6c44bd38bef47ee1b557f40fb72f.tar.bz2 ice-8bcf04a19c9f6c44bd38bef47ee1b557f40fb72f.tar.xz ice-8bcf04a19c9f6c44bd38bef47ee1b557f40fb72f.zip |
Added BlobjectArray
Diffstat (limited to 'cpp/src/Ice/Object.cpp')
-rw-r--r-- | cpp/src/Ice/Object.cpp | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/cpp/src/Ice/Object.cpp b/cpp/src/Ice/Object.cpp index f07dddce0ad..0b5ce8a9ff2 100644 --- a/cpp/src/Ice/Object.cpp +++ b/cpp/src/Ice/Object.cpp @@ -299,6 +299,26 @@ Ice::Blobject::__dispatch(Incoming& in, const Current& current) } DispatchStatus +Ice::BlobjectArray::__dispatch(Incoming& in, const Current& current) +{ + pair<const Byte*, const Byte*> inParams; + vector<Byte> outParams; + Int sz = in.is()->getReadEncapsSize(); + in.is()->readBlob(inParams.first, sz); + inParams.second = inParams.first + sz; + bool ok = ice_invoke(inParams, outParams, current); + in.os()->writeBlob(outParams); + if(ok) + { + return DispatchOK; + } + else + { + return DispatchUserException; + } +} + +DispatchStatus Ice::BlobjectAsync::__dispatch(Incoming& in, const Current& current) { vector<Byte> inParams; @@ -324,6 +344,32 @@ Ice::BlobjectAsync::__dispatch(Incoming& in, const Current& current) return DispatchAsync; } +DispatchStatus +Ice::BlobjectArrayAsync::__dispatch(Incoming& in, const Current& current) +{ + pair<const Byte*, const Byte*> inParams; + Int sz = in.is()->getReadEncapsSize(); + in.is()->readBlob(inParams.first, sz); + inParams.second = inParams.first + sz; + AMD_Object_ice_invokePtr cb = new ::IceAsync::Ice::AMD_Object_ice_invoke(in); + try + { + ice_invoke_async(cb, inParams, current); + } + catch(const Exception& ex) + { + cb->ice_exception(ex); + } + catch(const ::std::exception& ex) + { + cb->ice_exception(ex); + } + catch(...) + { + cb->ice_exception(); + } + return DispatchAsync; +} void Ice::ice_writeObject(const OutputStreamPtr& out, const ObjectPtr& p) { |