r2corba 1.5.4 → 1.5.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (152) hide show
  1. checksums.yaml +4 -4
  2. data/README.rdoc +2 -1
  3. data/ext/extload/extload.c +5 -6
  4. data/ext/libr2tao/object.cpp +4 -4
  5. data/ext/libr2tao/orb.cpp +8 -8
  6. data/ext/libr2tao/r2tao_ext.h +0 -12
  7. data/ext/libr2tao/required.cpp +2 -2
  8. data/ext/libr2tao/required.h +9 -11
  9. data/ext/libr2tao/values.cpp +5 -5
  10. data/ext/libr2tao/values.h +19 -19
  11. data/ext/librpoa/iortable.cpp +3 -3
  12. data/ext/librpoa/poa.cpp +7 -7
  13. data/ext/librpoa/servant.cpp +15 -90
  14. data/ext/librpoa/servant.h +13 -35
  15. data/lib/corba/cbase/ORB.rb +7 -7
  16. data/lib/corba/cbase/Streams.rb +2 -2
  17. data/lib/corba/cbase/Typecode.rb +6 -6
  18. data/lib/corba/cbase/exception.rb +2 -2
  19. data/lib/corba/cbase/policies.rb +1 -1
  20. data/lib/corba/cmds/base.rb +1 -1
  21. data/lib/corba/common/Any.rb +1 -1
  22. data/lib/corba/common/ORB.rb +1 -1
  23. data/lib/corba/common/Object.rb +0 -1
  24. data/lib/corba/common/Stub.rb +1 -1
  25. data/lib/corba/common/Typecode.rb +34 -34
  26. data/lib/corba/common/const.rb +2 -2
  27. data/lib/corba/common/version.rb +1 -1
  28. data/lib/corba/jbase/Any.rb +23 -23
  29. data/lib/corba/jbase/ORB.rb +3 -3
  30. data/lib/corba/jbase/Request.rb +5 -5
  31. data/lib/corba/jbase/Servant.rb +10 -10
  32. data/lib/corba/jbase/ServerRequest.rb +7 -7
  33. data/lib/corba/jbase/Streams.rb +3 -3
  34. data/lib/corba/jbase/Typecode.rb +14 -14
  35. data/lib/corba/jbase/exception.rb +1 -1
  36. data/lib/corba/jbase/poa.rb +2 -2
  37. data/lib/corba/jbase/policies.rb +3 -3
  38. data/lib/corba/poa.rb +1 -1
  39. data/lib/corba/policies.rb +1 -1
  40. data/lib/corba/require.rb +2 -2
  41. data/lib/corba/svcs/ins/cos_naming.rb +27 -27
  42. data/lib/corba/svcs/ins/ins.rb +17 -17
  43. data/lib/corba/svcs/ins/naming_service.rb +2 -2
  44. data/lib/ridlbe/ruby/config.rb +10 -10
  45. data/lib/ridlbe/ruby/walker.rb +21 -21
  46. data/mkrf_conf_srcgem.rb +5 -5
  47. data/rakelib/bin.rake +1 -1
  48. data/rakelib/bin.rb +3 -3
  49. data/rakelib/build.rake +15 -15
  50. data/rakelib/config.rb +13 -13
  51. data/rakelib/ext.rake +3 -5
  52. data/rakelib/ext.rb +13 -13
  53. data/rakelib/ext_r2tao.rb +12 -18
  54. data/rakelib/gem.rake +5 -5
  55. data/rakelib/gem.rb +5 -5
  56. data/test/BiDirectional/client.rb +3 -3
  57. data/test/BiDirectional/run_test.rb +1 -1
  58. data/test/BiDirectional/server.rb +4 -5
  59. data/test/CORBA_Services/Naming/BindingIterator/client.rb +5 -5
  60. data/test/CORBA_Services/Naming/BindingIterator/run_test.rb +1 -1
  61. data/test/CORBA_Services/Naming/BindingIterator/server.rb +4 -4
  62. data/test/CORBA_Services/Naming/Corbaname/client.rb +3 -3
  63. data/test/CORBA_Services/Naming/Corbaname/run_test.rb +1 -1
  64. data/test/CORBA_Services/Naming/Corbaname/server.rb +10 -10
  65. data/test/CORBA_Services/Naming/Simple/client.rb +4 -4
  66. data/test/CORBA_Services/Naming/Simple/run_test.rb +1 -1
  67. data/test/CORBA_Services/Naming/Simple/server.rb +4 -4
  68. data/test/Collocation/test.rb +2 -2
  69. data/test/Connect_Timeout/client.rb +3 -4
  70. data/test/DII/client.rb +5 -5
  71. data/test/DII/run_test.rb +1 -1
  72. data/test/DII/server.rb +3 -3
  73. data/test/DSI/client.rb +3 -3
  74. data/test/DSI/run_test.rb +1 -1
  75. data/test/DSI/server.rb +3 -3
  76. data/test/Exceptions/client.rb +4 -4
  77. data/test/Exceptions/run_test.rb +1 -1
  78. data/test/Exceptions/server.rb +3 -3
  79. data/test/Hello/client.rb +3 -3
  80. data/test/Hello/run_test.rb +1 -1
  81. data/test/Hello/server.rb +3 -3
  82. data/test/IDL_Test/client.rb +3 -3
  83. data/test/IDL_Test/run_test.rb +1 -1
  84. data/test/IDL_Test/server.rb +3 -3
  85. data/test/IORMap/client.rb +3 -3
  86. data/test/IORMap/run_test.rb +1 -1
  87. data/test/IORMap/server.rb +4 -4
  88. data/test/IORTable/client.rb +3 -3
  89. data/test/IORTable/run_test.rb +1 -1
  90. data/test/IORTable/server.rb +4 -4
  91. data/test/Implicit_Conversion/client.rb +4 -4
  92. data/test/Implicit_Conversion/run_test.rb +1 -1
  93. data/test/Implicit_Conversion/server.rb +3 -3
  94. data/test/Multi_Threading/Multiple_ORB/client.rb +3 -3
  95. data/test/Multi_Threading/Multiple_ORB/run_test.rb +2 -2
  96. data/test/Multi_Threading/Multiple_ORB/server.rb +3 -3
  97. data/test/Multi_Threading/Simple/client.rb +4 -4
  98. data/test/Multi_Threading/Simple/run_test.rb +1 -1
  99. data/test/Multi_Threading/Simple/server.rb +3 -3
  100. data/test/Multi_Threading/Threads/client.rb +3 -3
  101. data/test/Multi_Threading/Threads/run_test.rb +1 -1
  102. data/test/Multi_Threading/Threads/server.rb +4 -4
  103. data/test/Multi_Threading/Threads/watchdog.rb +3 -3
  104. data/test/Multiple_Servant_Interfaces/client.rb +3 -3
  105. data/test/Multiple_Servant_Interfaces/run_test.rb +1 -1
  106. data/test/Multiple_Servant_Interfaces/server.rb +3 -3
  107. data/test/Nil/test.rb +3 -4
  108. data/test/OBV/AbstractInterface/client.rb +3 -3
  109. data/test/OBV/AbstractInterface/run_test.rb +1 -1
  110. data/test/OBV/AbstractInterface/server.rb +3 -3
  111. data/test/OBV/Custom/client.rb +3 -3
  112. data/test/OBV/Custom/run_test.rb +1 -1
  113. data/test/OBV/Custom/server.rb +3 -3
  114. data/test/OBV/Simple/client.rb +3 -3
  115. data/test/OBV/Simple/run_test.rb +1 -1
  116. data/test/OBV/Simple/server.rb +3 -3
  117. data/test/OBV/Simple_Event/client.rb +3 -3
  118. data/test/OBV/Simple_Event/run_test.rb +1 -1
  119. data/test/OBV/Simple_Event/server.rb +3 -3
  120. data/test/OBV/Supports/client.rb +3 -3
  121. data/test/OBV/Supports/run_test.rb +1 -1
  122. data/test/OBV/Supports/server.rb +3 -3
  123. data/test/OBV/Tree/client.rb +3 -3
  124. data/test/OBV/Tree/run_test.rb +1 -1
  125. data/test/OBV/Tree/server.rb +3 -3
  126. data/test/OBV/Truncatable/Truncatable_impl.rb +1 -1
  127. data/test/OBV/Truncatable/client.rb +4 -4
  128. data/test/OBV/Truncatable/run_test.rb +1 -1
  129. data/test/OBV/Truncatable/server.rb +3 -3
  130. data/test/OBV/ValueBox/client.rb +44 -44
  131. data/test/OBV/ValueBox/run_test.rb +1 -1
  132. data/test/OBV/ValueBox/server.rb +29 -29
  133. data/test/Object/client.rb +4 -4
  134. data/test/Object/run_test.rb +1 -1
  135. data/test/Object/server.rb +3 -3
  136. data/test/POA/test.rb +3 -3
  137. data/test/Param_Test/client.rb +6 -6
  138. data/test/Param_Test/run_test.rb +1 -1
  139. data/test/Param_Test/server.rb +6 -6
  140. data/test/Performance/Simple/client.rb +3 -3
  141. data/test/Performance/Simple/run_test.rb +1 -1
  142. data/test/Performance/Simple/server.rb +3 -3
  143. data/test/Policies/test.rb +2 -3
  144. data/test/Timeout/client.rb +6 -6
  145. data/test/Timeout/run_test.rb +1 -1
  146. data/test/Timeout/server.rb +4 -4
  147. data/test/lib/assert.rb +0 -1
  148. data/test/lib/test.rb +14 -15
  149. data/test/test_runner.rb +5 -6
  150. metadata +4 -6
  151. data/ext/librpoa/srvreq_fix.cpp +0 -282
  152. data/ext/librpoa/srvreq_fix.h +0 -148
