corbaContext = new CorbaMessageContextImpl(new GenericMessageContext());
corbaContext.put(ObjectMessageContext.MESSAGE_INPUT, true);
bindingImpl.marshal(objContext,
corbaContext,
new JAXBDataBindingCallback(objContext.getMethod(),
DataBindingCallback.Mode.MESSAGE,
null));
// Verify that everything was marshalled correctly
CorbaStreamable[] streamables = corbaContext.getMessage().getStreamableArguments();
assertTrue(streamables.length == 3);
CorbaStreamable param0 = streamables[0];
assertTrue(param0.getObject().getTypeCodeKind().value() == TCKind._tk_short);
assertTrue(param0.getMode() == ARG_IN.value);
CorbaStreamable param1 = streamables[1];
assertTrue(param1.getObject().getTypeCodeKind().value() == TCKind._tk_short);
assertTrue(param1.getMode() == ARG_OUT.value);
CorbaStreamable param2 = streamables[2];
assertTrue(param2.getObject().getTypeCodeKind().value() == TCKind._tk_short);
assertTrue(param2.getMode() == ARG_INOUT.value);
// Now try the call with a return value
objContext = new ObjectMessageContextImpl();
objContext.setMethod(paramModesClass.getMethod("testMultipleMixedParamsWithReturn", params));
objContext.setMessageObjects(paramObjs);
corbaContext = new CorbaMessageContextImpl(new GenericMessageContext());
corbaContext.put(ObjectMessageContext.MESSAGE_INPUT, true);
bindingImpl.marshal(objContext,
corbaContext,
new JAXBDataBindingCallback(objContext.getMethod(),
DataBindingCallback.Mode.MESSAGE,
null));
// Verify that everything was marshalled correctly
streamables = corbaContext.getMessage().getStreamableArguments();