// ********************************************************************** // // Copyright (c) 2003 // ZeroC, Inc. // Billerica, MA, USA // // All Rights Reserved. // // Ice is free software; you can redistribute it and/or modify it under // the terms of the GNU General Public License version 2 as published by // the Free Software Foundation. // // ********************************************************************** #include #include using namespace std; using namespace Ice; class CallbackServer : public Application { public: virtual int run(int, char*[]); }; int main(int argc, char* argv[]) { CallbackServer app; return app.main(argc, argv, "config.server"); } int CallbackServer::run(int argc, char* argv[]) { ObjectAdapterPtr adapter = communicator()->createObjectAdapter("Callback.Server"); CallbackPrx self = CallbackPrx::uncheckedCast(adapter->createProxy(Ice::stringToIdentity("callback"))); adapter->add(new CallbackI(communicator()), Ice::stringToIdentity("callback")); adapter->activate(); communicator()->waitForShutdown(); return EXIT_SUCCESS; }