The Adf SelectManyChoice uses List<String> as its value type. Unfortunately, this stops you from directly using it or binding it to a pageDef attribute bindings.
A solution for this is by using a BackingBean and take a handle on its getter and setter while resolving or pointing the value to-and-from the actual value holder.
In my example, I will present an attribute with attributeName "CODE" and this code value will be read by the selectManyChoice as well as modified. Also, I'm showing the "CODE" attribute as inputText so that I can present how the "read" part works.
First I prepare my selectManyChoice's options by utilizing a pageFlowBean. Oh, I also use this same mBean to hold my table rows.
Here's my pageFragment which utilizes the List<Map> as my data collection. Take note of my item's scope since I only want to initialize my items once (not that it matter in a prototype hehe).
Here's my backingBean which handles the manipulation for setting the code value on selection as well as the reading piece of it. (Really think there has to be a more optimized solution though, but oh well).
Since we are setting the value and retrieving it using ValueExpression, we are able to evaluate the value at runtime.