Upcall_Wrapper.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 //=============================================================================
00004 /**
00005  *  @file    Upcall_Wrapper.h
00006  *
00007  *  $Id: Upcall_Wrapper.h 78248 2007-05-02 14:03:48Z johnnyw $
00008  *
00009  *  @author Ossama Othman
00010  *  @author Jeff Parsons
00011  *  @author Carlos O'Ryan
00012  */
00013 //=============================================================================
00014 
00015 #ifndef TAO_UPCALL_WRAPPER_H
00016 #define TAO_UPCALL_WRAPPER_H
00017 
00018 #include /**/ "ace/pre.h"
00019 
00020 #include "tao/PortableServer/portableserver_export.h"
00021 
00022 #ifndef ACE_LACKS_PRAGMA_ONCE
00023 # pragma once
00024 #endif /* !ACE_LACKS_PRAGMA_ONCE */
00025 
00026 #include "tao/Basic_Types.h"
00027 #include "tao/orbconf.h"
00028 
00029 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00030 
00031 class TAO_ServantBase;
00032 class TAO_ServerRequest;
00033 class TAO_InputCDR;
00034 class TAO_OutputCDR;
00035 
00036 namespace PortableServer
00037 {
00038   typedef ::TAO_ServantBase ServantBase;
00039 }
00040 
00041 namespace TAO
00042 {
00043   class Argument;
00044   class Upcall_Command;
00045 
00046   /**
00047    * @class Upcall_Wrapper
00048    *
00049    * @brief Wraps the activities of the _skel operations.
00050    *
00051    */
00052   class TAO_PortableServer_Export Upcall_Wrapper
00053   {
00054   public:
00055 
00056     /**
00057      * @note The TAO::Argument corresponding to the return value is
00058      *       always the first element in the array, regardless of
00059      *       whether or not the return type is void.
00060      */
00061 
00062     /// Perform the upcall.
00063     /**
00064      * @param server_request Object containing server side messaging
00065      *                       operations (e.g. CDR reply construction, etc).
00066      * @param args           Operation argument list.
00067      * @param nargs          Number of arguments in the operation
00068      *                       argument list.
00069      * @param command        @c Command object that performs the
00070      *                       actual upcall into the servant.
00071      *
00072      * @param servant_upcall Object containing information for POA
00073      *                       that dispatched the servant.
00074      * @param exceptions     Array of user exceptions the operation
00075      *                       may raise.
00076      * @param nexceptions    The number of exceptions in the operation
00077      *                       user exception array.
00078      */
00079     void upcall (TAO_ServerRequest & server_request,
00080                  TAO::Argument * const args[],
00081                  size_t nargs,
00082                  TAO::Upcall_Command & command
00083 #if TAO_HAS_INTERCEPTORS == 1
00084                  , void * servant_upcall
00085                  , CORBA::TypeCode_ptr const * exceptions
00086                  , CORBA::ULong nexceptions
00087 #endif  /* TAO_HAS_INTERCEPTORS == 1 */
00088                 );
00089 
00090   private:
00091 
00092 
00093     /// Perform pre-upcall operations.
00094     /**
00095      * Perform pre-upcall operations, including operation @c IN and
00096      * @c INOUT argument demarshaling.
00097      */
00098     void pre_upcall (TAO_InputCDR & cdr,
00099                      TAO::Argument * const * args,
00100                      size_t nargs);
00101 
00102     /// Perform post-upcall operations.
00103     /**
00104      * Perform post-upcall operations, including operation @c INOUT
00105      * and @c OUT argument marshaling.
00106      */
00107     void post_upcall (TAO_OutputCDR & cdr,
00108                       TAO::Argument * const * args,
00109                       size_t nargs);
00110 
00111   };
00112 
00113 }  // End namespace TAO
00114 
00115 TAO_END_VERSIONED_NAMESPACE_DECL
00116 
00117 #include /**/ "ace/post.h"
00118 
00119 #endif /* TAO_UPCALL_WRAPPER_H */

Generated on Tue Feb 2 17:40:54 2010 for TAO_PortableServer by  doxygen 1.4.7