1 Reply Latest reply on Apr 6, 2006 7:11 AM by hjones

    Deferred-value expressions in custom tags

    hjones

      Hi,

      I read that the current Tomcat (5.5) only provides the JSP 2.0 spec.
      I try to write a custom tag which takes a deferred value as a parameter like
      this:

      <my:tag param="#{SessionBean1.prop}" />
      


      Since it is not possible to use the <deferred-value> tag in the TLD file, does anybody know how to do this? How does the myfaces implementation accomplish this? E.g. a JSP line like to following has to perform the same
      deferred evaluation as I would like to have in my custom tag, too:
      <ui:staticText text="#{SessionBean1.prop}" />
      


      Greetings.

        • 1. Re: Deferred-value expressions in custom tags
          hjones

          Ok, it works with the $-syntax:

          <my:tag param="${SessionBean1.prop}" />
          


          But this bean is not instantiated if it does not exist. Anybody any idea
          how to get this behaviour since withe the #-syntax, beans are created
          on the spot.

          Greetings.