data/ext/librpoa/poa.cpp CHANGED
@@ -11,7 +11,6 @@
11
11
  #------------------------------------------------------------------*/
12
12
 
13
13
  #include "poa.h"
14
- #include "ace/Auto_Ptr.h"
15
14
  #include "tao/DynamicInterface/Server_Request.h"
16
15
  #include "tao/DynamicInterface/Dynamic_Implementation.h"
17
16
  #include "tao/AnyTypeCode/Any.h"
@@ -25,6 +24,7 @@
25
24
  #include "exception.h"
26
25
  #include "orb.h"
27
26
  #include "servant.h"
27
+ #include <memory>
28
28
 
29
29
  #define RUBY_INVOKE_FUNC RUBY_ALLOC_FUNC
30
30
 
@@ -171,7 +171,7 @@ public:
171
171
  R2TAO_POA_BlockedRegionCallerBase ()
172
172
  : exception_ (false),
173
173
  corba_ex_ (0) {}
174
- virtual ~R2TAO_POA_BlockedRegionCallerBase () R2CORBA_NO_EXCEPT_FALSE;
174
+ virtual ~R2TAO_POA_BlockedRegionCallerBase () noexcept(false);
175
175
 
176
176
  VALUE call ();
177
177
 
@@ -186,13 +186,13 @@ protected:
186
186
  CORBA::Exception* corba_ex_;
