4 Replies Latest reply on Aug 22, 2007 4:44 PM by Matt Drees

    Configuring Seam Filters through components.xml

    Greg Kasi Newbie

      All,
      Is it possible to configure Seam Filters through the components.xml?

      My Filter on Seam 1.2.1 :
      @Scope(ScopeType.APPLICATION)
      @Name("common.WebTrendsFilter")
      public class WebTrendsFilter extends AbstractFilter {
      public static final String FILTER_ENABLED = "FILTER_ENABLED";

      /**
      * _log - Default Logger injected from SEAM.
      */
      @Logger
      private Log _log;

      /**
      * Club configuration provider for page information.
      */
      @In(value="common.clubConfigProvider")
      private IClubConfigProvider _clubConfig;

      My issue is that when I try to configure the filter through the web.xml, the objects with the @In annotation come up Null, and are not injected by Seam. Therefore, I tried adding it to the components.xml, but have not had any luck whatsoever. Here is what I have tried placing in components.xml:


      #{common.clubConfigProvider}
      #{common.viewContentProvider}
      #{common.commonModuleConfig}


      Is there a special tag to designate a component as a filter? If so, I am assuming you can designate a url-pattern to apply the filter too? Any help would be greatly appreciated. Thanks.

      ~Greg