00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "config.h"
00019
00020 #include <fstream>
00021 #include <iostream>
00022
00023 #include "BasicTaskKernelImpl.h"
00024
00025 using namespace std;
00026
00027 int main(int argc, char *argv[])
00028 {
00029 ACE_DEBUG ((LM_DEBUG, ACE_TEXT(" quokernel-cpp started up \n")));
00030
00031
00032 CORBA::ORB_var orb = CORBA::ORB_init(argc, argv);
00033
00034
00035 CORBA::Object_var poaobj = orb->resolve_initial_references ("RootPOA");
00036 PortableServer::POA_var poa = PortableServer::POA::_narrow(poaobj.in());
00037
00038
00039 poa->the_POAManager()->activate();
00040
00041
00042 Qosket::Basic::BasicTaskKernelImpl kernel_serv (CORBA::ORB::_duplicate(orb.in()));
00043 quo::QuoKernel_ptr kernel = kernel_serv._this();
00044
00045
00046 ofstream ostr("quoKernel.ior");
00047 ostr << orb->object_to_string(kernel) << endl;
00048 ostr.close();
00049
00050
00051 ACE_DEBUG((LM_ERROR, ACE_TEXT("quokernel is ready \n") ));
00052 orb->run();
00053
00054
00055 #ifdef QUO_USE_TAO
00056 orb->shutdown();
00057 #endif
00058
00059 return 0;
00060 }