ICEfaces
  1. ICEfaces
  2. ICE-6517

Use JSFComponentProvider API on Netbeans 7

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.0.1
    • Component/s: Tool Integrations
    • Labels:
      None
    • Environment:
      Netbeans 7

      Description

      JSF support in Netbeans 7 includes some changes and introduces some new features, such as improved EL support in editor. etc. One of them being mentioned widely is called "Support for JSF component libraries, including bundled Primefaces library". PrimeFaces 2.1 runtime is bundled as example only available for JSF 2.0 environment . This feature allows 3rd party component library provider to easily create a netbeans module for their component library.

      In JSF configuration panel, a Components tab is added with a combo box to select one and only one component suite. This can be done by JSFComponentProvider to provide component jar files.

      We could combine core and ACE component as one ICEfaces2 component to be listed in the Component Suite combo box. But we cannot provide compat components as compat component needs further configuration (adding compatResourceServlet in web.xml).

      A bugzilla case: "Allow multiple JSF component libraries" is created.
      http://netbeans.org/bugzilla/show_bug.cgi?id=194445

        Activity

        Hide
        Liming Wu added a comment -

        there are 2 ways to add ICEfaces support to Netbeans 7.

        Onne is the traditional approach, which provide ICEfaces support as a new web framework provider.
        Second is to use JSFComponentProvider extension, which provide ICEfaces as a component library as Netbeans did for primefaces.

        Here is the summary of pros and cons of new netbeans 7 tool bundle, which uses JSFComponentProvider extension.

        Pro:
        ICEfaces is now integrated into Netbeans JSF module. This means that ICEfaces2 is listed as a component library instead of a separate framework. User is now able to select JSF framework and go to JSF configuration panel to select ICEfaces2 library from component list box. Currently primefaces and icefaces2 are in the list.

        Cons.
        1. ICEfaces2 has to be packaged as one library and we cannot provide 3 different libraries such as ICEfaces core, ACE, ICEfaces component, and ICEPush, and potentially portletBridge as this feature (component library provider) is designed for one component library. In the configuration panel a combo box is used, and in JSFFrameworkProvider, only one selected component library is allowed and added.

        2. Custom welcome page is allowed but only for 2 parts: namespace def and welcome message body. For namespace def, only one namespace uri can be added. So I cannot add both ice and ace namespace. Only ice or ace can be added. Currently I put ice and user can add ace manually on the welcome page. As for creating new pages, I provide new icefaces page wizard, which generates right page skeleton if user follows New->Other->ICEfaces->ICEfaces2 Facelets Page.

        Due to the face that head section cannot be changed, I cannot add link tag to point to rime or xp etc. This will affect all compat components which use images specified in css such as arrow in selectInputDate and a lot of other components.

        3. CompatResourceServlet cannot be defined in web.xml
        CompatResourceServlet doesn't have annotation as @WebServlet(name="Resource Servlet",urlPatterns=

        {"/xmlhttp/*"}

        for compatibility reason on servlet 2.5.

        Without this mapper servlet and this link tag mentioned above, all compat components which use images specified in css won't work properly.

        4. This plugin requires netbeans' JSF Support module as dependency but the JSF Support module is defined to "Exported only to friend packages". Of course primefaces module is in the list and we are not. This is ridiculous. They publish the component library extension and API but restrict the use of the API. This is minor as it can be worked around with minor risk.

        Show
        Liming Wu added a comment - there are 2 ways to add ICEfaces support to Netbeans 7. Onne is the traditional approach, which provide ICEfaces support as a new web framework provider. Second is to use JSFComponentProvider extension, which provide ICEfaces as a component library as Netbeans did for primefaces. Here is the summary of pros and cons of new netbeans 7 tool bundle, which uses JSFComponentProvider extension. Pro: ICEfaces is now integrated into Netbeans JSF module. This means that ICEfaces2 is listed as a component library instead of a separate framework. User is now able to select JSF framework and go to JSF configuration panel to select ICEfaces2 library from component list box. Currently primefaces and icefaces2 are in the list. Cons. 1. ICEfaces2 has to be packaged as one library and we cannot provide 3 different libraries such as ICEfaces core, ACE, ICEfaces component, and ICEPush, and potentially portletBridge as this feature (component library provider) is designed for one component library. In the configuration panel a combo box is used, and in JSFFrameworkProvider, only one selected component library is allowed and added. 2. Custom welcome page is allowed but only for 2 parts: namespace def and welcome message body. For namespace def, only one namespace uri can be added. So I cannot add both ice and ace namespace. Only ice or ace can be added. Currently I put ice and user can add ace manually on the welcome page. As for creating new pages, I provide new icefaces page wizard, which generates right page skeleton if user follows New->Other->ICEfaces->ICEfaces2 Facelets Page. Due to the face that head section cannot be changed, I cannot add link tag to point to rime or xp etc. This will affect all compat components which use images specified in css such as arrow in selectInputDate and a lot of other components. 3. CompatResourceServlet cannot be defined in web.xml CompatResourceServlet doesn't have annotation as @WebServlet(name="Resource Servlet",urlPatterns= {"/xmlhttp/*"} for compatibility reason on servlet 2.5. Without this mapper servlet and this link tag mentioned above, all compat components which use images specified in css won't work properly. 4. This plugin requires netbeans' JSF Support module as dependency but the JSF Support module is defined to "Exported only to friend packages". Of course primefaces module is in the list and we are not. This is ridiculous. They publish the component library extension and API but restrict the use of the API. This is minor as it can be worked around with minor risk.
        Hide
        Liming Wu added a comment -

        Due to limited functionalities provided, this solution is dropped temporarily.

        Email sent to oracle.

        Ted,

        Is this you need for requesting enhancement on the new feature JsfComponentProvider ?

        In Netbeans 7.0, a new JSF support feature JsfComponentProvider through path "j2ee/jsf/components" is introduced. This is a nice feature to allow custom component library plugged into Netbeans. But current implementation only allow one custom component library to be selected. This restricts us (icefaces) to adopt this feature as ICEfaces 2 provides 2 sets of component suits, ICEfaces Advanced Components and ICEfaces Components with different namespaces.

        It would be very nice if Netbeans could extend this feature to allow multiple component libraries. An enhancement bugzilla case is created (http://netbeans.org/bugzilla/show_bug.cgi?id=194445).

        It would be even nicer if Netbeans could extend this feature to allow custom configuration tab and selection listener for further custom configuration for selected component libraries. Eclipse WTP (oracle contributes) does have similar thing called LibraryProvider framework, which provides LibraryProvider configuration model, LibraryProvider configuration panel, and LibraryProvider configuration operation.

        Another issue is about friend module. JsfComponentProvider is a open API for custom component library providers. But the module of "JsfComponentProvider" class belongs "JSF Support" to is only open to friend modules listed in JSF Support module. This means custom component library providers cannot add their modules unless being listed in JSF Support module as "friend".

        Before this feature is enhanced, we have to add ICEfaces support by "WebFrameworkProvider" through path "j2ee/webtier/framework"

        Closed for now.

        Show
        Liming Wu added a comment - Due to limited functionalities provided, this solution is dropped temporarily. Email sent to oracle. Ted, Is this you need for requesting enhancement on the new feature JsfComponentProvider ? In Netbeans 7.0, a new JSF support feature JsfComponentProvider through path "j2ee/jsf/components" is introduced. This is a nice feature to allow custom component library plugged into Netbeans. But current implementation only allow one custom component library to be selected. This restricts us (icefaces) to adopt this feature as ICEfaces 2 provides 2 sets of component suits, ICEfaces Advanced Components and ICEfaces Components with different namespaces. It would be very nice if Netbeans could extend this feature to allow multiple component libraries. An enhancement bugzilla case is created ( http://netbeans.org/bugzilla/show_bug.cgi?id=194445 ). It would be even nicer if Netbeans could extend this feature to allow custom configuration tab and selection listener for further custom configuration for selected component libraries. Eclipse WTP (oracle contributes) does have similar thing called LibraryProvider framework, which provides LibraryProvider configuration model, LibraryProvider configuration panel, and LibraryProvider configuration operation. Another issue is about friend module. JsfComponentProvider is a open API for custom component library providers. But the module of "JsfComponentProvider" class belongs "JSF Support" to is only open to friend modules listed in JSF Support module. This means custom component library providers cannot add their modules unless being listed in JSF Support module as "friend". Before this feature is enhanced, we have to add ICEfaces support by "WebFrameworkProvider" through path "j2ee/webtier/framework" Closed for now.

          People

          • Assignee:
            Liming Wu
            Reporter:
            Liming Wu
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: