diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-03-17 10:52:36 +0000 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-03-17 10:52:36 +0000 |
commit | 505947bad66886263ed5a18bb96d56bc7992a816 (patch) | |
tree | 5fe8336d56ce57be80b4a20f1997701a3d5d9d3b | |
parent | 8995bb9f46383c2e8149099694c65a8de626a16a (diff) | |
download | ATCD-505947bad66886263ed5a18bb96d56bc7992a816.tar.gz |
-rw-r--r-- | TAO/tao/Codeset/Codeset_Service_Context_Handler.cpp | 45 | ||||
-rw-r--r-- | TAO/tao/Codeset/Codeset_Service_Context_Handler.h | 45 |
2 files changed, 90 insertions, 0 deletions
diff --git a/TAO/tao/Codeset/Codeset_Service_Context_Handler.cpp b/TAO/tao/Codeset/Codeset_Service_Context_Handler.cpp new file mode 100644 index 00000000000..e94015d6beb --- /dev/null +++ b/TAO/tao/Codeset/Codeset_Service_Context_Handler.cpp @@ -0,0 +1,45 @@ +// $Id$ + +#include "tao/Codeset/Codeset_Service_Context_Handler.h" + +ACE_RCSID (Codeset, + Codeset_Service_Context_Handler, + "$Id$") + +#include "tao/CDR.h" +#include "tao/Transport.h" +#include "tao/ORB_Core.h" +#include "tao/Operation_Details.h" +#include "tao/Codeset_Manager.h" + +TAO_BEGIN_VERSIONED_NAMESPACE_DECL + +int +TAO_Codeset_Service_Context_Handler::process_service_context ( + TAO_Transport&, + const IOP::ServiceContext&) +{ + return 0; +} + +int +TAO_Codeset_Service_Context_Handler::generate_service_context ( + TAO_Stub *, + TAO_Transport& transport, + TAO_Operation_Details &opdetails, + TAO_Target_Specification &spec, + TAO_OutputCDR &msg) +{ + if (transport.first_request ()) + { + TAO_Codeset_Manager * const csm = transport.orb_core ()->codeset_manager (); + if (csm) + { + csm->generate_service_context (opdetails, transport); + } + } + + return 0; +} + +TAO_END_VERSIONED_NAMESPACE_DECL diff --git a/TAO/tao/Codeset/Codeset_Service_Context_Handler.h b/TAO/tao/Codeset/Codeset_Service_Context_Handler.h new file mode 100644 index 00000000000..381dbb0d480 --- /dev/null +++ b/TAO/tao/Codeset/Codeset_Service_Context_Handler.h @@ -0,0 +1,45 @@ +// -*- C++ -*- + +// =================================================================== +/** + * @file Codeset_Service_Context_Handler.h + * + * $Id$ + * + * @author Johnny Willemsen <jwillemsen@remedy.nl> + */ +// =================================================================== + +#ifndef TAO_CODESET_SERVICE_CONTEXT_HANDLER_H +#define TAO_CODESET_SERVICE_CONTEXT_HANDLER_H +#include /**/ "ace/pre.h" +#include "tao/Codeset/codeset_export.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +# pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "tao/Service_Context_Handler.h" + +TAO_BEGIN_VERSIONED_NAMESPACE_DECL + +class TAO_Stub; + +class TAO_Codeset_Service_Context_Handler : + public TAO_Service_Context_Handler +{ +public: + virtual int process_service_context (TAO_Transport& transport, + const IOP::ServiceContext& context); + virtual int generate_service_context ( + TAO_Stub* stub, + TAO_Transport &transport, + TAO_Operation_Details &opdetails, + TAO_Target_Specification &spec, + TAO_OutputCDR &msg); +}; + +TAO_END_VERSIONED_NAMESPACE_DECL + +#include /**/ "ace/post.h" +#endif /* TAO_CODESET_SERVICE_CONTEXT_HANDLER_H */ |