SPONSORS:






User Tag List

Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Oct 2002
    Location
    Earth (I think!)
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ListAppend how does it work?...

    Given the following attached code, why doesn't the ListAppend append the window and it's data contents to the cache?

    The window object is added though, so AnyType does include window.

    I have a feeling why, but I'd like other opinions.


    opt file has default browser as none, and nothing in the use text field.


    [This message has been edited by Shane DeMorais (edited 02-07-2003).]
    Let go Luke!

  2. #2
    Super Member
    Join Date
    Jul 2001
    Location
    Earth
    Posts
    1,882
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    Can you maybe attach the script instead or use UBB code. This would help people give you an answer without spending a lot of time trying to figure out the code levels.

    ------------------
    James Soderborg
    http://www.ameliortech.com
    jamesso@ameliortech.com

  3. #3
    Member
    Join Date
    Aug 2002
    Location
    Durham, NC USA
    Posts
    60
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    I noticed at least one issue with your code, but it could be the demo: it looks like icnt is undefined by the time it's used in TC2. It now defaults to 0, which may be a problem. It seems to run, at least. A version of the code I ciphered is appended.

    As to the ListAppend, it looks like you're appending a window to a list of window. What are you expecting to see? I guess I'm not clear about "data contents"...

    It is very possible that I am just misreading the question, so I'll post the modified code in case someone else has insight.

    -TC

    --
    Tim Crone
    Broadcom

  4. #4
    Member
    Join Date
    Oct 2002
    Location
    Earth (I think!)
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    sorry, edited the org. post and attached the code.

    Indentations are diff than prior person's interpretation. Should shed some light.

    ------------------


    [This message has been edited by Shane DeMorais (edited 02-07-2003).]
    Let go Luke!

  5. #5
    Member
    Join Date
    Oct 2002
    Location
    Earth (I think!)
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    In real OO languages, the object is represented as a set of data that has a mapping to a virtual function table. When you manipulate an object, only the data (which includes class type) is required (hence polymorphism).

    So if I have several classes derived from say myType, then appending to a list of myType works because the object (data) is put into the list. When I retrieve the data from the list I can cast it to the appropriate type due to the type info contained within the object itself.

    Most class libraries rely on the polymorphic ability of the OO language in order to provide the most generic solution.

    What I'm seeing here is that a winclass is really more of a template that a object representation (class). The statement window myType myTypeObject is an instantiation of the class.

    I've attached a solution I came up with, a layer of complexity is introduced, but the results work and I can move forward.


    ------------------
    Let go Luke!

  6. #6
    Member
    Join Date
    Oct 2002
    Location
    Earth (I think!)
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    I have data in several external databases amounting to thousands of records.

    I wish to use the data when the data is needed, and kept until it is deleted.

    The database record fields are described with XML.

    There is a one-one mapping of fields to GUI controls within the AUT

    At first the initial sanity test scripts may only use a few data records, but eventually the larger scenarios may require using thousands of pieces of data.

    The footprint size of the partner.exe is important as I've seen problems with the internal handling of the data structures representing the interpreted 4Test code.

    Now, I can develop code to translate the XML file into 4Test record structures. Hook in an XML file parser and use the "new", "delete" mechanism I've coded up.

    The other alternative is to determine what data is need for the test case, find the database that houses the data, get it out and into a 4Test record structure housed in an .inc file.

    Seems a lot of work when I can just use the name of the record.


    ------------------
    Let go Luke!

  7. #7
    Senior Member
    Join Date
    Feb 2000
    Posts
    1,497
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: ListAppend how does it work?...

    I for one, don't see what the original problem was and therefor don't understand the need for the added complexity.

    If, to establish a personal comfort level as you learn a new tool, you're attempting to completely avoid using declaration files in favor of implementing a more familiar dynamic C++like process, that's certainly possible. But I think that you'll find that in most cases (certainly not all) there is a far simpler solution available using a native approach.


    John


    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 05:50 AM.

Copyright BetaSoft Inc.