Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Working with comma separated String attribute (looking for elegant solution

ILya CycloneJun 3 2013 — edited Jun 4 2013
Hello.
In my ADF application View Object I have a comma separated String attribute like "value1,value2,value3".
In the UI I would like to represent it as a number of inputTexts. There should be add/delete buttons in this inputTexts collection.

I am able to do all the work in a backing beans, like splitting the attribute into an List<String>/array and modifying the String attribute depending on elements index in Java methods.
But I wonder if there is more ADF way? Like using Business Component capabilities or something.

For example, I found that VO can have an Array type attribute. I've added a transient Array attribute and moved splitting it in getThisArrayAttribute() method in ViewRowImpl.
But to my surprise af:iterator can't iterate through it. At least I couldn't find a way. Again I could do the splitting in the backingbean but there's no point in using Array attribute then.

Or maybe creating a VO method would do or a programmatic child VO...

What would you advise?

Thanks.
JDev 11.1.2.3
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 2 2013
Added on Jun 3 2013
2 comments
960 views