Merge pull request #2309 from mitza-oci/warnings
[ACE_TAO.git] / TAO / tao / CSD_ThreadPool / CSD_TP_Remote_Request.h
blob29079cf5ff3006fe7d4db8c49dc8d3f82bf874fd
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file CSD_TP_Remote_Request.h
7 * @author Tim Bradley <bradley_t@ociweb.com>
8 */
9 //=============================================================================
11 #ifndef TAO_CSD_TP_REMOTE_REQUEST_H
12 #define TAO_CSD_TP_REMOTE_REQUEST_H
14 #include /**/ "ace/pre.h"
16 #include "tao/CSD_ThreadPool/CSD_TP_Export.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 # pragma once
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
22 #include "tao/CSD_ThreadPool/CSD_TP_Corba_Request.h"
24 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
26 namespace TAO
28 namespace CSD
30 class TP_Remote_Request;
31 typedef TAO_Intrusive_Ref_Count_Handle<TP_Remote_Request>
32 TP_Remote_Request_Handle;
34 /**
35 * @class TP_Remote_Request
37 * @brief Represents a "queue-able", remote, CORBA request.
38 * Both syncronous and asynchronous remote CORBA requests
39 * are represented by the class.
41 * TBD - Go over the following comments and clean up.
43 * Since this class derives from the TP_Request class, it can be
44 * added to a TP_Queue (ie, it is a "queueable" request). It
45 * represents a servant request that has been made by a remote
46 * CORBA client (as opposed to a collocated CORBA client). The
47 * term "CORBA client" is being used here to distinguish CORBA
48 * servant requests (those made thru a CORBA object reference), and
49 * "Custom" servant requests that can be "dispatched" to the strategy
50 * directly by the client application code (ie, not thru a CORBA
51 * object reference). Thus, there are "CORBA clients" and
52 * "Direct clients".
54 * In summary, this class represents a servant request made when a
55 * remote client invokes a method on a CORBA object reference.
58 class TAO_CSD_TP_Export TP_Remote_Request : public TP_Corba_Request
60 public:
61 /// Constructor.
62 TP_Remote_Request(TAO_ServerRequest& server_request,
63 const PortableServer::ObjectId& object_id,
64 PortableServer::POA_ptr poa,
65 const char* operation,
66 PortableServer::Servant servant,
67 TP_Servant_State* servant_state);
69 /// Virtual Destructor.
70 virtual ~TP_Remote_Request();
73 protected:
74 /// Prepare this TP_Remote_Request object to be placed into the
75 /// request queue. This will cause the underlying TAO_ServerRequest
76 /// object to be cloned.
77 virtual void prepare_for_queue_i();
79 /// Dispatch the request to the servant.
80 virtual void dispatch_i();
82 /// Cancel the request.
83 virtual void cancel_i();
88 TAO_END_VERSIONED_NAMESPACE_DECL
90 #if defined (__ACE_INLINE__)
91 # include "tao/CSD_ThreadPool/CSD_TP_Remote_Request.inl"
92 #endif /* __ACE_INLINE__ */
94 #include /**/ "ace/post.h"
96 #endif /* TAO_CSD_TP_REMOTE_REQUEST_H */