summaryrefslogtreecommitdiff
path: root/TAO/tests/Bug_2417_Regression/subscriber_impl.cpp
diff options
context:
space:
mode:
authorWilliam R. Otte <wotte@dre.vanderbilt.edu>2006-07-24 15:50:21 +0000
committerWilliam R. Otte <wotte@dre.vanderbilt.edu>2006-07-24 15:50:21 +0000
commit3aff90f4a822fcf5d902bbfbcc9fa931d6191a8c (patch)
tree197c810e5f5bce17b1233a7cb8d7b50c0bcd25e2 /TAO/tests/Bug_2417_Regression/subscriber_impl.cpp
parent6b846cf03c0bcbd8c276cb0af61a181e5f98eaae (diff)
downloadATCD-3aff90f4a822fcf5d902bbfbcc9fa931d6191a8c.tar.gz
Repo restructuring
Diffstat (limited to 'TAO/tests/Bug_2417_Regression/subscriber_impl.cpp')
-rw-r--r--TAO/tests/Bug_2417_Regression/subscriber_impl.cpp45
1 files changed, 45 insertions, 0 deletions
diff --git a/TAO/tests/Bug_2417_Regression/subscriber_impl.cpp b/TAO/tests/Bug_2417_Regression/subscriber_impl.cpp
new file mode 100644
index 00000000000..61f25e23349
--- /dev/null
+++ b/TAO/tests/Bug_2417_Regression/subscriber_impl.cpp
@@ -0,0 +1,45 @@
+// $Id$
+
+#include "subscriber_impl.h"
+#include "ace/OS_NS_stdio.h"
+
+Subscriber_impl::Subscriber_impl(CORBA::ORB_ptr orb)
+: orb_ (CORBA::ORB::_duplicate (orb))
+, count(0)
+{
+}
+
+Subscriber_impl::~Subscriber_impl()
+{
+}
+
+void
+Subscriber_impl::onData (
+ ::CORBA::Double
+ ACE_ENV_ARG_DECL_WITH_DEFAULTS
+ )
+ ACE_THROW_SPEC ((
+ ::CORBA::SystemException
+ ))
+{
+ ++count;
+ if (count > 100)
+ shutdown();
+}
+
+::CORBA::Boolean
+Subscriber_impl::isAlive (
+ ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS
+ )
+ ACE_THROW_SPEC ((
+ ::CORBA::SystemException
+ ))
+{
+ return true;
+}
+
+void Subscriber_impl::shutdown()
+{
+ this->orb_->shutdown (0);
+}
+