You can use the following peace of code (extract from the mico name
service source code)


CORBA::PolicyList pl;
pl.length (1);
pl[0] = RootPOA->create_lifespan_policy (PortableServer::PERSISTENT);
PortableServer::POA_var ncpoa =
RootPOA->create_POA ("NamingContexts",
                      PortableServer::POAManager::_nil (),
                      pl);
PortableServer::POAManager_var rcmgr = ncpoa->the_POAManager ();
pl.length (2);
pl[1] = RootPOA->create_id_assignment_policy (PortableServer::USER_ID);
PortableServer::POA_var rcpoa =
RootPOA->create_POA ("NameService", rcmgr.in(), pl);





On Sat, 2006-08-19 at 20:24 +0330, Ali Nikzad wrote:
> Hi all,
>  
> How can I create a server that produces persistent IOR?
> in Vinoski's book there is a part with this topic:
> 14.3.2 
> 
> Direct Binding of Persistent References 
> 
> but it is not mentioned how to do it. is it available in Mico? How?
> regards,
> Ali
> 
> 
> _______________________________________________
> Mico-devel mailing list
> [email protected]
> http://www.mico.org/mailman/listinfo/mico-devel

_______________________________________________
Mico-devel mailing list
[email protected]
http://www.mico.org/mailman/listinfo/mico-devel

Reply via email to