Results 1 to 5 of 5

Thread: List of beans, JTable and binders....

  1. #1
    Join Date
    Dec 2005
    Location
    Mexico City
    Posts
    15

    Question List of beans, JTable and binders....

    Hi there.

    I'm new with RC and I'm having some problems getting examples or documentation about it.

    Rigth now I'm trying to figure out how to bind the beans that I have in a list, and then build a JTable with it.

    Until now I've just achieve to build a table model from the list using the BeanTableModel class.

    The thing here is that I don't know how to associate or configure a binder for each bean in the list, with the purpose of having a JTable that updates the bean's properties each time I edit a cell on the JTable.

    Is this possible?

    Is there any examples that show something similar?

    Thanks in advance guys.

  2. #2
    Join Date
    Aug 2005
    Location
    London (the English one!)
    Posts
    378

    Default

    No good news for "in table" data entry:
    see
    http://forum.springframework.org/showthread.php?t=20179

    Regards
    Benoit

  3. #3
    Join Date
    Aug 2005
    Location
    Austin, TX
    Posts
    425

    Default

    If you can live without direct "in table" editing, you might consider using master/detail forms to handle the data in your list. It was designed to handle exactly this problem.

    Here's a writeup in the wiki: http://opensource2.atlassian.com/con...on?pageId=2579

    The code's in the sandbox.

    HTH,
    Larry.

  4. #4
    Join Date
    Dec 2005
    Location
    Mexico City
    Posts
    15

    Default

    Well the problem has been solved, I just realized that the BeanTableModel works exactly as I wanted, I can edit the cells and automatically the properties in the beans are modified.

    So it seems that this specific problem(a problem for me of course), has been solved.

    Right now I'm checking the link that lstreepy posted it.

    Thanks guys, you have been a lot of help.

  5. #5
    Join Date
    Aug 2005
    Location
    Austin, TX
    Posts
    425

    Default

    Glad you found a workable solution. Just be aware that the BeanTableModel will allow for in place editing, but most of the other features of the RCP platform are not supported: no commit/revert handling, no validation support, no dirty tracking (so it can't participate fully in a form), etc.

    As long as you don't need any of those features, you should be good to go.

    Larry.

Posting Permissions

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