187
187
  };
188
188
 
189
- R2TAO_POA_BlockedRegionCallerBase::~R2TAO_POA_BlockedRegionCallerBase() R2CORBA_NO_EXCEPT_FALSE
189
+ R2TAO_POA_BlockedRegionCallerBase::~R2TAO_POA_BlockedRegionCallerBase() noexcept(false)
190
190
  {
191
191
  if (this->exception_)
192
192
  {
193
193
  if (corba_ex_)
194
194
  {
195
- ACE_Auto_Basic_Ptr<CORBA::Exception> e_ptr(corba_ex_);
195
+ std::unique_ptr<CORBA::Exception> e_ptr(corba_ex_);
196
196
  corba_ex_->_raise ();
197
197
  }
198
198
  else
@@ -974,7 +974,7 @@ public:
974
974
  protected:
975
975
  virtual VALUE do_exec ();
976
976
 
977
- bool wait_for_completion_;
977
+ bool const wait_for_completion_;
978
978
  };
979
979
 
980
980
  VALUE R2TAO_POAMan_BlockedDiscardReq::do_exec ()
@@ -1015,8 +1015,8 @@ public:
1015
1015
  protected:
1016
1016
  virtual VALUE do_exec ();
1017
1017
 
1018
- bool etherealize_;
1019
- bool wait_for_completion_;
1018
+ bool const etherealize_;
1019
+ bool const wait_for_completion_;
1020
1020
  };
