Skip to Content
0
Former Member
Jul 12, 2007 at 09:18 AM

Adaptive WebService Model- Controller Binding

12 Views

HI,

Cannot execute a webservice from webdynpro applcn due to the error described at the bottom.

My Node Structure:

-Request1(0..n)

--ChildNode1(0..1) of Class ComplexType1

---ChildNode2(0..1) of Class ComplexType2

-


Required_Date

-


Required_Quantity

---Material

---Unit

Source Code:

Request1 input = new Request1();

wdContext.nodeRequest1().bind(input);

ComplexType1 input1 = new ComplexType1();

ComplexType2 input2 = new ComplexType2();

input2.setREQUIRED_DATE("20.06.2007");

input2.setREQUIRED_QUANTITY("5000");

input1.setChildNode2(input2);

input1.setMATERIAL("1000141000");

input1.setUNIT("ST");

wdContext.currentRequest1Element().modelObject().setChildNode1(input1);

try{

wdContext.currentRequest1Element().modelObject().execute();

wdContext.nodeResponse().invalidate();

}catch(Exception ex){

wdComponentAPI.getMessageManager().reportException(ex.toString(), false);

}

Exception:

java.rmi.RemoteException: Service call exception; nested exception is:

com.sap.engine.services.webservices.jaxrpc.exceptions.XmlMarshalException:

XML Serialization Error. Property [ChildNode2] of class [com.test.model.proxies.types.ComplexType1]

must exist and can not be null

Is there anything missing which Iam not instantiating?

Regards

MK.