//
ByteBufferWithInfo bbwi = cdrOutputObject.getByteBufferWithInfo();
cdrOutputObject.getMessageHeader().setSize(bbwi.byteBuffer, bbwi.getSize());
CDRInputObject cdrInputObject =
new CDRInputObject(orb, null, bbwi.byteBuffer,
cdrOutputObject.getMessageHeader());
messageMediator.setInputObject(cdrInputObject);
cdrInputObject.setMessageMediator(messageMediator);
//
// Dispatch
//
// REVISIT: Impl cast.
((CorbaMessageMediatorImpl)messageMediator).handleRequestRequest(
messageMediator);
// InputStream must be closed on the InputObject so that its
// ByteBuffer can be released to the ByteBufferPool. We must do
// this before we re-assign the cdrInputObject reference below.
try { cdrInputObject.close(); }
catch (IOException ex) {
// No need to do anything since we're done with the input stream
// and cdrInputObject will be re-assigned a new client-side input
// object, (i.e. won't result in a corba error).
if (orb.transportDebugFlag) {
dprint(".marshalingComplete: ignoring IOException - " + ex.toString());
}
}
//
// Create client-side input object
//
cdrOutputObject = (CDROutputObject) messageMediator.getOutputObject();
bbwi = cdrOutputObject.getByteBufferWithInfo();
cdrOutputObject.getMessageHeader().setSize(bbwi.byteBuffer, bbwi.getSize());
cdrInputObject =
new CDRInputObject(orb, null, bbwi.byteBuffer,
cdrOutputObject.getMessageHeader());
messageMediator.setInputObject(cdrInputObject);
cdrInputObject.setMessageMediator(messageMediator);
cdrInputObject.unmarshalHeader();
InputObject inputObject = cdrInputObject;
return processResponse(orb, messageMediator, inputObject);