summaryrefslogtreecommitdiff
path: root/TAO/tests/TransportCurrent/lib
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tests/TransportCurrent/lib')
-rw-r--r--TAO/tests/TransportCurrent/lib/Client_ORBInitializer.cpp42
-rw-r--r--TAO/tests/TransportCurrent/lib/Client_ORBInitializer.h54
-rw-r--r--TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.cpp135
-rw-r--r--TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.h128
-rw-r--r--TAO/tests/TransportCurrent/lib/Current_Test.idl38
-rw-r--r--TAO/tests/TransportCurrent/lib/Current_Test_Export.h58
-rw-r--r--TAO/tests/TransportCurrent/lib/Current_Test_Impl.h77
-rw-r--r--TAO/tests/TransportCurrent/lib/Current_Test_Lib.mpc57
-rw-r--r--TAO/tests/TransportCurrent/lib/Makefile.am106
-rw-r--r--TAO/tests/TransportCurrent/lib/Server_ORBInitializer.cpp42
-rw-r--r--TAO/tests/TransportCurrent/lib/Server_ORBInitializer.h52
-rw-r--r--TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.cpp120
-rw-r--r--TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.h109
13 files changed, 0 insertions, 1018 deletions
diff --git a/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.cpp b/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.cpp
deleted file mode 100644
index 40112cc0b5a..00000000000
--- a/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.cpp
+++ /dev/null
@@ -1,42 +0,0 @@
-// -*- C++ -*-
-
-#include "ace/Log_Msg.h"
-
-ACE_RCSID (Current_Test_Lib,
- Client_ORBInitializer,
- "$Id$")
-
-#include "Client_Request_Interceptor.h"
-#include "Client_ORBInitializer.h"
-
-namespace Test
-{
-
- Client_ORBInitializer::Client_ORBInitializer
- (PortableInterceptor::ClientRequestInterceptor_ptr interceptor)
- : interceptor_
- (PortableInterceptor::ClientRequestInterceptor::_duplicate (interceptor))
- {
- /* no-op */
- }
-
- Client_ORBInitializer::~Client_ORBInitializer (void)
- {
- /* no-op */
- }
-
- void
- Client_ORBInitializer::pre_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException)
- {
- /* no-op */
- }
-
- // A specialization to handle client-side interceptors
- void Client_ORBInitializer::post_init (PortableInterceptor::ORBInitInfo* oii)
- throw (CORBA::SystemException)
- {
- oii->add_client_request_interceptor (this->interceptor_.in ());
- }
-
-}
diff --git a/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.h b/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.h
deleted file mode 100644
index dcafa6638f4..00000000000
--- a/TAO/tests/TransportCurrent/lib/Client_ORBInitializer.h
+++ /dev/null
@@ -1,54 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file Client_ORBInitializer.h
- *
- * $Id$
- *
- * @author Iliyan jeliazkov <iliyan@ociweb.com>
- */
-//=============================================================================
-
-#ifndef CLIENT_ORBINITIALIZER_T_H
-#define CLIENT_ORBINITIALIZER_T_H
-#include /**/ "ace/pre.h"
-#include /**/ "ace/config.h"
-
-#include /**/ "Current_Test_Export.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "tao/PI/PI.h"
-#include "tao/PortableInterceptorC.h"
-
-namespace Test
-{
-
- class Current_Test_Export Client_ORBInitializer :
- public PortableInterceptor::ORBInitializer
- {
- public:
- Client_ORBInitializer (PortableInterceptor::ClientRequestInterceptor_ptr interceptor);
- ~Client_ORBInitializer (void);
-
- virtual void pre_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException);
-
- virtual void post_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException);
-
- private:
- PortableInterceptor::ClientRequestInterceptor_var interceptor_;
- };
-
-}
-
-#include /**/ "ace/post.h"
-
-#endif /* CLIENT_ORBINITIALIZER_T_H */
-
-
-
diff --git a/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.cpp b/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.cpp
deleted file mode 100644
index f62ed6e1df1..00000000000
--- a/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.cpp
+++ /dev/null
@@ -1,135 +0,0 @@
-// -*- C++ -*-
-
-#include "ace/Log_Msg.h"
-
-ACE_RCSID (ForwardRequest,
- Client_Request_Interceptor,
- "$Id$")
-
-#include "Current_TestC.h"
-#include "Client_Request_Interceptor.h"
-#include "Client_ORBInitializer.h"
-
-namespace Test
-{
-
- Client_Request_Interceptor::Client_Request_Interceptor (const char *orb_id,
- TEST test)
- : orb_id_ (CORBA::string_dup (orb_id))
- , request_count_ (0)
- , requestID_ (1)
- , test_ (test)
- {
- }
-
- CORBA::Long
- Client_Request_Interceptor::interceptions (void)
- {
- return this->request_count_;
- }
-
- char *
- Client_Request_Interceptor::name (void)
- throw (CORBA::SystemException)
- {
- return CORBA::string_dup ("Client_Request_Interceptor");
- }
-
- void
- Client_Request_Interceptor::test_transport_current (const ACE_TCHAR* amethod)
- throw (CORBA::SystemException, CORBA::UserException)
- {
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("CRI (%P|%t) Test accessing Transport Current from %s\n"),
- amethod));
-
- ++this->request_count_;
-
- int tmp = 0;
- CORBA::ORB_var orb = CORBA::ORB_init (tmp,
- 0,
- orb_id_.in ());
-
- // Call the test function, which will throw an exception on
- // failure
- (*this->test_) (orb.in ());
-
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("CRI (%P|%t) Successfully tested Transport Current from %s\n"),
- amethod));
- }
-
- void
- Client_Request_Interceptor::destroy (void)
- throw (CORBA::SystemException)
- {
- }
-
- void
- Client_Request_Interceptor::send_request (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- //Test TC
- test_transport_current ("send_request");
-
- CORBA::Boolean response_expected =
- ri->response_expected ();
-
- // Oneway?
- if (response_expected)
- ACE_DEBUG ((LM_DEBUG, ACE_TEXT("CRI (%P|%t) Sending a two-way\n")));
- else
- ACE_DEBUG ((LM_DEBUG, ACE_TEXT("CRI (%P|%t) Sending a one-way\n")));
-
- // Make the context to send the context to the target
- IOP::ServiceContext sc;
- sc.context_id = Test::Transport::CurrentTest::ContextTag;
-
- // How long can a number really get?
- char temp[32];
- {
- ACE_GUARD (TAO_SYNCH_MUTEX, monitor, this->lock_);
-
- ACE_OS::sprintf (temp, "%d", this->requestID_);
- this->requestID_++;
- }
-
- CORBA::ULong string_len = ACE_OS::strlen (temp) + 1;
- CORBA::Octet *buf = CORBA::OctetSeq::allocbuf (string_len);
- ACE_OS::strcpy (reinterpret_cast <char *> (buf), temp);
-
- sc.context_data.replace (string_len, string_len, buf, 1);
-
- // Add this context to the service context list.
- ri->add_request_service_context (sc, 0);
- }
-
- void
- Client_Request_Interceptor::send_poll (PortableInterceptor::ClientRequestInfo_ptr)
- throw (CORBA::SystemException)
- {
- test_transport_current ("send_poll");
- }
-
- void
- Client_Request_Interceptor::receive_reply (PortableInterceptor::ClientRequestInfo_ptr)
- throw (CORBA::SystemException)
- {
- test_transport_current ("receive_reply");
- }
-
- void
- Client_Request_Interceptor::receive_exception (PortableInterceptor::ClientRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("receive_exception");
- }
-
- void
- Client_Request_Interceptor::receive_other (PortableInterceptor::ClientRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("receive_other");
- }
-
-}
diff --git a/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.h b/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.h
deleted file mode 100644
index 8b9d16adcc9..00000000000
--- a/TAO/tests/TransportCurrent/lib/Client_Request_Interceptor.h
+++ /dev/null
@@ -1,128 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file Client_Request_Interceptor.h
- *
- * $Id$
- *
- * Implementation header for the client request interceptor for the
- * Transport::Current test.
- *
- * @author Ossama Othman <ossama@uci.edu>
- */
-//=============================================================================
-
-#ifndef CLIENT_REQUEST_INTERCEPTOR_H
-#define CLIENT_REQUEST_INTERCEPTOR_H
-
-#include /**/ "ace/config.h"
-#include /**/ "Current_Test_Export.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "tao/PI/PI.h"
-#include "tao/PortableInterceptorC.h"
-#include "tao/LocalObject.h"
-#include "tao/ORB.h"
-#include "tao/CORBA_String.h"
-
-namespace Test
-{
-
- /// A metod doing the actual testing, so we could change it for the
- /// different traits implementations
- typedef int (*TEST) (CORBA::ORB_ptr);
-
-
- /**
- * @class Client_Request_Interceptor
- *
- * @brief Client request interceptor that exercises
- * Transport::Current support.
- *
- * This client request interceptor forwards a request to a secondary
- * object by throwing the PortableInterceptor::ForwardRequest
- * exception from within the send_request() interception point. It
- * only forwards the initial request. See the README file for
- * details.
- */
- class Current_Test_Export Client_Request_Interceptor
- : public virtual PortableInterceptor::ClientRequestInterceptor,
- public virtual TAO_Local_RefCounted_Object
- {
- public:
-
- /// Constructor.
- Client_Request_Interceptor (const char *orb_id,
- TEST test);
- /**
- * @name Methods Required by the Client Request Interceptor
- * Interface
- *
- * These are methods that must be implemented since they are pure
- * virtual in the abstract base class. They are the canonical
- * methods required for all client request interceptors.
- */
- //@{
- /// Return the name of this ClientRequestinterceptor.
- virtual char * name (void) throw (CORBA::SystemException);
-
- virtual void destroy (void) throw (CORBA::SystemException);
-
- virtual void send_request (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
-
- virtual void send_poll (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException);
-
- virtual void receive_reply (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException);
-
-
- virtual void receive_exception (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
-
- virtual void receive_other (PortableInterceptor::ClientRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
- //@}
-
- // Number of interceptions
- CORBA::Long interceptions (void);
-
- private:
- // Implementation method, every inteception point will have to
- // call it, supplying a name.
- void test_transport_current (const ACE_TCHAR* amethod)
- throw (CORBA::SystemException, CORBA::UserException);
-
- private:
- ///The ID of the ORB this interceptor is registered with.
- CORBA::String_var orb_id_;
-
- /// Pseudo-reference to the ORB this interceptor is registered
- /// with.
- CORBA::ORB_var orb_;
-
- /// The number of requests intercepted by this interceptor.
- CORBA::ULong request_count_;
-
- /// Stringified reference to the object the initial request will be
- /// forwarded to by this interceptor.
- CORBA::String_var forward_str_;
-
- /// Synchronize internal state...
- TAO_SYNCH_MUTEX lock_;
-
- /// Unique request ID
- unsigned long requestID_;
-
- /// Test function
- TEST test_;
- };
-
-} // namespace Test
-
-#endif /* CLIENT_REQUEST_INTERCEPTOR_H */
diff --git a/TAO/tests/TransportCurrent/lib/Current_Test.idl b/TAO/tests/TransportCurrent/lib/Current_Test.idl
deleted file mode 100644
index a7f00f7d29f..00000000000
--- a/TAO/tests/TransportCurrent/lib/Current_Test.idl
+++ /dev/null
@@ -1,38 +0,0 @@
-// -*- IDL -*-
-
-//=============================================================================
-/**
- * @file Current_Test.idl
- *
- * $Id$
- *
- * Simple IDL file to test TAO::TranspotCurrent
- * support.
- *
- * @author Iliyan Jeliazkov <iliyan@ociweb.com>
- */
-//=============================================================================
-
-
-
-module Test
-{
- module Transport
- {
- interface CurrentTest
- {
-
- const unsigned long ContextTag = 0xabcdef;
-
- void invoked_by_client ();
-
- void invoked_during_upcall ();
-
- long self_test ();
-
- oneway void shutdown ();
- };
- };
-};
-
-
diff --git a/TAO/tests/TransportCurrent/lib/Current_Test_Export.h b/TAO/tests/TransportCurrent/lib/Current_Test_Export.h
deleted file mode 100644
index cfdf16fe60e..00000000000
--- a/TAO/tests/TransportCurrent/lib/Current_Test_Export.h
+++ /dev/null
@@ -1,58 +0,0 @@
-
-// -*- C++ -*-
-// $Id$
-// Definition for Win32 Export directives.
-// This file is generated automatically by generate_export_file.pl -d Current_Test
-// ------------------------------
-#ifndef CURRENT_TEST_EXPORT_H
-#define CURRENT_TEST_EXPORT_H
-
-#include "ace/config-all.h"
-
-#if defined (ACE_AS_STATIC_LIBS) && !defined (CURRENT_TEST_HAS_DLL)
-# define CURRENT_TEST_HAS_DLL 0
-#endif /* ACE_AS_STATIC_LIBS && CURRENT_TEST_HAS_DLL */
-
-#if !defined (CURRENT_TEST_HAS_DLL)
-# define CURRENT_TEST_HAS_DLL 1
-#endif /* ! CURRENT_TEST_HAS_DLL */
-
-#if defined (CURRENT_TEST_HAS_DLL) && (CURRENT_TEST_HAS_DLL == 1)
-# if defined (CURRENT_TEST_BUILD_DLL)
-# define Current_Test_Export ACE_Proper_Export_Flag
-# define CURRENT_TEST_SINGLETON_DECLARATION(T) ACE_EXPORT_SINGLETON_DECLARATION (T)
-# define CURRENT_TEST_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK) ACE_EXPORT_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
-# else /* CURRENT_TEST_BUILD_DLL */
-# define Current_Test_Export ACE_Proper_Import_Flag
-# define CURRENT_TEST_SINGLETON_DECLARATION(T) ACE_IMPORT_SINGLETON_DECLARATION (T)
-# define CURRENT_TEST_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK) ACE_IMPORT_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
-# endif /* CURRENT_TEST_BUILD_DLL */
-#else /* CURRENT_TEST_HAS_DLL == 1 */
-# define Current_Test_Export
-# define CURRENT_TEST_SINGLETON_DECLARATION(T)
-# define CURRENT_TEST_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
-#endif /* CURRENT_TEST_HAS_DLL == 1 */
-
-// Set CURRENT_TEST_NTRACE = 0 to turn on library specific tracing even if
-// tracing is turned off for ACE.
-#if !defined (CURRENT_TEST_NTRACE)
-# if (ACE_NTRACE == 1)
-# define CURRENT_TEST_NTRACE 1
-# else /* (ACE_NTRACE == 1) */
-# define CURRENT_TEST_NTRACE 0
-# endif /* (ACE_NTRACE == 1) */
-#endif /* !CURRENT_TEST_NTRACE */
-
-#if (CURRENT_TEST_NTRACE == 1)
-# define CURRENT_TEST_TRACE(X)
-#else /* (CURRENT_TEST_NTRACE == 1) */
-# if !defined (ACE_HAS_TRACE)
-# define ACE_HAS_TRACE
-# endif /* ACE_HAS_TRACE */
-# define CURRENT_TEST_TRACE(X) ACE_TRACE_IMPL(X)
-# include "ace/Trace.h"
-#endif /* (CURRENT_TEST_NTRACE == 1) */
-
-#endif /* CURRENT_TEST_EXPORT_H */
-
-// End of auto generated file.
diff --git a/TAO/tests/TransportCurrent/lib/Current_Test_Impl.h b/TAO/tests/TransportCurrent/lib/Current_Test_Impl.h
deleted file mode 100644
index f8dfc3f3ef3..00000000000
--- a/TAO/tests/TransportCurrent/lib/Current_Test_Impl.h
+++ /dev/null
@@ -1,77 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file Current_Test_Impl.h
- *
- * $Id$
- *
- * Implementation header for the "test" IDL interface for the
- * TAO::TransportCurrent test.
- *
- * @author Iliyan Jeliazkov <iliyan@ociweb.com>
- */
-//=============================================================================
-
-#ifndef CURRENT_TEST_IMPL_H
-#define CURRENT_TEST_IMPL_H
-
-#include "Current_TestS.h"
-#include "tao/TransportCurrent/TCC.h"
-
-/**
- * @class Current_Test_Impl
- *
- * @brief Simple test class.
- *
- * This class implements the "test" interface used in this test.
- */
-class Current_Test_Impl : public virtual POA_Test::Transport::CurrentTest
-{
-public:
-
- /// Constructor.
- Current_Test_Impl (CORBA::ORB_ptr orb, PortableServer::POA_ptr poa, int do_collocated_calls = 1);
-
- /// Destructor.
- ~Current_Test_Impl (void);
-
- /// Main servant test method.
- virtual void invoked_by_client (void) throw (CORBA::SystemException);
-
- /// No-op method used so that a client request interceptor will be
- /// invoked when invoking this method from the above invoke_me()
- /// method. Say that 10 times fast. :-)
- virtual void invoked_during_upcall (void)
- throw (CORBA::SystemException);
-
- /// Shutdown the ORB.
- virtual void shutdown (void) throw (CORBA::SystemException);
-
- // A self-test for coherency
- virtual ::CORBA::Long self_test (void) throw (CORBA::SystemException);
-
-public:
- /// Reports if unexpected errors have been encountered for the
- /// lifetime of the instance
- bool is_successful (void) const;
-
-private:
- void test_transport_current (void) throw (CORBA::SystemException);
-
- /// Main servant test method.
- void invoked_by_client_i (void)
- throw (CORBA::SystemException, TAO::Transport::NoContext);
-
-private:
- /// Pseudo-reference to the ORB.
- CORBA::ORB_var orb_;
-
- /// Pseudo-reference to the POA (cache)
- PortableServer::POA_var poa_;
-
- /// To do or not to do ...
- int do_collocated_calls_;
-};
-
-#endif /* CURRENT_TEST_IMPL_H */
diff --git a/TAO/tests/TransportCurrent/lib/Current_Test_Lib.mpc b/TAO/tests/TransportCurrent/lib/Current_Test_Lib.mpc
deleted file mode 100644
index 993ff326393..00000000000
--- a/TAO/tests/TransportCurrent/lib/Current_Test_Lib.mpc
+++ /dev/null
@@ -1,57 +0,0 @@
-// -*- MPC -*-
-// $Id$
-
-project(*idl): taoidldefaults {
-
- dynamicflags += CURRENT_TEST_BUILD_DLL
- idlflags += -Wb,export_include=Current_Test_Export.h \
- -Wb,export_macro=Current_Test_Export
-
- IDL_Files {
- Current_Test.idl
- }
-
- custom_only = 1
-}
-
-project(*Client): tc {
-
- after += *idl TAO_TC
- includes += .
- libout = .
- dynamicflags += CURRENT_TEST_BUILD_DLL
-
- Source_Files {
- Client_Request_Interceptor.cpp
- Client_ORBInitializer.cpp
- }
-
- Source_Files {
- Current_TestC.cpp
- }
-
- IDL_Files {
- }
-}
-
-project(*Server): tc, pi_server {
-
- after += *Client
- includes += .
- libout = .
- dynamicflags += CURRENT_TEST_BUILD_DLL
-
- Source_Files {
- Server_Request_Interceptor.cpp
- Server_ORBInitializer.cpp
- }
-
- Source_Files {
- Current_TestC.cpp
- Current_TestS.cpp
- }
-
- IDL_Files {
- }
-}
-
diff --git a/TAO/tests/TransportCurrent/lib/Makefile.am b/TAO/tests/TransportCurrent/lib/Makefile.am
deleted file mode 100644
index 8bd002e5a05..00000000000
--- a/TAO/tests/TransportCurrent/lib/Makefile.am
+++ /dev/null
@@ -1,106 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-ACE_BUILDDIR = $(top_builddir)/..
-ACE_ROOT = $(top_srcdir)/..
-TAO_BUILDDIR = $(top_builddir)
-TAO_IDL = ACE_ROOT=$(ACE_ROOT) TAO_ROOT=$(TAO_ROOT) $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDL_DEP = $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDLFLAGS = -Wb,pre_include=ace/pre.h -Wb,post_include=ace/post.h -I$(TAO_ROOT) -I$(srcdir) -g $(ACE_BUILDDIR)/apps/gperf/src/gperf
-TAO_ROOT = $(top_srcdir)
-
-noinst_LTLIBRARIES =
-
-## Makefile.Current_Test_Lib_Idl.am
-
-BUILT_SOURCES = \
- Current_TestC.cpp \
- Current_TestC.h \
- Current_TestC.inl \
- Current_TestS.cpp \
- Current_TestS.h \
- Current_TestS.inl
-
-CLEANFILES = \
- Current_Test-stamp \
- Current_TestC.cpp \
- Current_TestC.h \
- Current_TestC.inl \
- Current_TestS.cpp \
- Current_TestS.h \
- Current_TestS.inl
-
-Current_TestC.cpp Current_TestC.h Current_TestC.inl Current_TestS.cpp Current_TestS.h Current_TestS.inl: Current_Test-stamp
-
-Current_Test-stamp: $(srcdir)/Current_Test.idl $(TAO_IDL_DEP)
- $(TAO_IDL) $(TAO_IDLFLAGS) -Sa -St -Wb,export_include=Current_Test_Export.h -Wb,export_macro=Current_Test_Export $(srcdir)/Current_Test.idl
- @touch $@
-
-noinst_HEADERS = \
- Current_Test.idl
-
-## Makefile.Current_Test_Lib_Client.am
-
-if BUILD_EXCEPTIONS
-
-noinst_LTLIBRARIES += libCurrent_Test_Lib_Client.la
-
-libCurrent_Test_Lib_Client_la_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I. \
- -DCURRENT_TEST_BUILD_DLL
-
-libCurrent_Test_Lib_Client_la_SOURCES = \
- Client_ORBInitializer.cpp \
- Client_Request_Interceptor.cpp \
- Current_TestC.cpp
-
-noinst_HEADERS += \
- Client_ORBInitializer.h \
- Client_Request_Interceptor.h
-
-endif BUILD_EXCEPTIONS
-
-## Makefile.Current_Test_Lib_Server.am
-
-if BUILD_EXCEPTIONS
-
-noinst_LTLIBRARIES += libCurrent_Test_Lib_Server.la
-
-libCurrent_Test_Lib_Server_la_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I. \
- -DCURRENT_TEST_BUILD_DLL
-
-libCurrent_Test_Lib_Server_la_SOURCES = \
- Current_TestC.cpp \
- Current_TestS.cpp \
- Server_ORBInitializer.cpp \
- Server_Request_Interceptor.cpp
-
-noinst_HEADERS += \
- Server_ORBInitializer.h \
- Server_Request_Interceptor.h
-
-endif BUILD_EXCEPTIONS
-
-## Clean up template repositories, etc.
-clean-local:
- -rm -f *~ *.bak *.rpo *.sym lib*.*_pure_* core core.*
- -rm -f gcctemp.c gcctemp so_locations *.ics
- -rm -rf cxx_repository ptrepository ti_files
- -rm -rf templateregistry ir.out
- -rm -rf ptrepository SunWS_cache Templates.DB
diff --git a/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.cpp b/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.cpp
deleted file mode 100644
index 72cc1b34782..00000000000
--- a/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.cpp
+++ /dev/null
@@ -1,42 +0,0 @@
-// -*- C++ -*-
-
-#include "ace/Log_Msg.h"
-
-ACE_RCSID (Current_Test_Lib,
- Server_ORBInitializer,
- "$Id$")
-
-#include "Server_Request_Interceptor.h"
-#include "Server_ORBInitializer.h"
-
-namespace Test
-{
-
- Server_ORBInitializer::Server_ORBInitializer
- (PortableInterceptor::ServerRequestInterceptor_ptr interceptor)
- : interceptor_
- (PortableInterceptor::ServerRequestInterceptor::_duplicate (interceptor))
- {
- /* no-op */
- }
-
- Server_ORBInitializer::~Server_ORBInitializer (void)
- {
- /* no-op */
- }
-
- void
- Server_ORBInitializer::pre_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException)
- {
- /* no-op */
- }
-
- // A specialization to handle client-side interceptors
- void Server_ORBInitializer::post_init (PortableInterceptor::ORBInitInfo* oii)
- throw (CORBA::SystemException)
- {
- oii->add_server_request_interceptor (this->interceptor_.in ());
- }
-
-}
diff --git a/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.h b/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.h
deleted file mode 100644
index 6a00e61fca1..00000000000
--- a/TAO/tests/TransportCurrent/lib/Server_ORBInitializer.h
+++ /dev/null
@@ -1,52 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file Server_ORBInitializer.h
- *
- * $Id$
- *
- * @author Iliyan jeliazkov <iliyan@ociweb.com>
- */
-//=============================================================================
-
-#ifndef SERVER_ORBINITIALIZER_T_H
-#define SERVER_ORBINITIALIZER_T_H
-#include /**/ "ace/pre.h"
-#include /**/ "ace/config.h"
-
-#include /**/ "Current_Test_Export.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "tao/PI/PI.h"
-#include "tao/PortableInterceptorC.h"
-
-namespace Test
-{
-
- class Current_Test_Export Server_ORBInitializer :
- public PortableInterceptor::ORBInitializer
- {
- public:
- Server_ORBInitializer (PortableInterceptor::ServerRequestInterceptor_ptr interceptor);
- ~Server_ORBInitializer (void);
-
- virtual void pre_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException);
-
- virtual void post_init(PortableInterceptor::ORBInitInfo*)
- throw (CORBA::SystemException);
-
- private:
- PortableInterceptor::ServerRequestInterceptor_var interceptor_;
- };
-
-}
-
-#include /**/ "ace/post.h"
-
-#endif /* SERVER_ORBINITIALIZER_T_H */
-
diff --git a/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.cpp b/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.cpp
deleted file mode 100644
index 1f05e06e8ac..00000000000
--- a/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.cpp
+++ /dev/null
@@ -1,120 +0,0 @@
-// -*- C++ -*-
-
-#include "ace/Log_Msg.h"
-
-ACE_RCSID (Current_Test_Lib,
- Server_Request_Interceptor,
- "$Id$")
-
-#include "Server_Request_Interceptor.h"
-#include "Server_ORBInitializer.h"
-
-namespace Test
-{
-
- Server_Request_Interceptor::Server_Request_Interceptor (const char* orbid, TEST test)
- : request_count_ (0)
- , orb_id_ (::CORBA::string_dup (orbid))
- , test_ (test)
- {
- }
-
- Server_Request_Interceptor::~Server_Request_Interceptor (void)
- {
- }
-
- void
- Server_Request_Interceptor::test_transport_current (const ACE_TCHAR* amethod)
- throw (CORBA::SystemException)
- {
- CORBA::String_var name (this->name ());
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("%s (%P|%t) Test accessing Transport Current from %s\n"),
- name.in (),
- amethod));
-
- ++this->request_count_;
-
- if (TAO_debug_level >=1)
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("%s (%P|%t) Getting the ORB\n"),
- name.in ()));
-
- int tmpargc = 0;
- CORBA::ORB_var orb = CORBA::ORB_init (tmpargc,
- 0,
- this->orb_id_.in ());
- if (TAO_debug_level >=1)
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("%s (%P|%t) Resolving the TC\n"),
- name.in ()));
-
- CORBA::Object_var tcobject =
- orb->resolve_initial_references ("TAO::Transport::Current");
-
- // Run the test function
- (*this->test_) (orb.in ());
-
- ACE_DEBUG ((LM_DEBUG,
- ACE_TEXT ("%s (%P|%t) Success - Transport Current from %s\n"),
- name.in (),
- amethod));
- }
-
- /// queries the status of the test
- bool
- Server_Request_Interceptor::self_test (void)
- {
- return true;
- }
-
-
- char *
- Server_Request_Interceptor::name (void)
- throw (CORBA::SystemException)
- {
- return CORBA::string_dup ("SRI ");
- }
-
- void
- Server_Request_Interceptor::destroy (void)
- throw (CORBA::SystemException)
- {
- }
-
- void
- Server_Request_Interceptor::receive_request_service_contexts (PortableInterceptor::ServerRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("receive_request_service_contexts");
- }
-
- void
- Server_Request_Interceptor::receive_request (PortableInterceptor::ServerRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("receive_request");
- }
-
- void
- Server_Request_Interceptor::send_reply (PortableInterceptor::ServerRequestInfo_ptr)
- throw (CORBA::SystemException)
- {
- test_transport_current ("send_reply");
- }
-
- void
- Server_Request_Interceptor::send_exception (PortableInterceptor::ServerRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("send_exception");
- }
-
- void
- Server_Request_Interceptor::send_other (PortableInterceptor::ServerRequestInfo_ptr)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest)
- {
- test_transport_current ("send_other");
- }
-
-} /* namespace Test */
diff --git a/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.h b/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.h
deleted file mode 100644
index f489156c2ae..00000000000
--- a/TAO/tests/TransportCurrent/lib/Server_Request_Interceptor.h
+++ /dev/null
@@ -1,109 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file Server_Request_Interceptor.h
- *
- * $Id$
- *
- * Implementation header for the server request interceptor for the
- * PortableInterceptor::ForwardRequest test.
- *
- * @author Ossama Othman <ossama@uci.edu>
- */
-//=============================================================================
-
-#ifndef SERVER_REQUEST_INTERCEPTOR_H
-#define SERVER_REQUEST_INTERCEPTOR_H
-
-#include /**/ "ace/config.h"
-#include /**/ "Current_Test_Export.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "Current_TestC.h"
-
-#include "tao/TransportCurrent/TCC.h"
-#include "tao/PortableInterceptorC.h"
-#include "tao/LocalObject.h"
-#include "tao/PI_Server/PI_Server.h"
-
-namespace Test
-{
-
- /// A metod doing the actual testing, so we could change it for the
- /// different traits implementations
-
- typedef int (*TEST) (CORBA::ORB_ptr);
-
- /**
- * @class Server_Request_Interceptor
- *
- * @brief Simple concrete server request interceptor.
- *
- */
- class Current_Test_Export Server_Request_Interceptor
- : public virtual PortableInterceptor::ServerRequestInterceptor,
- public virtual TAO_Local_RefCounted_Object
- {
- public:
-
- /// Constructor.
- Server_Request_Interceptor (const char*orb_id,
- TEST test);
-
- /// Destructor.
- virtual ~Server_Request_Interceptor (void);
-
- virtual void test_transport_current (const char* amethod)
- throw (CORBA::SystemException);
-
- /// Coherency test
- virtual bool self_test (void);
-
- /**
- * @name Methods Required by the Server Request Interceptor
- * Interface
- *
- * These are methods that must be implemented since they are pure
- * virtual in the abstract base class. They are the canonical
- * methods required for all server request interceptors.
- */
- //@{
- /// Return the name of this ServerRequestinterceptor.
- virtual char * name (void) throw (CORBA::SystemException);
-
- virtual void destroy (void) throw (CORBA::SystemException);
-
- virtual void receive_request_service_contexts (PortableInterceptor::ServerRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
-
- virtual void receive_request (PortableInterceptor::ServerRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
-
- virtual void send_reply (PortableInterceptor::ServerRequestInfo_ptr ri)
- throw (CORBA::SystemException);
-
- virtual void send_exception (PortableInterceptor::ServerRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
-
- virtual void send_other (PortableInterceptor::ServerRequestInfo_ptr ri)
- throw (CORBA::SystemException, PortableInterceptor::ForwardRequest);
- //@}
-
- protected:
-
- /// The number of requests intercepted by this interceptor.
- CORBA::ULong request_count_;
-
- CORBA::String_var orb_id_;
-
- TEST test_;
-
- };
-
-}
-
-#endif /* SERVER_REQUEST_INTERCEPTOR_H */