com.ibm.commerce.marketing.commands.marketingspot

Interface FilterCategoryTaskCmd

  • All Superinterfaces:
    com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, MarketingSpotCommandBaseTaskCmd, java.io.Serializable, com.ibm.websphere.command.TargetableCommand
    All Known Implementing Classes:
    FilterCategoryTaskCmdImpl


    public interface FilterCategoryTaskCmd
    extends MarketingSpotCommandBaseTaskCmd
    This command loads the specified category by calling the RetrieveCategoryTaskCmd command. Then this command checks if the specified category qualifies for the defined filtering criteria or not. See the file samples/samples/dynacache/marketing/cachespec.xml for details about caching this command. Filters that can be cached (such as check if in the current catalog) are evaluated in the performExecute method. Filters that cannot be cached (such as check if in current shopping cart) are evaluated in the postFilter method. If a custom filter is added, and the evaluation can be cached, then extend the method removeCategory. If a custom filter is added, and the evaluation cannot be cached, then extend the method postFilter.
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String COPYRIGHT
      IBM copyright notice field.
      static java.lang.String defaultCommandClassName
      Default implementation class for this command.
      static java.lang.String NAME
      The name of this interface.
      • Fields inherited from interface com.ibm.websphere.command.Command

        serialVersionUID
    • Field Detail

      • COPYRIGHT

        static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
      • defaultCommandClassName

        static final java.lang.String defaultCommandClassName
        Default implementation class for this command.
    • Method Detail

      • getCategories

        java.util.ArrayList getCategories()
        This method returns an array of filtered category data objects that will be displayed in the e-Marketing Spot.
        Returns:
        An array of filtered category data objects.
      • getResultDataBeans

        EMarketingSpotDataBean[] getResultDataBeans()
        This method sets the data beans containing the results that the e-Marketing Spot displays.
        Returns:
        The data beans containing the results that the e-Marketing Spot displays.
      • setResultDataBeans

        void setResultDataBeans(EMarketingSpotDataBean[] resultDataBeans)
        This method sets the data beans containing the results that the e-Marketing Spot displays. Although this method takes an array, only one EMarketingSpotDataBean can be set. This is to allow for the appropriate command caching.
        Parameters:
        resultDataBeans - The data beans containing the results that the e-Marketing Spot displays.
      • postFilter

        boolean postFilter(MarketingSpotActivityCatalogGroupDataType category)
        This method checks the filters that need to be evaluated every time and cannot be cached when this command is cached.
        Parameters:
        category - The category to check.
        Returns:
        This method returns true if the category should be removed because one of the remove filters has matched its criteria.