1021
1021
 
1022
1022
  VALUE R2TAO_POAMan_BlockedDeactivate::do_exec ()
@@ -11,7 +11,6 @@
11
11
  #------------------------------------------------------------------*/
12
12
 
13
13
  #include "poa.h"
14
- #include "ace/Auto_Ptr.h"
15
14
  #include "tao/DynamicInterface/Server_Request.h"
16
15
  #include "tao/DynamicInterface/Dynamic_Implementation.h"
17
16
  #include "tao/AnyTypeCode/Any.h"
@@ -25,10 +24,7 @@
25
24
  #include "exception.h"
26
25
  #include "orb.h"
27
26
  #include "servant.h"
28
-
29
- #if RPOA_NEED_DSI_FIX
30
- # include "srvreq_fix.cpp"
31
- #endif
27
+ #include <memory>
32
28
 
33
29
  #define RUBY_INVOKE_FUNC RUBY_ALLOC_FUNC
34
30
 
@@ -113,12 +109,12 @@ void r2tao_init_Servant()
113
109
  //===================================================================
114
110
 
115
111
  struct DSI_Data {
116
- R2CORBA_ServerRequest_ptr _request;
112
+ CORBA::ServerRequest_ptr _request;
117
113
  CORBA::NVList_ptr _nvlist;
118
114
  CORBA::TypeCode_var _result_type;
119
115
  VALUE _rData;
120
116
 
121
- DSI_Data(R2CORBA_ServerRequest_ptr _req)
117
+ DSI_Data(CORBA::ServerRequest_ptr _req)
122
118
  : _request(_req), _nvlist(0), _rData(Qnil) {}
123
119
  ~DSI_Data() {
124
120
  if (this->_rData!=Qnil) { DATA_PTR(this->_rData) = 0; }
@@ -134,7 +130,7 @@ VALUE r2tao_ServerRequest_operation(VALUE self)
134
130
  {
135
131
  if (DATA_PTR (self) != 0)
136
132
  {
137
- R2CORBA_ServerRequest_ptr request = static_cast<DSI_Data*> (DATA_PTR (self))->_request;
133
+ CORBA::ServerRequest_ptr request = static_cast<DSI_Data*> (DATA_PTR (self))->_request;
138
134
  return rb_str_new2 (request->operation ());
139
135
  }
140
136
  return Qnil;
@@ -152,7 +148,7 @@ VALUE r2tao_ServerRequest_describe(VALUE self, VALUE desc)
152
148
  X_CORBA (BAD_INV_ORDER);
153
149
  }
154
150
 
155
- R2CORBA_ServerRequest_ptr request = dsi_data->_request;
151
+ CORBA::ServerRequest_ptr request = dsi_data->_request;
156
152
 
157
153
  if (desc != Qnil && rb_type (desc) == T_HASH)
158
154
  {
@@ -497,73 +493,6 @@ DSI_Servant::METHOD DSI_Servant::method_id (const char* method)
497
493
  return NONE;
498
494
  }
499
495
 
500
- #if RPOA_NEED_DSI_FIX
501
- void DSI_Servant::invoke (CORBA::ServerRequest_ptr /*request*/)
502
- {}
503
-
504
- void DSI_Servant::_dispatch (TAO_ServerRequest &request,
505
- void * /*context*/)
506
- {
507
- // No need to do any of this if the client isn't waiting.
508
- if (request.response_expected ())
509
- {
510
- if (request.is_forwarded ())
511
- {
512
- request.init_reply ();
513
- request.tao_send_reply ();
514
-
515
- // No need to invoke in this case.
516
- return;
517
- }
518
- else if (request.sync_with_server ())
519
- {
520
- // The last line before the call to this function
521
- // was an ACE_CHECK_RETURN, so if we're here, we
522
- // know there is no exception so far, and that's all
523
- // a SYNC_WITH_SERVER client request cares about.
524
- request.send_no_exception_reply ();
525
- }
526
- }
527
-
528
- // Create DSI request object.
529
- R2CORBA::ServerRequest *dsi_request = 0;
530
- ACE_NEW (dsi_request,
531
- R2CORBA::ServerRequest (request));
532
-
533
- try
534
- {
535
- // Delegate to user.
536
- this->invoke_fix (dsi_request);
537
-
538
- // Only if the client is waiting.
539
- if (request.response_expected () && !request.sync_with_server ())
540
- {
541
- dsi_request->dsi_marshal ();
542
- }
543
- }
544
- catch (::CORBA::Exception& ex)
545
- {
546
- // Only if the client is waiting.
547
- if (request.response_expected () && !request.sync_with_server ())
548
- {
549
- if (request.collocated ()
550
- && request.operation_details ()->cac () != 0)
551
- {
552
- // If we have a cac it will handle the exception and no
553
- // need to do any further processing
554
- request.operation_details ()->cac ()->handle_corba_exception (
555
- request, &ex);
556
- return;
557
- }
558
- else
559
- request.tao_send_reply_exception (ex);
560
- }
561
- }
562
-
563
- ::CORBA::release (dsi_request);
564
- }
565
- #endif
566
-
567
496
  // invocation helper for threadsafe calling of Ruby code
568
497
  void* DSI_Servant::thread_safe_invoke (void * arg)
569
498
  {
@@ -581,11 +510,7 @@ void* DSI_Servant::thread_safe_invoke (void * arg)
581
510
  return 0;
582
511
  }
583
512
 
584
- # if RPOA_NEED_DSI_FIX
585
- void DSI_Servant::invoke_fix (R2CORBA::ServerRequest_ptr request)
586
- # else
587
513
  void DSI_Servant::invoke (CORBA::ServerRequest_ptr request)
588
- # endif
589
514
  {
590
515
  ThreadSafeArg tca_(this, request);
591
516
 
@@ -593,12 +518,12 @@ void DSI_Servant::invoke (CORBA::ServerRequest_ptr request)
593
518
  if (rc != 0)
594
519
  {
595
520
  CORBA::SystemException* exc = reinterpret_cast<CORBA::SystemException*> (rc);
596
- ACE_Auto_Basic_Ptr<CORBA::SystemException> e_ptr(exc);
521
+ std::unique_ptr<CORBA::SystemException> e_ptr(exc);
597
522
  exc->_raise ();
598
523
  }
599
524
  }
600
525
 
601
- void DSI_Servant::inner_invoke (R2CORBA_ServerRequest_ptr request)
526
+ void DSI_Servant::inner_invoke (CORBA::ServerRequest_ptr request)
602
527
  {
603
528
  if (TAO_debug_level > 7)
604
529
  ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) - Servant::invoke(%C)\n", request->operation ()));
@@ -634,7 +559,7 @@ void DSI_Servant::inner_invoke (R2CORBA_ServerRequest_ptr request)
634
559
  f = this->_is_a (tmp);
635
560
 
636
561
  if (TAO_debug_level > 5)
637
- ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) _is_a (%s) -> %d\n", tmp, f));
562
+ ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) _is_a (%C) -> %d\n", tmp, f));
638
563
  }
