3
//=============================================================================
5
* @file LB_MemberLocator.h
7
* LB_MemberLocator.h,v 1.2 2003/07/21 23:51:31 dhinton Exp
9
* @author Ossama Othman <ossama@uci.edu>
11
//=============================================================================
14
#ifndef TAO_LB_MEMBER_LOCATOR_H
15
#define TAO_LB_MEMBER_LOCATOR_H
17
#include /**/ "ace/pre.h"
19
#include "ace/config-all.h"
21
# if !defined (ACE_LACKS_PRAGMA_ONCE)
23
# endif /* ACE_LACKS_PRAGMA_ONCE */
25
#include "tao/PortableServer/PortableServerC.h"
26
#include "tao/LocalObject.h"
28
// Forward declarations.
29
class TAO_LB_LoadManager;
33
* @class TAO_LB_MemberLocator
35
* @brief ServantLocator implementation for the Load Balancer.
37
* This is a Servant Locator implementation that forwards requests to
38
* a member returned by the Load Balancer.
40
class TAO_LB_MemberLocator
41
: public virtual PortableServer::ServantLocator,
42
public virtual TAO_Local_RefCounted_Object
47
TAO_LB_MemberLocator (TAO_LB_LoadManager * load_balancer);
50
* @name The PortableServer::ServantLocator methods.
52
* Methods required by the PortableServer::ServantLocator
57
/// Clients requests are forwarded via the
58
/// PortableServer::ForwardRequest exception thrown in this method.
59
virtual PortableServer::Servant preinvoke (
60
const PortableServer::ObjectId & oid,
61
PortableServer::POA_ptr adapter,
62
const char * operation,
63
PortableServer::ServantLocator::Cookie & the_cookie
65
ACE_THROW_SPEC ((CORBA::SystemException,
66
PortableServer::ForwardRequest));
68
/// This method is no-op in this ServantLocator implementation.
69
virtual void postinvoke (
70
const PortableServer::ObjectId &oid,
71
PortableServer::POA_ptr adapter,
72
const char * operation,
73
PortableServer::ServantLocator::Cookie the_cookie,
74
PortableServer::Servant the_servant
76
ACE_THROW_SPEC ((CORBA::SystemException));
82
/// The load balancer/manager implementation.
83
TAO_LB_LoadManager * load_manager_;
87
#include /**/ "ace/post.h"
89
#endif /* TAO_LB_MEMBER_LOCATOR_H */