diff options
Diffstat (limited to 'TAO/orbsvcs/examples/LoadBalancing/ServerRequestInterceptor.cpp')
-rw-r--r-- | TAO/orbsvcs/examples/LoadBalancing/ServerRequestInterceptor.cpp | 82 |
1 files changed, 82 insertions, 0 deletions
diff --git a/TAO/orbsvcs/examples/LoadBalancing/ServerRequestInterceptor.cpp b/TAO/orbsvcs/examples/LoadBalancing/ServerRequestInterceptor.cpp new file mode 100644 index 00000000000..8deb50cae85 --- /dev/null +++ b/TAO/orbsvcs/examples/LoadBalancing/ServerRequestInterceptor.cpp @@ -0,0 +1,82 @@ +#include "ServerRequestInterceptor.h" + +ACE_RCSID (LoadBalancing, + ServerRequestInterceptor, + "$Id$") + + +ServerRequestInterceptor::ServerRequestInterceptor (void) + : request_count_ (0) +{ +} + +ServerRequestInterceptor::~ServerRequestInterceptor (void) +{ +} + +char * +ServerRequestInterceptor::name (ACE_ENV_SINGLE_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((CORBA::SystemException)) +{ + return CORBA::string_dup ("ServerRequestInterceptor"); +} + +void +ServerRequestInterceptor::destroy (ACE_ENV_SINGLE_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((CORBA::SystemException)) +{ +} + +void +ServerRequestInterceptor::receive_request_service_contexts ( + PortableInterceptor::ServerRequestInfo_ptr /* ri */ + ACE_ENV_ARG_DECL) + ACE_THROW_SPEC ((CORBA::SystemException, + PortableInterceptor::ForwardRequest)) +{ + ++this->request_count_; +} + +void +ServerRequestInterceptor::receive_request ( + PortableInterceptor::ServerRequestInfo_ptr + ACE_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((CORBA::SystemException, + PortableInterceptor::ForwardRequest)) +{ +} + +void +ServerRequestInterceptor::send_reply ( + PortableInterceptor::ServerRequestInfo_ptr /* ri */ + ACE_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((CORBA::SystemException)) +{ +} + +void +ServerRequestInterceptor::send_exception ( + PortableInterceptor::ServerRequestInfo_ptr + ACE_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((CORBA::SystemException, + PortableInterceptor::ForwardRequest)) +{ +} + +void +ServerRequestInterceptor::send_other ( + PortableInterceptor::ServerRequestInfo_ptr + ACE_ENV_ARG_DECL) + ACE_THROW_SPEC ((CORBA::SystemException, + PortableInterceptor::ForwardRequest)) +{ +} + +CORBA::Long +ServerRequestInterceptor::request_count (void) +{ + const CORBA::Long r = this->request_count_.value (); + this->request_count_ = 0; + + return r; +} |