2 Replies Latest reply on May 18, 2009 5:47 PM by Francisco Jose Peredo Noguez

    s:convertEntity equivalent without JPA Entities?

    Todd Gould Newbie


      I know this may be somewhat of an unusual question.  As always, I welcome any insights and suggestions as I am still coming up the learning curve and may be missing something obvious.

      I am wondering if there is some sort of equivalent (or similar alternative) to


      that can be used withOUT any JPA Entities?  I have one application that does not use any @Entity components (customer requirements force persistence architecture down a completely different path).  However, I would still like to make use something to convert

      into their native object format.  I presently have this working with a

      containing a

      tag and using the pickList converter attribute to do the trick.  However, this seems less elegant and a bit distracting than the


      Is there an alternative to


      that will provide similar functionality without requiring JPA Entities?  Is there a better way to approach this than what I have working with the pickList and converter?  Is there a way to use

      without using Entities?


        • 1. Re: s:convertEntity equivalent without JPA Entities?
          Todd Gould Newbie

          Does anyone have any thoughts/ideas on this topic?

          • 2. Re: s:convertEntity equivalent without JPA Entities?
            Francisco Jose Peredo Noguez Master

            Guess you could create a class like this:

            public class AnythingStore {
                 private List store;
                 public void create()
                      store = new ArrayList();
                  public Object get(int index){
                       return store.get(index);
                  public int add(Object object){
                       return store.indexOf(object);

            and use EL expressions to get the assigned index for the objects stored in AnyEntityStore and use that as the id for your objects in the UI, Since the object is of PAGE scope, the id will remain the same for an object as long as you stay in the same page (you can of course change to scope if you need it to last longer).