1 Reply Latest reply on Nov 18, 2010 5:53 PM by Andrew Wheeler

    JSF cannot find InputContainer

    Andrew Wheeler Newbie

      I followed the docs for using an InputContainer but cannot get it to find the seam faces component:




      SEVERE [javax.enterprise.resource.webcontainer.jsf.application] JSF1068: Cannot instantiate component with component-type org.jboss.seam.faces.InputContainer


      The composite template is:


      <composite:interface componentType="org.jboss.seam.faces.InputContainer"/>
      <composite:implementation>
        <h:panelGroup layout="block" styleClass="property">
          <h:outputLabel id="label" value="#{cc.attrs.label}:" styleClass="#{cc.attrs.invalid ? ' invalid' : ''}">
          <h:outputText styleClass="required" rendered="#{cc.attrs.required}" value="*" />
          </h:outputLabel>
          <composite:insertChildren/>
          <h:message id="message" errorClass="invalid message" rendered="#{cc.attrs.invalid}" />
        </h:panelGroup>
      </composite:implementation>
      



      Usage example:


      <edit:input label="First name:" id="firstNameInput">     
        <h:inputText id="firstName" value="#{personList.firstName}" size="30"/>
      </edit:input>
      



      I am using using JBossAS6-M5 and Seam faces 3 Beta1. The component is in the seam-faces-api-3.0.0.Beta1.jar and I had a quick look in the source and all seems well.


      I haven't delved too deep, but how does the tag lib get registered? I can't see any reference to seam-faces.taglib.xml in web-fragment.xml. I thought you needed a context-param for javax.faces.FACELETS_LIBRARIES?


      Interesting comment in the seam-faces.taglib.xml org.jboss.seam.faces.InputContainer is a composite component, does not need taglib.


      I did have a problem deploying Seam3 initially because Weld extensions were being scanned when they shouldn't have been. I figured that one out see http://seamframework.org/Community/WeldExtensionsBlockUseOfSeam3 by manually excluding the extensions.