Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Sapphire » Custom TableLabelService
Custom TableLabelService [message #733687] Wed, 05 October 2011 12:36 Go to next message
Nepomuk Seiler is currently offline Nepomuk SeilerFriend
Messages: 88
Registered: December 2010
Member
Hi,

I have a model which basically represents a relational-database.
That means it contains of a header and data.

With the ValueSerializationService I'm able to handle this format. However I cannot display the I want to, which is not plain String. Instead I want a TableView. I found no example for the Custom-Part property.

My model derives from AbstractList.

thx,
Muki
Re: Custom TableLabelService [message #733736 is a reply to message #733687] Wed, 05 October 2011 14:39 Go to previous messageGo to next message
Konstantin Komissarchik is currently offline Konstantin KomissarchikFriend
Messages: 1077
Registered: July 2009
Senior Member
Rather than using a value property with a ValueSerializationService to turn your string into a List object, you should use a list property with a custom binding. See IContact.Connections property in the samples for an example that's likely rather similar to what you need.

- Konstantin
Re: Custom TableLabelService [message #733809 is a reply to message #733736] Wed, 05 October 2011 17:20 Go to previous messageGo to next message
Nepomuk Seiler is currently offline Nepomuk SeilerFriend
Messages: 88
Registered: December 2010
Member
Hi. Thx for the hint. I just had a short look on the XmlNamespaceResolver.
Does this class cover different List-Objects, too? I use my format as a
generic dataformat, which means the header (relations) are always different.

cheers, Muki
Re: Custom TableLabelService [message #733817 is a reply to message #733809] Wed, 05 October 2011 17:45 Go to previous message
Konstantin Komissarchik is currently offline Konstantin KomissarchikFriend
Messages: 1077
Registered: July 2009
Senior Member
I suspect you mean XmlDelimitedListBindingImpl rather than XmlNamespaceResolver. To support more complex list elements, you would override DelimitedListBinding.createListEntryResource() to return your own implementation that knows how to read/write individual properties within a record. If you are clever with how you implement this resource (maybe using your own property annotation to link property to cell within a record), then you should be able to write this custom binding implementation once and re-use it for many lists.

- Konstantin
Previous Topic:Performance Improvements
Next Topic:ImpliedElementProperty vs ElementProperty
Goto Forum:
  


Current Time: Fri Apr 19 01:28:08 GMT 2024

Powered by FUDForum. Page generated in 0.01952 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top