diff options
author | vishal <vishal@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-04-06 20:33:27 +0000 |
---|---|---|
committer | vishal <vishal@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-04-06 20:33:27 +0000 |
commit | 0fd787a3322d9e7088bcf4e121ee1303d14720a4 (patch) | |
tree | 761d61ba57633cfb30e202bd1a1111f4785d04f2 | |
parent | 5908020a29f0317e32182e3bf1b77c4eb74b197a (diff) | |
download | ATCD-0fd787a3322d9e7088bcf4e121ee1303d14720a4.tar.gz |
*** empty log message ***
-rw-r--r-- | TAO/orbsvcs/Time_Service/Time_Service_Clerk.cpp | 42 | ||||
-rw-r--r-- | TAO/orbsvcs/Time_Service/Time_Service_Server.cpp | 42 |
2 files changed, 84 insertions, 0 deletions
diff --git a/TAO/orbsvcs/Time_Service/Time_Service_Clerk.cpp b/TAO/orbsvcs/Time_Service/Time_Service_Clerk.cpp new file mode 100644 index 00000000000..debf4a123f3 --- /dev/null +++ b/TAO/orbsvcs/Time_Service/Time_Service_Clerk.cpp @@ -0,0 +1,42 @@ +// $Id$ + +#include "Clerk_i.h" + +ACE_RCSID(TimeService, Time_Service_Clerk, "$Id$") + +// This is the main driver program for the Time Service clerk. + +int +main (int argc, char *argv[]) +{ + Clerk_i clerk; + + ACE_DEBUG ((LM_DEBUG, + "[SERVER] Process/Thread Id : (%P/%t) Time Service clerk\n")); + + TAO_TRY + { + if (clerk.init (argc, argv, TAO_TRY_ENV) == -1) + return 1; + else + { + clerk.run (TAO_TRY_ENV); + TAO_CHECK_ENV; + } + } + TAO_CATCH (CORBA::SystemException, sysex) + { + ACE_UNUSED_ARG (sysex); + TAO_TRY_ENV.print_exception ("System Exception"); + return -1; + } + TAO_CATCH (CORBA::UserException, userex) + { + ACE_UNUSED_ARG (userex); + TAO_TRY_ENV.print_exception ("User Exception"); + return -1; + } + TAO_ENDTRY; + + return 0; +} diff --git a/TAO/orbsvcs/Time_Service/Time_Service_Server.cpp b/TAO/orbsvcs/Time_Service/Time_Service_Server.cpp new file mode 100644 index 00000000000..efcfe4b27d3 --- /dev/null +++ b/TAO/orbsvcs/Time_Service/Time_Service_Server.cpp @@ -0,0 +1,42 @@ +// $Id$ + +#include "Server_i.h" + +ACE_RCSID(TimeService, Time_Service_Server, "$Id$") + +// This is the main driver program for the Time Service server. + +int +main (int argc, char *argv[]) +{ + Server_i server; + + ACE_DEBUG ((LM_DEBUG, + "[SERVER] Process/Thread Id : (%P/%t) Time Service server\n")); + + TAO_TRY + { + if (server.init (argc, argv, TAO_TRY_ENV) == -1) + return 1; + else + { + server.run (TAO_TRY_ENV); + TAO_CHECK_ENV; + } + } + TAO_CATCH (CORBA::SystemException, sysex) + { + ACE_UNUSED_ARG (sysex); + TAO_TRY_ENV.print_exception ("System Exception"); + return -1; + } + TAO_CATCH (CORBA::UserException, userex) + { + ACE_UNUSED_ARG (userex); + TAO_TRY_ENV.print_exception ("User Exception"); + return -1; + } + TAO_ENDTRY; + + return 0; +} |