Implementing the Server in C++, using the CORBA Naming Service
Hello_var p = new Hello_impl;
CORBA_Object_var obj = orb -> resolve_initial_references("NameService");
CosNaming_NamingContext_var nc = CosNaming_NamingContext::_narrow(obj);
n[0].id = CORBA_string_dup("a");
n[0].kind = CORBA_string_dup("");
boa -> impl_is_ready(CORBA_ImplementationDef::_nil());
- Create an implementation object
- Get naming service
- “Narrow” necessary to get naming context
- Create name in root context