java.lang.Object
org.omg.PortableServer.POAHelper
- See Also:
- Top Examples, Source Code
public static POA extract(Any a)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static String id()
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static void insert(Any a,
POA that)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static POA narrow(Object obj)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
[101]Creating a new Persistent POA and a factory object in a CORBA server
By Anonymous on 2002/10/18 17:46:40 Rate
// creating a new Persistent POA and a factory object in a CORBA server ( ORBACUS ) :
//
// Get the root POA
//
org.omg.PortableServer.POA root =
org.omg.PortableServer.POAHelper.narrow (
orb.resolve_initial_references ( "RootPOA" ) ) ;
//
// Create persistent POA
//
org.omg.PortableServer.POAManager manager = root.the_POAManager ( ) ;
org.omg.CORBA.Policy [ ] policies = new org.omg.CORBA.Policy [ 2 ] ;
policies [ 0 ] = root.create_id_assignment_policy (
org.omg.PortableServer.IdAssignmentPolicyValue.USER_ID ) ;
policies [ 1 ] = root.create_lifespan_policy (
org.omg.PortableServer.LifespanPolicyValue.PERSISTENT ) ;
org.omg.PortableServer.POA poa =
root.create_POA ( "persistent", manager, policies ) ;
//
// Create factory implementation object and create a remote reference and activate it in the
// POA at the same time
//
Factory_impl factory = new Factory_impl ( orb, poa ) ;
//The factory takes a POA as argument. Associate account servants to this POA.
org.omg.CORBA.Object obj = root.servant_to_reference ( factory ) ;
public POAHelper()
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static POA read(InputStream istream)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static TypeCode type()
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static void write(OutputStream ostream,
POA value)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples