Revert "Minor modernization of DynamicAny code"
[ACE_TAO.git] / TAO / tao / CORBA_methods.h
blobc7030701405307edfe9723592860b6ee1da8f52b
1 // -*- C++ -*-
2 //=============================================================================
3 /**
4 * @file CORBA_methods.h
6 * Declarations of common methods in the CORBA namespace.
8 * @author Jeff Parsons
9 */
10 //=============================================================================
12 #ifndef TAO_CORBA_METHODS_H
13 #define TAO_CORBA_METHODS_H
15 #include /**/ "ace/pre.h"
17 #include /**/ "tao/TAO_Export.h"
19 #if !defined (ACE_LACKS_PRAGMA_ONCE)
20 # pragma once
21 #endif /* ACE_LACKS_PRAGMA_ONCE */
23 #include "tao/Basic_Types.h"
24 #include "tao/orbconf.h"
26 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
28 namespace CORBA
30 class ORB;
31 typedef ORB *ORB_ptr;
33 /**
34 * ORB Initialization
36 extern TAO_Export ORB_ptr ORB_init (int & argc,
37 char * argv[],
38 const char * orb_name = 0);
39 #if defined (ACE_USES_WCHAR)
40 extern TAO_Export ORB_ptr ORB_init (int & argc,
41 wchar_t * argv[],
42 const char * orb_name = 0);
44 extern TAO_Export ORB_ptr ORB_init (int & argc,
45 wchar_t * argv[],
46 const wchar_t * orb_name);
47 #endif
49 template<typename T> inline Boolean is_nil (T x)
51 return x == 0;
54 template<typename T> inline void release (T x)
56 if (x)
58 x->_decr_refcount ();
63 TAO_END_VERSIONED_NAMESPACE_DECL
65 #include /**/ "ace/post.h"
67 #endif /* TAO_CORBA_METHODS_H */