summaryrefslogtreecommitdiff
path: root/TAO/tao/Messaging/Messaging.h
blob: ba4077c94cbbe714c5688f7bcb5eaa878a73807b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
// -*- C++ -*-

// ================================================================
/**
 *  @file Messaging.h
 *
 *  $Id$
 *
 *  Include all the required headers to use CORBA Messaging easily.
 *
 *  @author Carlos O'Ryan <coryan@uci.edu>
 */
// ================================================================

#ifndef TAO_MESSAGING_H
#define TAO_MESSAGING_H
#include /**/ "ace/pre.h"


#include "messaging_export.h"

class TAO_Messaging_Export TAO_Messaging_Initializer
{
public:
  /// Used to force the initialisation of the ORB code.
  static int init (void);
};

static int
TAO_Requires_Messaging_Initializer = TAO_Messaging_Initializer::init ();

#define TAO_MESSAGING_SAFE_INCLUDE
#include "MessagingC.h"
#undef TAO_MESSAGING_SAFE_INCLUDE

#include "MessagingA.h"
#include "TAO_ExtC.h"
#include "tao/TAOC.h"


// Typedef for the Reply Handler Skeleton.
// This is handcrafted not generated by the IDL compiler.

class TAO_InputCDR;

enum TAO_AMI_Reply_Status
{
  /// Reply is normal.
  TAO_AMI_REPLY_OK,

  /// Reply is not normal and no exceptions
  TAO_AMI_REPLY_NOT_OK,

  /// An user exception was raised.
  TAO_AMI_REPLY_USER_EXCEPTION,

  /// An system exception was raised.
  TAO_AMI_REPLY_SYSTEM_EXCEPTION
};


typedef void (*TAO_Reply_Handler_Skeleton)(
    TAO_InputCDR &,
    Messaging::ReplyHandler_ptr,
    CORBA::ULong reply_status
    ACE_ENV_ARG_DECL_NOT_USED
    );

namespace TAO
{
  struct Exception_Data;
}

/**
 * @namespace TAO_Messaging_Helper
 *
 * @brief Define helper functions for the CORBA Messaging
 * implementation in TAO.
 */
namespace TAO_Messaging_Helper
{
  /// Implement the code shared by all the ExceptionHolder::raise_*()
  /// operations
  void TAO_Messaging_Export exception_holder_raise (
           TAO::Exception_Data *exception_data,
           CORBA::ULong exception_count,
           CORBA::Octet *marshaled_data,
           CORBA::ULong marshaled_data_length,
           CORBA::Boolean byte_order,
           CORBA::Boolean is_system_exception
           ACE_ENV_ARG_DECL);
}


#include /**/ "ace/post.h"
#endif /* TAO_MESSAGING_H */