639
564
  else
640
565
  {
@@ -663,7 +588,7 @@ void DSI_Servant::inner_invoke (R2CORBA_ServerRequest_ptr request)
663
588
  CORBA::String_var repo_id = this->_repository_id ();
664
589
 
665
590
  if (TAO_debug_level > 5)
666
- ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) _repository_id () -> %s\n", repo_id.in ()));
591
+ ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) _repository_id () -> %C\n", repo_id.in ()));
667
592
 
668
593
  CORBA::Any _any;
669
594
  _any <<= repo_id.in ();
@@ -700,13 +625,13 @@ void DSI_Servant::inner_invoke (R2CORBA_ServerRequest_ptr request)
700
625
  }
701
626
  }
702
627
 
703
- void DSI_Servant::invoke_DSI (R2CORBA_ServerRequest_ptr request)
628
+ void DSI_Servant::invoke_DSI (CORBA::ServerRequest_ptr request)
704
629
  {
705
630
  if (TAO_debug_level > 5)
706
631
  ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) - Servant::invoke_DSI(%C) entry\n", request->operation ()));
707
632
 
708
633
  // wrap request for Ruby; cleanup automatically
709
- ACE_Auto_Basic_Ptr<DSI_Data> dsi_data(new DSI_Data(request));
634
+ std::unique_ptr<DSI_Data> dsi_data(new DSI_Data(request));
710
635
 
