Skip to Content
author's profile photo Former Member
Former Member

Executing model : deep structure in importing parameter of RFC

Hi all,

I need to execute a RFC model which has a deep structure in its importing parameter. I am finding it difficult in populating the stucture.

Can some body help me in giving some input on this.

Thanks and Regards,

Rakesh Kumar

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Posted on Dec 13, 2004 at 01:00 PM

    Hallo Rakesh,

    you have to pay attention when dealing with <i>context-to-model-binding</i> in respect of <b>model object relations</b>.

    First think of a <b>model</b> as being a <i>model object graph</i> which is independent from the context. Its objects can have relations to one another.

    Then think of the <b>context</b> as being a <i>structured hierarchy</i> of nodes containing node element collections, with node elements containing inner non-singleton nodes or nodes containing a singleton child node and so on.

    <i>Context-To-Model-binding</i> at design time means, that you define bindings from model nodes in the context to model classes in the model as well as supplying relation roles in the context (nodes) based on given model class relations.

    Then a tip when dealing with models at runtime: <u>Start implementing inside the model object graph and not in the context</u>. Instantiate model objects. Fill model object collections. Add these collections to other model objects based on the given model class relations.

    Afterwards you have to set the reference between the root-level context node (element) and the root-level model object. This means you call


    . With this method call the context model node (on root level) contains a model node element referencing the corresponding model object in the model object graph. That's all. As soon as Web Dynpro needs context data from deeper levels it follows the defined supplying relation roles, traverses the model object graph starting from the root model object and updates the references between model node elements and model objects.

    I favor a <i>first-model-then-context</i> approach when programming the context-to-model-binding:

     /* First model.*/
    __Model_Input input = new __Model_Input();
    __Model_Input_Table tableInput = new __Model_Input_Table();
    /* Then context: add model node element (with reference to model object) to a context model  node. */

    In your case, populate the model object graph first with correctly associated model objects before binding the executable model object to the context node.

    Greetings, Bertram

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Bertram,

      Just one question here.

      __Model_Input input = new __Model_Input();

      __Model_Input_Table tableInput =

      new __Model_Input_Table();


      The above statement adds one element to the root model object and one element to child model object below the root one.

      Incase i have to fill the "tableInput" elements based on some condition for eg number of entries in the a Table UI then should i first get the model object of the root node and then add elements as per the code or is there any other way.



      Message was edited by: Sidharth Deshpande

  • author's profile photo Former Member
    Former Member
    Posted on Dec 13, 2004 at 03:26 PM

    Hello Bertram,

    Thanks for this input. Now it worked for me with some additional help from you.



    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.