2 Replies Latest reply on Nov 26, 2007 9:28 AM by Olivier Thierry

    DataModel annotation and empty EL operator

    Olivier Thierry Apprentice

      In a Seam component, I have an array attribute with @DataModel annotation and an associated @Factory metod.

      @org.jboss.seam.annotations.datamodel.DataModel
      protected myPackage.VOProcessus[] listeProcessus;


      @javax.ejb.TransactionAttribute(javax.ejb.TransactionAttributeType.REQUIRES_NEW)
      @org.jboss.seam.annotations.Factory(value = "listeProcessus")
      @org.jboss.seam.annotations.Observer("listeProcessusUpdated")
      public void getListeProcessus() {
      ...
      }


      I want to test if this array is empty in a rendered attribute, so I wrote the following EL expression :

      rendered="#{empty listeProcessus}"


      But it looks like empty operator always returns false. I don't have this problem when I remove the @DataModel annotation.

      Is this something expected or is there something I did wrong ?