711
636
  VALUE srvreq = Data_Wrap_Struct(r2tao_cServerRequest, 0, 0, dsi_data.get ());
712
637
 
@@ -752,7 +677,7 @@ void DSI_Servant::invoke_DSI (R2CORBA_ServerRequest_ptr request)
752
677
  _exc->completed (
753
678
  static_cast<CORBA::CompletionStatus> (NUM2ULONG (rb_iv_get (rexc, "@completed"))));
754
679
 
755
- ACE_Auto_Basic_Ptr<CORBA::SystemException> e_ptr(_exc);
680
+ std::unique_ptr<CORBA::SystemException> e_ptr(_exc);
756
681
  _exc->_raise ();
757
682
  }
758
683
  else
@@ -825,7 +750,7 @@ void DSI_Servant::invoke_DSI (R2CORBA_ServerRequest_ptr request)
825
750
  }
826
751
  }
827
752
 
828
- void DSI_Servant::invoke_SI (R2CORBA_ServerRequest_ptr request)
753
+ void DSI_Servant::invoke_SI (CORBA::ServerRequest_ptr request)
829
754
  {
830
755
  if (TAO_debug_level > 5)
831
756
  ACE_DEBUG ((LM_INFO, "R2TAO (%P|%t) - Servant::invoke_SI(%C) entry\n", request->operation ()));
@@ -985,7 +910,7 @@ void DSI_Servant::invoke_SI (R2CORBA_ServerRequest_ptr request)
985
910
  _exc->completed (
986
911
  static_cast<CORBA::CompletionStatus> (NUM2ULONG (rb_iv_get (rexc, "@completed"))));
987
912
 
988
- ACE_Auto_Basic_Ptr<CORBA::SystemException> e_ptr(_exc);
913
+ std::unique_ptr<CORBA::SystemException> e_ptr(_exc);
989
914
  _exc->_raise ();
990
915
  }
991
916
  else
@@ -1131,7 +1056,7 @@ CORBA::Object_ptr DSI_Servant::_get_component (void)
1131
1056
  }
1132
1057
  }
1133
1058
 
