// Create a policy, from the threadpool created in example 3 RTCORBA::ThreadpoolPolicy_var tpoolPolicy = rtorb->create_threadpool_policy(tpoolId); // Create a list to hold the policy CORBA::PolicyList policyList(1); policyList.length(1); policyList[0] = tpoolPolicy; // Set the policy for an already existing object reference CORBA::Object_var object = sensorRouter->create_policy_overrides(policyList, SET_OVERRIDE); sensorRouter = SensorRouter::_narrow(object);
Example 4: Attaching a threadpool to a POA.