com.ibm.commerce.catalog.facade.server.commands

Class FetchCatalogEntryBySearchTaskCmdImpl

  • All Implemented Interfaces:
    FetchCatalogEntryCmd, AbstractFetchNounCmd, com.ibm.websphere.command.Command, java.io.Serializable


    public class FetchCatalogEntryBySearchTaskCmdImpl
    extends AbstractFetchCatalogEntrySOICmdImpl
    This task command retrieves a list of Catalog Entries according to the search criteria specified by client in xpath expression. The returned list contains CatalogEntryDataBean objects populated with all the available data.

    The search criteria are specified as a xpath expression. To retrieve various parameters in the xpath expression, getSelectionCriteriaMapper() method, defined in parent AbstractFetchCatalogEntrySOICmdImpl class is used.

    This command searches for the specified criteria within the current catalog, retrieved from the Catalog Context.

    By default this command searches for Product, Package, Bundle and DynamicKit. It does not search for Items unless specified in the xpath expression. To enable search for items, 'wc_isSKUexcluded' parameter in xpath expression must be set to 'false'.

    The Catalog Entries retrieved from the search are checked against the entitlement contract of the current user. If the current user is not entitled to a catalog entry, it will not be included in the return list.


    Following are the xpath expressions used to invoke this command:
    '/CatalogEntry[CatalogEntryIdentifier[ExternalIdentifier[contains(@PartNumber,'$partNumber$')]]]'
  • $partNumber$ : a valid part number.

  • '/CatalogEntry[Description[contains(@Name,'$name$')]]'
  • $name$ : a valid name for a Catalog Entry. Searched in CATENTDESC.NAME column.

  • '/CatalogEntry[Description[contains(@ShortDescription,'$description$')]]'
  • $description$ : short description for the Catalog Entry. Searched in CATENTDESC.SHORTDESCRIPTION column.


  • Following is the list of parameters passed through WC extension of XPath:
    • wc_nameOp : Sets searchTermOperator for name. setSearchTermOperator (String) : A user can choose either like or equal as search operators. The value in this variable is used to store a user's choice. The value must be either LIKE (for like operator) or EQUAL (for equal operator).

    • wc_searchTermScope : The search term scope specifies the fields to be searched for name. Following is a list of possible values:
      • '1' for search on name and short description.
      • '2' for search on name only
      • '3' for search on name, short description and long description.
      • '4' for search on keyword.

    • wc_isSKUexcluded: This parameter specifies if sku has to be searched along with other catalog entries for a given search criteria. Possible values are 'true' and 'false' (case sensitive). Value 'true' indicates all the catalog entry types except sku will be searched for. Value 'false' indicates that all types of catalog entries will be searched for including sku for a given search criteria. If this parameter is not present in xpath expression, sku will not be included in search.
See Also:
Serialized Form
    • Constructor Detail

      • FetchCatalogEntryBySearchTaskCmdImpl

        public FetchCatalogEntryBySearchTaskCmdImpl()
        The default constructor for this class. This constructor just calls the superclass constructor.