1134
- const char *DSI_Servant::_interface_repository_id (void) const
1059
+ const char *DSI_Servant::_interface_repository_id () const
1135
1060
  {
1136
1061
  static R2TAO_RBFuncall FN_repository_id ("_repository_id");
1137
1062
 
@@ -10,36 +10,19 @@
10
10
  # Copyright (c) Remedy IT Expertise BV
11
11
  #------------------------------------------------------------------*/
12
12
 
13
- #if ((TAO_MAJOR_VERSION < 2) || (TAO_MAJOR_VERSION == 2 && TAO_MINOR_VERSION == 0 && TAO_MICRO_VERSION <= 1))
14
- # define RPOA_NEED_DSI_FIX 1
15
-
16
- # include "srvreq_fix.h"
17
-
18
- # define R2CORBA_ServerRequest R2CORBA::ServerRequest
19
- # define R2CORBA_ServerRequest_ptr R2CORBA::ServerRequest_ptr
20
- #else
21
- # define R2CORBA_ServerRequest CORBA::ServerRequest
22
- # define R2CORBA_ServerRequest_ptr CORBA::ServerRequest_ptr
23
- #endif
24
-
25
13
  //-------------------------------------------------------------------
26
14
  // R2TAO Servant class
27
15
  //
28
16
  //===================================================================
29
-
30
17
  class DSI_Servant : public PortableServer::DynamicImplementation
31
18
  {
32
19
  public:
20
+ /// ctor
33
21
  DSI_Servant (VALUE rbServant);
34
- // ctor
22
+ /// dtor
35
23
  virtual ~DSI_Servant ();
36
- // dtor
37
24
 
38
25
  virtual void invoke (CORBA::ServerRequest_ptr request);
39
- //ACE_THROW_SPEC ((CORBA::SystemException));
40
- #if RPOA_NEED_DSI_FIX
41
- void invoke_fix (R2CORBA::ServerRequest_ptr request);
42
- #endif
43
26
 
44
27
  virtual CORBA::RepositoryId _primary_interface (
45
28
  const PortableServer::ObjectId &oid,
@@ -47,13 +30,13 @@ public:
47
30
 
48
31
  virtual CORBA::Boolean _is_a (const char *logical_type_id);
49
32
 
50
- virtual CORBA::Boolean _non_existent (void);
33
+ virtual CORBA::Boolean _non_existent ();
51
34
 
52
- //virtual CORBA::InterfaceDef_ptr _get_interface (void);
35
+ //virtual CORBA::InterfaceDef_ptr _get_interface ();
53
36
 
54
- virtual CORBA::Object_ptr _get_component (void);
37
+ virtual CORBA::Object_ptr _get_component ();
55
38
 
56
- virtual char * _repository_id (void);
39
+ virtual char * _repository_id ();
57
40
 
58
41
  enum METHOD {
59
42
  NONE,
@@ -73,12 +56,7 @@ public:
73
56
  void activate_servant ();
74
57
 
75
58
  protected:
76
- virtual const char *_interface_repository_id (void) const;
77
-
78
- #if RPOA_NEED_DSI_FIX
79
- /// Turns around and calls invoke.
80
- virtual void _dispatch (TAO_ServerRequest &request, void *context);
81
- #endif
59
+ virtual const char *_interface_repository_id () const;
82
60
 
83
61
  void register_with_servant ();
84
62
 
@@ -87,26 +65,26 @@ protected:
87
65
 
88
66
  METHOD method_id (const char* method);
89
67
 
90
- virtual void inner_invoke (R2CORBA_ServerRequest_ptr request);
68
+ void inner_invoke (CORBA::ServerRequest_ptr request);
91
69
 
92
- void invoke_SI (R2CORBA_ServerRequest_ptr request);
93
- void invoke_DSI (R2CORBA_ServerRequest_ptr request);
70
+ void invoke_SI (CORBA::ServerRequest_ptr request);
71
+ void invoke_DSI (CORBA::ServerRequest_ptr request);
94
72
 
95
73
  static VALUE _invoke_implementation(VALUE args);
96
74
 
97
75
  private:
76
+ /// The Ruby Servant
98
77
  VALUE rbServant_;
99
- // The Ruby Servant
100
78
 
101
79
  CORBA::String_var repo_id_;
102
80
 
103
81
  struct ThreadSafeArg
104
82
  {
105
83
  ThreadSafeArg (DSI_Servant* srv,
106
- R2CORBA_ServerRequest_ptr req)
84
+ CORBA::ServerRequest_ptr req)
107
85
  : servant_(srv), request_(req) {}
108
86
  DSI_Servant* servant_;
109
- R2CORBA_ServerRequest_ptr request_;
87
+ CORBA::ServerRequest_ptr request_;
110
88
  };
111
89
 
112
90
  static void* thread_safe_invoke (void * arg);
@@ -41,12 +41,12 @@ module R2CORBA
41
41
  prop = nil
42
42
  a1, a2, a3 = args
43
43
  if Array === a1
44
- raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size>3
44
+ raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size > 3
45
45
  argv = a1
46
46
  orb_id = (Hash === a2 ? nil : a2)
47
47
  prop = (Hash === a2 ? a2 : a3)
48
48
  elsif args.size == 1 || Hash === a2
49
- raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size>2
49
+ raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size > 2
50
50
  orb_id = a1
51
51
  prop = a2
52
52
  else
@@ -54,7 +54,7 @@ module R2CORBA
54
54
  end
55
55
  raise ArgumentError, "Invalid argument #{prop.class}; expected Hash" unless prop.nil? || Hash === prop
56
56
  unless prop.nil?()
57
- prop.inject(argv) {|a,(k,v)| a << k; a << v; a}
57
+ prop.inject(argv) {|a, (k, v)| a << k; a << v; a}
58
58
  end
59
59
  @@cached_orb = CORBA::Native::ORB.init(argv.collect {|a| a.to_s }.concat(@@_default_args), orb_id.nil?() ? nil : orb_id.to_s)
60
60
  end
@@ -98,11 +98,11 @@ module R2CORBA
98
98
  else
99
99
  @running ||= true
100
100
  raise CORBA::BAD_INV_ORDER.new('ORB has been shutdown', 0, CORBA::COMPLETED_NO) if @shutdown
101
- while (timeout.nil? or timeout>0) and !@shutdown
101
+ while (timeout.nil? or timeout > 0) and !@shutdown
102
102
  to = timeout || 0.05
103
103
  f, to = self.work_pending(to)
104
104
  timeout = to unless timeout.nil?
105
- if f and !@shutdown and (timeout.nil? or timeout>0)
105
+ if f and !@shutdown and (timeout.nil? or timeout > 0)
106
106
  to = timeout || 0.05
107
107
  to = self.perform_work(to)
108
108
  timeout = to unless timeout.nil?
@@ -210,7 +210,7 @@ module R2CORBA
210
210
  sigcmd = Signal.trap(signum, 'DEFAULT')
211
211
  Signal.trap(signum, sigcmd)
212
212
  @@sigreg[signum] = sigcmd
213
- if sigcmd.respond_to?(:call) or ['IGNORE','SIG_IGN','EXIT'].include?(sigcmd.to_s)
213
+ if sigcmd.respond_to?(:call) or ['IGNORE', 'SIG_IGN', 'EXIT'].include?(sigcmd.to_s)
214
214
  signum
215
215
  else
216
216
  nil
@@ -222,7 +222,7 @@ module R2CORBA
222
222
  def CORBA.handle_signal(signum)
223
223
  if @@sigreg.has_key?(signum)
224
224
  if @@sigreg[signum].respond_to?(:call)
225
- if @@sigreg[signum].respond_to?(:parameters) && @@sigreg[signum].parameters.size>0
225
+ if @@sigreg[signum].respond_to?(:parameters) && @@sigreg[signum].parameters.size > 0
226
226
  @@sigreg[signum].call(signum)
227
227
  else
228
228
  @@sigreg[signum].call
@@ -42,7 +42,7 @@ module R2CORBA
42
42
  when TK_DOUBLE
43
43
  read_double()
44
44
  when TK_LONGDOUBLE
45
- raise CORBA::NO_IMPLEMENT.new('LongDouble not supported',0,CORBA::COMPLETED_NO)
45
+ raise CORBA::NO_IMPLEMENT.new('LongDouble not supported', 0, CORBA::COMPLETED_NO)
46
46
  when TK_FIXED
47
47
  read_fixed()
48
48
  when TK_CHAR
@@ -98,7 +98,7 @@ module R2CORBA
98
98
  when TK_DOUBLE
99
99
  write_double(value)
100
100
  when TK_LONGDOUBLE
101
- raise CORBA::NO_IMPLEMENT.new('LongDouble not supported',0,CORBA::COMPLETED_NO)
101
+ raise CORBA::NO_IMPLEMENT.new('LongDouble not supported', 0, CORBA::COMPLETED_NO)
102
102
  when TK_FIXED
103
103
  write_fixed(value)
104
104
  when TK_CHAR