summaryrefslogtreecommitdiff
path: root/TAO/tao/Interceptor_List.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tao/Interceptor_List.cpp')
-rw-r--r--TAO/tao/Interceptor_List.cpp49
1 files changed, 49 insertions, 0 deletions
diff --git a/TAO/tao/Interceptor_List.cpp b/TAO/tao/Interceptor_List.cpp
index 62397be35b9..29aab0d326b 100644
--- a/TAO/tao/Interceptor_List.cpp
+++ b/TAO/tao/Interceptor_List.cpp
@@ -180,16 +180,65 @@ TAO_ServerRequestInterceptor_List::add_interceptor (
PortableInterceptor::ServerRequestInterceptor::_duplicate (interceptor);
}
+// -------------------------------------------------------------------
+
+TAO_IORInterceptor_List::TAO_IORInterceptor_List (void)
+ : interceptors_ ()
+{
+}
+
+TAO_IORInterceptor_List::~TAO_IORInterceptor_List (void)
+{
+ size_t len = this->interceptors_.size ();
+
+ for (size_t i = 0; i < len; ++i)
+ CORBA::release (this->interceptors_[i]);
+}
+
+size_t
+TAO_IORInterceptor_List::length (void)
+{
+ return this->interceptors_.size ();
+}
+
+void
+TAO_IORInterceptor_List::length (size_t len)
+{
+ this->interceptors_.size (len);
+}
+
+PortableInterceptor::Interceptor_ptr
+TAO_IORInterceptor_List::interceptor (size_t index)
+{
+ return this->interceptors_[index];
+}
+
+void
+TAO_IORInterceptor_List::add_interceptor (
+ PortableInterceptor::IORInterceptor_ptr interceptor,
+ CORBA::Environment &ACE_TRY_ENV)
+{
+ size_t index = this->add_interceptor_i (interceptor,
+ ACE_TRY_ENV);
+ ACE_CHECK;
+
+ // @@ Should we duplicate the reference here?
+ this->interceptors_[index] =
+ PortableInterceptor::IORInterceptor::_duplicate (interceptor);
+}
+
#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION)
template class ACE_Array_Base<PortableInterceptor::ClientRequestInterceptor_ptr>;
template class ACE_Array_Base<PortableInterceptor::ServerRequestInterceptor_ptr>;
+template class ACE_Array_Base<PortableInterceptor::IORInterceptor_ptr>;
#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA)
#pragma instantiate ACE_Array_Base<PortableInterceptor::ClientRequestInterceptor_ptr>
#pragma instantiate ACE_Array_Base<PortableInterceptor::ServerRequestInterceptor_ptr>
+#pragma instantiate ACE_Array_Base<PortableInterceptor::IORInterceptor_ptr>
#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */