on 09-11-2007 11:01 AM
Hi All,
I am new to this webdynpro for java code. I have 2 bapi's. Can anyone explain me what this code does.
public void wdDoInit()
{
//@@begin wdDoInit()
//Create a new element in node
//Bapi_Flbooking_Createfromdata_Input
Bapi_Flbooking_Createfromdata_Input input =new Bapi_Flbooking_Createfromdata_Input();
wdContext.nodeBapi_Flbooking_Createfromdata_Input().bind(input);
//Create a new element in node Booking_Data
input.setBooking_Data(new Bapisbonew()); (explain this particular line also)
//Create a new element in node
//Bapi_Flight_Checkavailibility_Input
Bapi_Flight_Checkavailibility_Input inputAvailibility =
new Bapi_Flight_Checkavailibility_Input();
wdContext.nodeBapi_Flight_Checkavailibility_Input().bind(inputAvailibility);
Regards,
Subashini.J
Hi,
What is Bapisbonew() in the below line of code?
input.setBooking_Data(new Bapisbonew());
Regards,
Subashini.J
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Subashini,
If you are not having a single value as import parameter to RFC and instead you are having table then you would be having a corresponding structure and the new Bapisbonew() is the object that would be required to set for that input element.
eg. You need to pass "P1" and "P2" as a table to your input node.
Bapisbonew ele = new Bapisbonew();
ele.set<attributevalue>("P1");
ele.set<attributevalue>("P2");
And now add this element to the input node element
input.set(ele);
Regards,
Murtuza
Hi Subashini,
<b>Bapi_Flbooking_Createfromdata_Input input =new Bapi_Flbooking_Createfromdata_Input();</b>creates an intance of your input Bapi node that would be required to provide input to bapi and will return you the ouptut within the output node within this node.
<b>wdContext.nodeBapi_Flbooking_Createfromdata_Input().bind(input);</b>The new element created by you is now binded to the context Bapi_Flbooking_Createfromdata_Input node.
<b>input.setBooking_Data(new Bapisbonew());</b>
This is the input value that you are providing to your BAPI.
Regards,
Murtuza
<b></b>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.