Broker broker, MessageMediator messageMediator) { return null; }
}
// REVISIT - this is a cut and paste modification of makeROIOperation.
private Operation makeAcceptorInstantiationOperation() {
Operation clsop = OperationFactory.classAction() ;
Operation indexOp = OperationFactory.suffixAction() ;
Operation op1 = OperationFactory.compose( indexOp, clsop ) ;
Operation mop = OperationFactory.maskErrorAction( op1 ) ;
Operation mkinst = new Operation() {
public Object operate( Object value )
{
final Class initClass = (Class)value ;
if (initClass == null)
return null ;
// For security reasons avoid creating an instance
// if this class is one that would fail the class cast
// to ORBInitializer anyway.
if( Acceptor.class.isAssignableFrom( initClass ) ) {
// Now that we have a class object, instantiate one and
// remember it:
Acceptor acceptor = null ;
try {
acceptor = (Acceptor)AccessController.doPrivileged(
new PrivilegedExceptionAction() {
public Object run()
throws InstantiationException, IllegalAccessException
{
return initClass.newInstance() ;
}
}
) ;
} catch (PrivilegedActionException exc) {
// Unwrap the exception, as we don't care exc here
throw wrapper.acceptorInstantiationFailure( exc.getException(),
initClass.getName() ) ;
} catch (Exception exc) {
throw wrapper.acceptorInstantiationFailure( exc, initClass.getName() ) ;
}
return acceptor ;
} else {
throw wrapper.acceptorInstantiationTypeFailure( initClass.getName() ) ;
}
}
} ;
Operation result = OperationFactory.compose( mop, mkinst ) ;
return result ;
}