Accessing "Configuration Model"-classes

hi,
i've created a "Configuration Model" and added some classes to store my data during runtime of a webdynpro-application.
but how can i access these classes? the wizard created the objects as interfaces (even if i hadn't selected the option "Interface" during creation).
how can i achieve to instatiate these classes?
kr, achim
or is there another way for creating Model-classes from self-defined dictionary structures?

<i>Still not sure you are following right direction...
</i>
(first, i think it's time to tell you, how i appreciate your extraordinary help
of course i read the docs you've mentioned.
ok, let's put it all together - what i've done so far, what i know and what i want to do:
i'm receiving a table of strings from abap via rfc-model that look like
"HAUCK     ACHIM     STREET1   MYCITY    STREET2   MYCITY    "
out of these strings, i have to build objects (javabeans) that i have to deal with within my webdynpro application.
the structure of theses strings, i've defined in the localdirectory:
ZDebtor
  String[10] lastname;
  String[10] firstname;
  List ZAddress;
ZAddress
   String[10] Street;
   String[10] City;
and NOW....
i need a model for storing the javabeans where i can manipulate them (i don't care <i>how</i> it is created: via xmi-files, manually, configuration model, etc.)
after manipulating the objects, i have to build the abap-table out of strings from the model-to-be-created and put it back to abap.
at the moment, i'm cutting the strings manually in the controller context-nodes that were created with the structure-definitions. but, as i already mentioned, a model should be the better place to put the data used here.
all attempts to create a model failed, so far.
i've got no external uml-modeler and it shouldn't be necessary for these few classes.
i can live with the "manually controller context solution", but i've got that feeling that's it could be done better...
kr, achim

Similar Messages

  • Access Custom Configuration Item Class property in Data Warehouse database

    Is there a way to access properties on a custom 'Configuration Item Class' in the DW database?
    When creating a new CI class eg. 'Monitors' and extending this with a property like 'Serial' is there a way to access this in the DW database?
    I can find Displayname and AssetStatus in the ConfigItemDim table, but is there a way to get the other custom created properties?

    Ok !
    Are you read this post ? :
    http://social.technet.microsoft.com/Forums/systemcenter/en-US/8434e129-b969-451e-875c-f120d7b31d36/dw-reporting-on-custom-class?forum=systemcenterservicemanager
    Remy BOVI

  • Access Application Class from Model Class in BSP

    Hello,
    I am developing a BSP Application based on MVC. Is there any way, I can access the Application Class's Attribute from a Method in the Model Class?
    Thanksin Advance.
    Regards
    Gladson

    Hello,
    I solved it by passing the application class attribute to the model method, from the controller class.
    Regards
    Gladson

  • How to implement custom Model Class in Oracle ADF?

    I am using Oracle ADF for one of my project and i am using Query component of ADF. For given tables the query component creates view objects and maps the relations. ADF uses its own custom model class for this component and it should understand the DB tables. But for my project i have no access to database. All i can do is pass a string or object/query to the existing (custom) Java class/object, and this model class formulates query and queries the database and returns the value to my Java class. I have to display these results using ADF to the front end. Is There a way to achieve this? Can i replace/override the existing Model class of ADF. If so how?
    Thanks in advance for your help.

    Hi, there:
    Best thing to do is to start with the default login.html page, and then modify it. The login screen is fairly complex and it's easy to just miss a JS function you need to call. To get to default page, you would need to do one deploy (to simulator or whatever), and then look for login.html page in the temporary Xcode or Android project generated from the deployment. It should be under the "deploy" directory in your JDev workspace.
    You can also see all the framework JS files and CSS files that way as well.
    We have had customers implementing custom login screen so we know it can work, but they all had to start with the default login screen and then modify it.
    Thanks,
    Joe Huang

  • Flex with any ORM - Writing Model classes and action scripts redundant?

    Hi,
    I am using Hibernate with Flex. I have all my model classes
    as POJOs. Now if i have to access these POJOs directly from flex, I
    need to write action script reference classes for all my POJO model
    classes. Since mapping POJOs with action script reference classes
    is so mechanical, i am wondering if there is any tool to read all
    the properties from the POJO's and convert them to action script
    reference classes automatically. Is there any way that this can be
    automated?
    Thanks in advance.
    Chandu.

    If you use Granite Data Services, there's something called
    "gas3" (I think is the name). You may be able to use it even if you
    don't use Granite.
    I didn't care for learning how to use it (plus it uses
    Groovy, more needless stuff to learn I guess), so I can't say how
    well it works. I just wanted a simple custom ant task that
    generates ActionScript classes for my Java classes. So I ended up
    making my own. It's definitely not trivial but it's not that hard
    if you're very good with Java and reflection.

  • Self Reference Model Class - How to populate using Entity Framework

    Hi,i have table in SQL Server named Employees as follows:
    EmployeeId lastName FirstName reportsTo
    1 Davolio Nancy 2
    2 Fuller Andrew NULL
    3 Leverling Janet 2
    4 Peacock Margaret 2
    5 Buchanan Steven 2
    6 Suyama Michael 5
    7 King Robert 5
    8 Callahan Laura 2
    9 Dodsworth Anne 5
    I would like to use Entity Framework to populate my Model Class .My model class looks as follows:
    public class Employees
        readonly List<Employees> _children = new List<Employees>();
        public IList<Employees> Children
            get { return _children; }
        public string FirstName { get; set; }
        public string LastName {get; set;}
    I want to use this class in ViewModel  to populate my TreeView control. Can anyone help me in order to define Linq to Entities in order to populate my model class Employees from table in SQL Server as defined. Thanks in advance.
    Almir

    Hello Fred,
    unfortunately it does not work, maybe I can be more specific about what I'm trying to get. I'm following Josh Smith's article on CodeProject related to WFP TreeView
    Josh Smith article. He has Class named Person with the following structure
    public class Person
    readonly List<Person> _children = new List<Person>();
    public List<Person> Children
    get
    return _children;
    public string Name { get; set; }
    The same is populated from Database class using method named GetFamilyTree() which look as follows:
    public static Person GetFamilyTree()
    // In a real app this method would access a database.
    return new Person
    Name = "David Weatherbeam",
    Children =
    new Person
    Name="Alberto Weatherbeam",
    Children=
    new Person
    Name="Zena Hairmonger",
    Children=
    new Person
    Name="Sarah Applifunk",
    new Person
    Name="Jenny van Machoqueen",
    Children=
    new Person
    Name="Nick van Machoqueen",
    new Person
    Name="Matilda Porcupinicus",
    new Person
    Name="Bronco van Machoqueen",
    new Person
    Name="Komrade Winkleford",
    Children=
    new Person
    Name="Maurice Winkleford",
    Children=
    new Person
    Name="Divinity W. Llamafoot",
    new Person
    Name="Komrade Winkleford, Jr.",
    Children=
    new Person
    Name="Saratoga Z. Crankentoe",
    new Person
    Name="Excaliber Winkleford",
    I'm trying to figure out how should I write
    GetFamilyTree() method using Entity Framework in order to connect to my SQL Server database and populate this Person class as it was populated manually in Joshs Example. The table I'm using in SQL Server is described in
    my first post named Employees (it's self reference table)

  • Build PAS Model - Cannot get exclusive access to model

    Hi all!
    I am receiving "Cannot get exclusive access to model" when we generate Build PAS Model from CubeBuilder.
    This is the environment info:
    OS: Red Hat Enterprise Linux Version 5.4
    Product: SSM 7.5 SP09 HotFix 03 (working in SAP Netweaver CE 7.1 SP5 for MaxDB)
    DB: MaxDB 7.6
    I create CBDEFAULT model connection, ODBC DSN SSM_CB_EA and SSM_CB_EA LINKDID, as per instructions in the install and config guides.
    All except the cube builder is working fine, even though after receiving the error y verified in my SSM Administrator that the Model Connections were
    correctly defined, my cube was named "CLARO" so the connection was automatically created as CBCLARO_MM and CBCLARO_SC, we tested connection and all was ok.
    I suspect about the ODBC for linux, for that instance, I install unixODBC and configure, but the problem persist. In my test, we verified that the user root
    and smpadm (smp is my instance name) the ODBC connection works fine, however, I configure the SYSTEM DSN however I was unable to verify it.
    These are my config files:
    ***Application Server files
    Application Server installed at /app/sap/sm/lss
    The lsdal.ini was copied from a Windows machine after configure the connection.
    /app/sap/sm/lss/lsdal.ini:
    [enable]
    ConnectionID1=Oracle (OCI)
    ConnectionID2=DB2 (CLI)
    ConnectionID3=SAP NW BI RFC (using sapnwrfc.ini)
    COnnectionID4=SAP NW BI RFC (load balancing)
    ConnectionID5=SAP NW BI RFC (specific server)
    [ConnectionID]
    ConnectionID1=ssm_cb_ea
    [Settings]
    LastSource=SSM_CB_EA
    [ssm_cb_ea]
    A0=ODBC
    A1=172.24.4.123
    B1=SERVERDB
    B2=0SERVERDB=smp
    B3=DSN
    B4=0DSN=SSM_CB_EA
    B5=UID
    B6=0Userid:=SAPSMPDB
    B7=PWD
    B8=3Password:=LNBY<W?D@420
    E1=MaxDB (Unicode)
    E2=MaxDB
    T1=ODBC
    V1=9.6.0
    *** unixODBC Config files
    odbcinst -j output
    unixODBC 2.3.0
    DRIVERS............: /usr/local/etc/odbcinst.ini
    SYSTEM DATA SOURCES: /usr/local/etc/odbc.ini
    FILE DATA SOURCES..: /usr/local/etc/ODBCDataSources
    USER DATA SOURCES..: /root/.odbc.ini
    SQLULEN Size.......: 8
    SQLLEN Size........: 8
    SQLSETPOSIROW Size.: 8
    System DSN files
    /usr/local/etc/odbc.ini
    [SSM_CB_EA]
    ServerDB=SMP
    ServerNode=172.24.4.123
    Driver=/sapdb/programs/lib/libsqlod.so
    [Default]
    Driver=/sapdb/programs/lib/libsqlod.so
    /usr/local/etc/odbcinst.ini
    unixODBC 2.3.0
    DRIVERS............: /usr/local/etc/odbcinst.ini
    SYSTEM DATA SOURCES: /usr/local/etc/odbc.ini
    FILE DATA SOURCES..: /usr/local/etc/ODBCDataSources
    USER DATA SOURCES..: /root/.odbc.ini
    SQLULEN Size.......: 8
    SQLLEN Size........: 8
    SQLSETPOSIROW Size.: 8
    User DSN File (root)
    /root/.odbc.ini
    [SSM_CB_EA]
    ServerDB=SMP
    ServerNode=172.24.4.123
    Driver=/sapdb/programs/lib/libsqlod.so
    [Default]
    Driver=/sapdb/programs/lib/libsqlod.so
    User DSN file (smpadm)
    /home/smpadm/.odbc.ini
    [SSM_CB_EA]
    ServerDB=SMP
    ServerNode=172.24.4.123
    Driver=/sapdb/programs/lib/libsqlod.so
    [Default]
    Driver=/sapdb/programs/lib/libsqlod.so
    *** Test Connection result from root
    root
    Connected!
    sql-statement
    help [tablename]
    quit
    SQL>
    *** Test connection result from smpadm
    smpadm
    Connected!
    sql-statement
    help [tablename]
    quit
    SQL>
    *** /app/sap/sm/lss/workfile/cb_build_CLARO.trc
    LSS>
    LSS> set control LINKID SSM_CB_EA
    LSS>
    LSS> .... capture cube id in a control var to simplify queries on other tables
    LSS> access lslink
    LSLink>

    Hi Cliff,
    This is the output of sup sho data and sup sho log before pressing "Build PAS Model" (My cube is the named "CLARO")...
    System> sup sho log
    ADMIN: Logged In , System Process Id 20856
             Database APLIB Open READ
             Database CLARO Open READ
             Database SMREPORT Open SHARED
    CBADMIN(1): Logged In , System Process Id 21020
             Database APLIB Open READ
             Database CGLIB Open SHARED
             Database INITIAL Open READ
             Database SMREPORT Open SHARED
    System> sup sho data
    MASTERDB (/app/sap/sm/lss/MASTERDB) Maxblocks 8000 Number Free 7898
    Database: APLIB (/app/sap/sm/lss/APLIB)
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Read
       Current State: IN USE (READ)  Protection Key: None
       Last user: CBADMIN    Last access: Mon Aug 29 22:51:39 2011
       Blksize: 512   Observations 5000   Maximum Members: 10000
       Max. Size of the Database is 32 Gigabytes.
       Maxblocks: 10000  Number Free: 4651
    Database: CGLIB
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Shared
       Current State: IN USE (SHARED)  Protection Key: None
       Last user: CBADMIN    Last access: Mon Aug 29 22:51:39 2011
       Blksize: 2048   Observations 5000   Maximum Members: 10000
       Database Not Available, Cannot Display Maxblocks and Number Free
    Database: CLARO (/app/sap/sm/lss/workfile/CLARO)
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Read
       Current State: IN USE (READ)  Protection Key: None
       Last user: CBADMIN    Last access: Mon Aug 29 22:51:41 2011
       Blksize: 16384   Observations 3000   Maximum Members: 20000   Maximum Variables: 5000
       Max. Size of the Database is 32 Gigabytes.
       Maxblocks: 120000  Number Free: 119986
    Database: INITIAL (/app/sap/sm/lss/INITIAL)
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Read
       Current State: IN USE (READ)  Protection Key: None
       Last user: CBADMIN    Last access: Mon Aug 29 22:51:41 2011
       Blksize: 4096   Observations 5000   Maximum Members: 10000
       Max. Size of the Database is 32 Gigabytes.
       Maxblocks: 10000  Number Free: 9965
    Database: JUICE (/app/sap/sm/lss/JUICE.ENG)
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Read
       Current State: AVAILABLE  Protection Key: None
       Last user: GUEST    Last access: Mon Aug 29 21:58:59 2011
       Blksize: 8192   Observations 1000   Maximum Members: 10000
       Max. Size of the Database is 32 Gigabytes.
       Maxblocks: 5000  Number Free: 4472
    Database: SMREPORT (/app/sap/sm/lss/SMREPORT)
       Maxaccess: UPDATE   Disposition: ENABLED   Default Usage: Shared
       Current State: IN USE (SHARED)  Protection Key: None
       Last user: CBADMIN    Last access: Mon Aug 29 22:51:39 2011
       Blksize: 2048   Observations 5000   Maximum Members: 10000
       Max. Size of the Database is 32 Gigabytes.
       Maxblocks: 10000  Number Free: 9962
    Database: TBDB (/app/sap/sm/lss/TBDB.ENG)
       Maxaccess: READ   Disposition: ENABLED   Default Usage: Exclusive
       Current State: IN USE (READ)  Protection Key: None
       Last user:     Last access:
       Blksize: 16384   Observations 0
       Max. Size of the Database is 512 Gigabytes.
       Maxblocks: 8000  Number Free: 7666
    As I can see there is not a lock or session opened with my cube, could you please confirm me.
    Thanks and Best Regards,
    Douglas

  • DC's and Configuration Models

    I wish to define a configuration model with an associated model class within a Distributed Component (DC).  However, when I go to reuse the model in another DC, the behaviour of a configuration model is different than an Adpative RFC or web service model.
    ie. When I make an Adaptive RFC Model a public part, the associated classes beneath this are made available and everything works fine.  But when I do the same with a configuration model, the model class does not come with the model. 
    I can get the model class to appear by manually adding the .wdmodelclass file to the public parts, but that of course doesn't work as the generated java class does not come across with it.
    Has anyone exposed configuration models in DC's before and know how to get around this apparent bug?
    note - I posted this on an old post, but thought it better to raise as a new question.

    Hi Matt,
    i've seen this after my posting to the other thread you mentioned, so forget about my question there.
    Well as i understand (from my own observations, since they are not really documented yet), configuration models are something special and obviously dedicated to be "private" for a component, therefore the implementation classes are not exposed, i guess.
    Since you are also familiar with the ABAP world, as i know from previous postings, you know the possibility to configure the application behaviour for reports for example by creating Variants (i hope this is correct, it's "Varianten" in German). The configuration models seem to be the corresponding part of Web Dynpro components.
    If you list the applications of the WD-tools in the WD content admin, you see an "Editor" entry. If you start this application and select an arbitrary component, you'll see, that only the configuration models are exposed for editing (i didn't get it to work, the Editor seems not to be completely implemented so far).
    Back to your question, if it's possible to expose the Java package tree of the generated common model implementation in the "Entries" editor of your PP definition, does it work then?
    Regards
    Stefan

  • Product Modelling Environment - Variant Configuration- modelling configura

    Hello all,
    I have a very important question for which I am trying to find answers. I ahve been researching for the last 2 days continuously
    and now I kind of confused.
    I need an answer tot his at the earliest possible
    And I am struggling to differentiate between PME and product modelling in crm , is it the same?
    When Ilook in this link ,it says;
    http://help.sap.com/saphelp_crm70/helpdata/en/ed/bfb2ce6a6a46af92172c4ff901f125/frameset.htm
    NOTE
    This function in the WebClient user interface (UI) replaces the Product Modeling Environment (PME) application, which had to be installed separately.
    What does this mean?? does this mean that modelling configurable products is different from PME?
    can Product modelling be done in crm as well as ERP?
    Could u please let me know
    Thank you
    BR
    Riya

    Hi Vinod,
    Please find below a brief:-
    A product model contains the configuration model data relevant for one product which is a server based Architecture.
    -A knowledge base is a container for data and can contain many PMEs
    -PME is available in Product page
    -Need to insert and create a new product model and select the model and enter product related data.
    -Create KB's
    -Will have to define the characterstics and values and assign to class
    -Product model hierarchy shows the model in tree structure.
    -After you created the hierarchy with all details you can simulate the configuration as a result titile simulator pops up where you can see the status and Variants and your current selection.
    Regds...
    Arup

  • Accessing view object class (impl) method from bean (or vice versa)

    Halo everyone, I am using JDeveloper 11.1.2.1.0
    I have a UsersViewImpl class with a method which refresh the user table like below.
    public void resetEmployeeSearch() {
    removeApplyViewCriteriaName("viewCriteria");
    executeQuery();
    and I have a UserBean class with a method which reset the search fields values like below.
    public void resetInput(ActionEvent actionEvent) {
    ........RichInputText = input ...
    input.setValue("");
    AdfFacesContext.getCurrentInstance().addPartialTarget(searchForm);
    I would like to implement it in such a way that, once I press a button, both methods will be called.
    I have tried to call from bean method using UsersViewImpl vs = new UsersViewImpl ..... which is wrong and wont work.
    I have read about doing something like ViewObject vo = am.findViewObject("DeptView1") but I duno how to use it because I cant have a proper example.
    Any suggestion on accessing view object class (impl) method from bean (or vice versa)?
    Or is there any way to combine both method in the same class ?
    Thank you :(

    User, if you get class not found exceptions you need to tell us which classes you can't find. The JSFUtils and ADFUtils classes needing some other libraries which should already be part of your Fusion Web Application template (which your adf application should be based on). If you did not use this application template, you may have to add some libraries yourself.
    What is the diff of using the ADFUtils and OperationBinding way?
    The ADFUtils can get you access to the application module which you then use to call exposed methods on. The disadvantage of doing this is that you have to implement your own exception framework which then handles exceptions thrown by the application module. An other thing is that if you e.g. alter a VO which you use on the page this changes are not seen on the page until you refresh the page. The binding layer does not know about these changes so the iterators (which are used on the page to show the data) are not refreshed and so you don't see the changes.
    In general you should avoid using the application modul in a managed bean method and always use the binding layer (OperationBinding) to call methods. This ensures that exceptions are all handled the same way and that changes to the data model are reflected in the GUI.
    Timo

  • Error while creating model classes, operation aborted in NWDS

    Hi All,
    When i select Adaptive rfc 2 model  and then search for the RFC,  when i select RFC and click on next i get an error while importing :
    Error while creating model classes, operation aborted.
    It is working fine in visual composer and i have activated function module, RFC but getting same error. It is also working in web service navigator also.
    Can any one help me out??
    Regards,
    Pradeep kumar
    Edited by: pradeep_546 on Feb 17, 2011 9:35 PM
    Edited by: pradeep_546 on Feb 17, 2011 9:36 PM
    Edited by: pradeep_546 on Feb 17, 2011 9:37 PM

    Hai guys thanks for reply
    Tushar,
    I am using NWDS 7.2, ce7.2 server, ECC 6.0.
    Amit,
    I have tested the JCO destinations they are working fine and i created a new pair of JCO destinations but unable to import the Adaptive RFC2 Model gives same error but Adaptive webservices are working fine in my NWDS7.2
    Deepak,
    I am unable to create model in other projects also.
    I have sufficient amount of memory in my drive.
    I have imported the DC to other NWDS but it gives same error.
    Thanks for all,
    Regards,
    Pradeep Kumar G
    Edited by: pradeep_546 on Feb 18, 2011 3:05 PM

  • How to set the Model Class for a newly created Model Node ?

    Hello All,
      I am trying to map a Model node from SourceA to DestinationB.
      To do so, I created a model node for Destination B in the interface controller (set the isInputElement to true). However why I try to map the node, I get an error saying that "Both context nodes have to be bound to a model class". Upon a closer look, I realised that the model node that I created in DestinationB has no entries under the properties.
      Does anyone knows/advise how I can add the model class entry to the model node that I have created as I am not able to do so. Or otherwise, is there a way to map a model node to another model node across different components ? Thank you very much.
    from
    Kwok Wei
    from
    Kwok Wei

    Hello Pascal
      The instructioons that you gave are for mapping the model between the view controller and the component controller within the same component is that right ?
      I am tryng to map a model node in the component controller of SourceA to another model node that belongs to another Component. I do believe that in this case I will need to create a model node in the interface controller of DestinationB and map that to the component controller of SourceA. However, by creating my own model node, how do I change the property modelClass in the context ?
      Thanks !
    from
    Kwok Wei

  • I have used SAP doc mgmt for years. We copied a client and now when I configure a Class to my DMS DIR and go to CV01n Additional Data NONE of the characteristic entry boxes show up. Additional Data is blank.

    I have used SAP doc mgmt for years. We copied a client and now when I configure a Class to my DMS DIR and go to CV01n Additional Data NONE of the characteristic entry boxes show up. Additional Data is blank.
    It appears there must be some high level setting missing in the client. I have checked all authorizations and cannot find a difference between this client and all of the other clients we have. Only this one client does not show the class characteristics in the Additional Data tab.
    Any ideas of why this standard function is not working). It does not matter which DIR I config the 017 class to, nothing shows on Additional Data.

    Hi,
    The issue is resolved. We are working in a sandbox with Class configuration on a DMS issue related to standard class 017. There are no standard settings in SPRO - Cross-Application Components | Maintain Object Types and Class Types | for the object type DRAW that will allow "auto-populating" characteristic values as we do with VC class 300.
    For whatever reason DRAW and class 017 are not configured by SAP in the same manner as class 300 for example.
    We made a config entry for DRAW Class 017 VBAP. Let's just say the system did not like that.
    We are exploring other options.

  • Cannot access Graphics - bad class file

    Hey.
    When I try to compile my source I get an error saying...
    .\Man.java:146: cannot access Graphics
    bad class file: .\Graphics.java
    file does not contain class Graphics
    Please remove the files or make sure it appears in the correct subdirectory.
    It's on a different computer so that's not exactly it, but it's close enough. Compiler was working fine until the other day when i found out that all the source files were zipped up in src.zip, I had to extract Graphics.java so I could open it in emacs, and after I did that it started giving me that error message. There's nothhing wrong with my source, and I didn't move Graphics, it's still in the correct place exactly as it was, and i looked at it, all the right stuff is still inside. I'm quite confused.
    So do I have to reinstall? That would mean a massive download on my 56k and I kinda wanna carry on with my work.

    You should not need to unzip src.zip to use the Graphics class or any class that comes with j2sdk. The compiled classes are in jar files that are installed in certain directories when you install the j2sdk.
    You should only need to have a line "import java.awt.Graphics;" near the start of your source code.
    The error most likely occurred when the compiler found a Graphics.class file but inside the file is java.awt.Graphics class, not a plain Graphics class.

  • Can't fill ByteArray in EJB-Method with generated Model-Class from WD-Model

    Hello everybody,
    i try to call an ejb-method with data from an FileUpload-UI-Element in WD. The EJB-Method is receiving the byte-data to create a document in KM via a Web-Service.
    The ebj-methid has the following signature:
    public FObject putFileDataSimple (byte [] btContent, String fullFileName, String username, String password)
    After importing the Model and creating a context node i have the following structure:
    Request_X_putFileDataSimple
    +---btContent (Node)
          +-- item
    + fullFileName
    + username
    + password
    btContent is of the generated Type Byte_Item, which is itself a generated Model-Class of modelClassType ARRAY
    item is of Type byte
    But i simply have problems to fill the context node (or the binded model-object). i tried different ways and looked at thread [https://www.sdn.sap.com/irj/scn/thread?messageID=1954223] but i cant get it work.
    So my Method in WD looks like this to fill the structure and start the ejb-method:
    public boolean putKMDataSimple( com.sap.tc.webdynpro.services.sal.datatransport.api.IWDResource fin )  {
    try
      wdContext.currentRequest_X_putFileDataSimpleElement().setFullFileName("abc");
      wdContext.currentRequest_X_putFileDataSimpleElement().setUsername("def");
      wdContext.currentRequest_X_putFileDataSimpleElement().setPassword("xxx");
      byte[] buffer = new byte[1];
      InputStream in = fin.read(false);
      int i = 1;
      int j = 0;
      while (i!=-1)
         i = in.read(buffer);
         if (i!=-1)
           Byte_Item bi = new Byte_Item(mAlf);     // mAlf ist global defined Model-Class-Instance
           bi.setItem(buffer[0]);
            wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().addBtContent(bi);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    Doing this results in Error-Messages like:
    Model-Object is not a complex type for every byte added this way.
    And finally an IllegalArgumentException at java.lang.reflect.Array.set(Native Method)
    The second way i tried is:
    public boolean putKMDataSimple( com.sap.tc.webdynpro.services.sal.datatransport.api.IWDResource fin )  {
    try
      wdContext.currentRequest_X_putFileDataSimpleElement().setFullFileName("abc");
      wdContext.currentRequest_X_putFileDataSimpleElement().setUsername("def");
      wdContext.currentRequest_X_putFileDataSimpleElement().setPassword("xxx");
      byte[] buffer = new byte[1];
      ArrayList<Byte> btlist = new ArrayList<Byte>();
      InputStream in = fin.read(false);
      int i = 1;
      int j = 0;
      while (i!=-1)
         i = in.read(buffer);
         if (i!=-1)
              btList.add(buffer[0]);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().setBtContent(btList);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    Trying so results in:
    java.lang.ClassCastException: class java.lang.Byte:null incompatible with interface com.sap.tc.cmi.model.ICMIModelClass:library:com.sap.tc.cmi(at-sign)[email protected]@alive
    whenn calling the setBtContent Method
    I don't what to do now to fill the context/model-object the right way.
    Any helpfull hints are very welcome
    Edited by: Matthias Hayk on Dec 1, 2008 5:51 PM
    Edited by: Matthias Hayk on Dec 2, 2008 10:56 AM

    Ok Vesselin and thanx for your idea,
    so i adapted the source in the way you told like the following:
                     ArrayList<Byte_Item> btlist = new ArrayList<Byte_Item>();
                     byte[] buffer = new byte[1];
                     InputStream in = fin.read(false);
                     int i = 1;
                     int j = 0;
                     while (i!=-1)
                          i = in.read(buffer);
                          if (i!=-1)
                               // Byte gelesen
                               Byte_Item bi = new Byte_Item(mAlf);
                               bi.setItem(buffer[0]);
                               btlist.add(bi);
                               j++;
                     wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().setBtContent(btlist);     
                     wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    This results also in the following Exception when exceuting the WS-proxy:
    execute
    [EXCEPTION]
    java.lang.IllegalArgumentException
    at java.lang.reflect.Array.set(Native Method)
    at com.sap.tc.webdynpro.model.ejb.model.EJBGenericModelClassExecutable.getInputParameters(EJBGenericModelClassExecutable.java:215)
    at com.sap.tc.webdynpro.model.ejb.model.EJBGenericModelClassExecutable.execute(EJBGenericModelClassExecutable.java:112)

Maybe you are looking for