Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JFace » Getting IValueProperty of a certain value in a MAP(ViewerSupport.bind(StructuredViewer viewer, IObservableList input, IValueProperty[] labelProperties))
Getting IValueProperty of a certain value in a MAP [message #897485] Tue, 24 July 2012 05:25
Simon Scholz is currently offline Simon Scholz
Messages: 73
Registered: April 2012
Location: Germany
Member
Hello,

I took a look at the Snippet013TableViewerEditing sample snippet.

In that snippet the ViewerSupport is used for the binding between model and the TableViewer.

ViewerSupport.bind method needs an array of IValueProperty[] to bind the items in the input list.

In the sample the IValueProperty is staticly defined by the person class, which has a name property, so BeanProperties.value(Person.class, "name") can be used.
My "Person" class contains a Map, which has a key to identify in which column the value should be shown.

Is it somehow possible to create an IValueProperty for a certain Map Entry in my own "Person" class?
Something like :
BeanProperties.value(Person.class, "nameOfTheMapInsideThePersonClass", keyOfTheMapEntry) ?

So that I can pass IValueProperty[] to the ViewerSupport.bind method, which describe the values in the Map?

Best regards,

Simon
Previous Topic:Databing with viewer input
Next Topic:ScrolledComposite in JFace
Goto Forum:
  


Current Time: Fri Aug 29 01:48:10 EDT 2014

Powered by FUDForum. Page generated in 0.01579 seconds