diff options
Diffstat (limited to 'orbsvcs/tests/AVStreams/Pluggable')
-rw-r--r-- | orbsvcs/tests/AVStreams/Pluggable/Makefile.am | 90 | ||||
-rw-r--r-- | orbsvcs/tests/AVStreams/Pluggable/ftp.h | 137 | ||||
-rwxr-xr-x | orbsvcs/tests/AVStreams/Pluggable/run_test.pl | 6 | ||||
-rw-r--r-- | orbsvcs/tests/AVStreams/Pluggable/server.h | 85 |
4 files changed, 117 insertions, 201 deletions
diff --git a/orbsvcs/tests/AVStreams/Pluggable/Makefile.am b/orbsvcs/tests/AVStreams/Pluggable/Makefile.am deleted file mode 100644 index d6a771ebaaf..00000000000 --- a/orbsvcs/tests/AVStreams/Pluggable/Makefile.am +++ /dev/null @@ -1,90 +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_ROOT = $(top_srcdir) - -noinst_PROGRAMS = - -## Makefile.AVS_Pluggable_Ftp.am - -if BUILD_EXCEPTIONS -if !BUILD_ACE_FOR_TAO - -noinst_PROGRAMS += ftp - -ftp_CPPFLAGS = \ - -I$(ACE_ROOT) \ - -I$(ACE_BUILDDIR) \ - -I$(TAO_ROOT) \ - -I$(TAO_BUILDDIR) \ - -I$(TAO_ROOT)/orbsvcs \ - -I$(TAO_BUILDDIR)/orbsvcs - -ftp_SOURCES = \ - ftp.cpp \ - ftp.h - -ftp_LDADD = \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_AV.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty_Serv.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty_Skel.la \ - $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \ - $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \ - $(TAO_BUILDDIR)/tao/libTAO.la \ - $(ACE_BUILDDIR)/ace/libACE.la - -endif !BUILD_ACE_FOR_TAO -endif BUILD_EXCEPTIONS - -## Makefile.AVS_Pluggable_Server.am - -if BUILD_EXCEPTIONS -if !BUILD_ACE_FOR_TAO - -noinst_PROGRAMS += server - -server_CPPFLAGS = \ - -I$(ACE_ROOT) \ - -I$(ACE_BUILDDIR) \ - -I$(TAO_ROOT) \ - -I$(TAO_BUILDDIR) \ - -I$(TAO_ROOT)/orbsvcs \ - -I$(TAO_BUILDDIR)/orbsvcs - -server_SOURCES = \ - server.cpp \ - server.h - -server_LDADD = \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_AV.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty_Serv.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty_Skel.la \ - $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosProperty.la \ - $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \ - $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \ - $(TAO_BUILDDIR)/tao/libTAO.la \ - $(ACE_BUILDDIR)/ace/libACE.la - -endif !BUILD_ACE_FOR_TAO -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/orbsvcs/tests/AVStreams/Pluggable/ftp.h b/orbsvcs/tests/AVStreams/Pluggable/ftp.h index 50ae2bb556c..b658ce53e2f 100644 --- a/orbsvcs/tests/AVStreams/Pluggable/ftp.h +++ b/orbsvcs/tests/AVStreams/Pluggable/ftp.h @@ -1,21 +1,18 @@ /* -*- C++ -*- */ -// $Id$ - -// ============================================================================ -// -// = LIBRARY -// TAO/orbsvcs/tests/AVStreams/Pluggable -// -// = FILENAME -// ftp.h -// -// = DESCRIPTION -// Ftp client to send data -// -// = AUTHOR -// Yamuna Krishnamurthy <yamuna@cs.wustl.edu> -// -// ============================================================================ + +//============================================================================= +/** + * @file ftp.h + * + * $Id$ + * + * Ftp client to send data + * + * + * @author Yamuna Krishnamurthy <yamuna@cs.wustl.edu> + */ +//============================================================================= + #ifndef TAO_AV_FTP_H @@ -29,140 +26,146 @@ #include "orbsvcs/AV/Protocol_Factory.h" +/** + * @class FTP_Client_Callback + * + * @brief Defines the client applcation callback. + * + * This class can override the methods of + * the TAO_AV_Callback to do application + * specific processing. + */ class FTP_Client_Callback : public TAO_AV_Callback { - // = TITLE - // Defines the client applcation callback. - // - // = DESCRIPTION - // This class can override the methods of - // the TAO_AV_Callback to do application - // specific processing. public: + ///Constructor FTP_Client_Callback (void); - //Constructor }; +/** + * @class FTP_Client_StreamEndPoint + * + * @brief Defines the client stream endpoint. + * + * This class overrides the methods of TAO_ClientStreamendpoint + * so the application can perform its processing during post and pre + * connection set up. + */ class FTP_Client_StreamEndPoint : public TAO_Client_StreamEndPoint { - // = TITLE - // Defines the client stream endpoint. - // - // = DESCRIPTION - // This class overrides the methods of TAO_ClientStreamendpoint - // so the application can perform its processing during post and pre - // connection set up. public: + ///Contructor FTP_Client_StreamEndPoint (void); - //Contructor + /// Create the application client callback and return its handle to the + /// AVSTreams for further application callbacks virtual int get_callback (const char *flowname, TAO_AV_Callback *&callback); - // Create the application client callback and return its handle to the - // AVSTreams for further application callbacks + /// Set protocol object corresponding to the transport protocol chosen. virtual int set_protocol_object (const char *flowname, TAO_AV_Protocol_Object *object); - // Set protocol object corresponding to the transport protocol chosen. protected: + /// reference to the cllient application callback. FTP_Client_Callback callback_; - // reference to the cllient application callback. }; typedef TAO_AV_Endpoint_Reactive_Strategy_A <FTP_Client_StreamEndPoint,TAO_VDev,AV_Null_MediaCtrl> ENDPOINT_STRATEGY; +/** + * @class Client + * + * @brief Defines the Client Application + * + * The actual client program that acts as the ftp client that streams data + * to the ftp servers that are waiting for data. + */ class Client { - // = TITLE - // Defines the Client Application - // - // = DESCRIPTION - // The actual client program that acts as the ftp client that streams data - // to the ftp servers that are waiting for data. public: + /// Constructor Client (void); - // Constructor + /// Method to initialize the various data components. int init (int argc, ACE_TCHAR *argv[]); - // Method to initialize the various data components. + /// Set the protocol object corresponding to the transport protocol chosen. void set_protocol_object (TAO_AV_Protocol_Object *protocol_object); - // Set the protocol object corresponding to the transport protocol chosen. + /// Method to pace and send data from a file. int pace_data (void); - // Method to pace and send data from a file. + /// File handle from which data is read to be sent. FILE *file (void); - // File handle from which data is read to be sent. + /// The stream control interface that manages the stream set up TAO_StreamCtrl* streamctrl (void); - // The stream control interface that manages the stream set up + /// name of the flow set up. char *flowname (void); - // name of the flow set up. + /// The requested frame rate for sending each frame of data read from the file. int frame_rate (void); - // The requested frame rate for sending each frame of data read from the file. private: + /// Method to parse the command line arguments. int parse_args (int argc, ACE_TCHAR *argv[]); - // Method to parse the command line arguments. + /// Method that binds the ftp client to the server int bind_to_server (void); - // Method that binds the ftp client to the server + /// The reacfive strategy of the client. ENDPOINT_STRATEGY endpoint_strategy_; - // The reacfive strategy of the client. + /// The server MMDevice that the ftpo client connects to AVStreams::MMDevice_var server_mmdevice_; - // The server MMDevice that the ftpo client connects to + /// The ftp client MMDevice. TAO_MMDevice client_mmdevice_; - // The ftp client MMDevice. + /// Video stream controller TAO_StreamCtrl streamctrl_; - // Video stream controller + /// Number of frames sent. int count_; - // Number of frames sent. int argc_; ACE_TCHAR **argv_; + /// File from which data is read. const char *filename_; - // File from which data is read. + /// Address of the ftp client host machine or a multicast address - Default is + /// UDP multicast addess const char *address_; - // Address of the ftp client host machine or a multicast address - Default is - // UDP multicast addess const char *peer_addr_str_; + /// The Naming Service client. TAO_Naming_Client my_naming_client_; - // The Naming Service client. + /// File handle of the file read from. FILE *fp_; - // File handle of the file read from. + /// Selected protocol - default is UDP char *protocol_; - // Selected protocol - default is UDP char *flowname_; + /// If set to 1 then use sfp as the flow carrier protocol. int use_sfp_; - // If set to 1 then use sfp as the flow carrier protocol. int frame_rate_; + /// Message block into which data is read from a file and then sent. ACE_Message_Block mb; - // Message block into which data is read from a file and then sent. + /// Protocol object corresponding to the transport protocol selected. TAO_AV_Protocol_Object* protocol_object_; - // Protocol object corresponding to the transport protocol selected. }; diff --git a/orbsvcs/tests/AVStreams/Pluggable/run_test.pl b/orbsvcs/tests/AVStreams/Pluggable/run_test.pl index 1591969296e..4f128a1530f 100755 --- a/orbsvcs/tests/AVStreams/Pluggable/run_test.pl +++ b/orbsvcs/tests/AVStreams/Pluggable/run_test.pl @@ -65,7 +65,7 @@ for ($i = 0; $i <= $#ARGV; $i++) { } } -$NS = $ns->CreateProcess ("$ENV{TAO_ROOT}/orbsvcs/Naming_Service/Naming_Service", +$NS = $ns->CreateProcess ("$ENV{TAO_ROOT}/orbsvcs/Naming_Service/tao_cosnaming", " -o $ns_nsiorfile"); print STDERR "Starting Naming Service\n"; @@ -112,12 +112,12 @@ for $protocol (@protocols) { my $sv_outputfile = $sv->LocalFile ($outputfile); $ns->DeleteFile ($outputfile); - $SV = $sv->CreateProcess ("server", + $SV = $sv->CreateProcess ("server", "-ORBInitRef NameService=file://$sv_nsiorfile ". "-ORBDebugLevel $debug ". "-f $sv_outputfile"); - $CL = $cl->CreateProcess ("ftp", + $CL = $cl->CreateProcess ("ftp", "-ORBInitRef NameService=file://$cl_nsiorfile ". "-ORBDebugLevel $debug ". "-p $protocol ". diff --git a/orbsvcs/tests/AVStreams/Pluggable/server.h b/orbsvcs/tests/AVStreams/Pluggable/server.h index bdb3544c767..7982865da72 100644 --- a/orbsvcs/tests/AVStreams/Pluggable/server.h +++ b/orbsvcs/tests/AVStreams/Pluggable/server.h @@ -1,20 +1,17 @@ /* -*- C++ -*- */ -// $Id$ -// ============================================================================ -// -// = LIBRARY -// TAO/orbsvcs/tests/AVStreams/Pluggable -// -// = FILENAME -// ftp.h -// -// = DESCRIPTION -// Ftp server to receive data -// -// = AUTHOR -// Yamuna Krishnamurthy <yamuna@cs.wustl.edu> -// -// ============================================================================ +//============================================================================= +/** + * @file server.h + * + * $Id$ + * + * Ftp server to receive data + * + * + * @author Yamuna Krishnamurthy <yamuna@cs.wustl.edu> + */ +//============================================================================= + #include "orbsvcs/Naming/Naming_Client.h" #include "orbsvcs/AV/AVStreams_i.h" @@ -22,14 +19,16 @@ #include "orbsvcs/AV/Policy.h" +/** + * @class FTP_Server_Callback + * + * @brief Defines a class for the server application callback. + * + * This class overides the methods of the TAO_AV_Callback so the + * AVStreams can make upcalls to the application. + */ class FTP_Server_Callback : public TAO_AV_Callback { - // = TITLE - // Defines a class for the server application callback. - // - // = DESCRIPTION - // This class overides the methods of the TAO_AV_Callback so the - // AVStreams can make upcalls to the application. public: @@ -43,51 +42,55 @@ public: int handle_destroy (void); }; +/** + * @class FTP_Server_StreamEndPoint + * + * @brief Defines the aplication stream endpoint + * + * This is the class that overrides the tao_server_enpodint to handle + * pre and post connect processing. + */ class FTP_Server_StreamEndPoint : public TAO_Server_StreamEndPoint { - // = TITLE - // Defines the aplication stream endpoint - // - // = DESCRIPTION - // This is the class that overrides the tao_server_enpodint to handle - // pre and post connect processing. public: // Create the server application callback. int get_callback (const char *flowname, TAO_AV_Callback *&callback); private: + /// reference to the server application callback. FTP_Server_Callback callback_; - // reference to the server application callback. }; +/** + * @class Server + * + * @brief Defines the server application class. + * = DESCRIPOTION + * The actual server progarm that acts as the ftp server that receives data + * sent by the ftp client. + */ class Server { - // = TITLE - // Defines the server application class. - // - // = DESCRIPOTION - // The actual server progarm that acts as the ftp server that receives data - // sent by the ftp client. public: + /// Constructor Server (void); - // Constructor + /// Deestructor. ~Server (void); - // Deestructor. + /// Initialize data components. int init (int argc, ACE_TCHAR *argv[]); - // Initialize data components. protected: + /// The Naming Service Client. TAO_Naming_Client my_naming_client_; - // The Naming Service Client. + /// The endpoint reacxtive strategy. TAO_AV_Endpoint_Reactive_Strategy_B <FTP_Server_StreamEndPoint,TAO_VDev,AV_Null_MediaCtrl> reactive_strategy_; - // The endpoint reacxtive strategy. + /// The server MMDevice. TAO_MMDevice *mmdevice_; - // The server MMDevice. }; |