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

Class ComposeCatalogGroupDetailsTaskCmdImpl

  • java.lang.Object
    • com.ibm.commerce.catalog.facade.server.commands.ComposeCatalogGroupDetailsTaskCmdImpl
  • All Implemented Interfaces:
    ComposeCatalogGroupTaskCmd, com.ibm.websphere.command.Command, java.io.Serializable


    public class ComposeCatalogGroupDetailsTaskCmdImpl
    extends java.lang.Object
    implements ComposeCatalogGroupTaskCmd
    This class is used to get the details of a single category. This class is used for the access profile specified by the key, WC_CatalogGroupDetailsProfile. The details included in this profile are,
    • /CatalogGroup/CatalogIdentifier/CatalogID
    • /CatalogGroup/CatalogIdentifier/Identifier
    • /CatalogGroup/Description/Name
    • /CatalogGroup/Description/ThumbNail
    • /CatalogGroup/Description/FullImage
    • /CatalogGroup/Description/ShortDescription
      • This access profile also contains the display template name value pair to the CatalogGroup noun. This indicates the display template to be used for the category. The attribute name used in Show BOD for display template is 'displayTemplate'. To get these details, set the category data bean using,setCatalogGroups(), and call the execute(). The details will be in the CatalogGroupType object, which can be obtained by getCatalogGroup().
    See Also:
    Serialized Form
    • Constructor Detail

      • ComposeCatalogGroupDetailsTaskCmdImpl

        public ComposeCatalogGroupDetailsTaskCmdImpl()
        Default constructor for the class.
    • Method Detail

      • execute

        public void execute()
                     throws com.ibm.websphere.command.CommandException
        Composes the category details. This method is used to compose the details of the required category. The details include categoryId, category name, thumbnail image location,full image location, short description and the long description. The details returned are as follows
        • /CatalogGroup/CatalogIdentifier/CatalogID
        • /CatalogGroup/CatalogIdentifier/Identifier
        • /CatalogGroup/Description/Name
        • /CatalogGroup/Description/ThumbNail
        • /CatalogGroup/Description/FullImage
        • /CatalogGroup/Description/ShortDescription
          • This method also adds the display template name value pair to the CatalogGroup noun. The attribute name used in Show BOD for display template is 'displayTemplate'. This works on following algorithm: -- Lookup in DISPCGPREL by CATGROUP_ID, LANGUAGE_ID, and STORE_ID (STORE_ID should be store path enabled) -- If not found: Lookup in DISPCGPREL for CATGROUP_ID=0, by LANGUAGE_ID, and STORE_ID (STORE_ID should be store path enabled) -- If still not found: Repeat above two steps using the store default language, then the site default language. If at any step multiple records are found, use the one with the highest RANK value The method uses CatalogGroupPageRelationAccessBean.findByStoreCategoryMemberLanguageId() which works on the algorithm specified above.
        Specified by:
        execute in interface com.ibm.websphere.command.Command
        Throws:
        com.ibm.websphere.command.CommandException - when the required an exception occurs while extracting individual fields from the catalog group data bean.
      • isReadyToCallExecute

        public boolean isReadyToCallExecute()
        Specified by:
        isReadyToCallExecute in interface com.ibm.websphere.command.Command
        Returns:
        true if ready, false otherwise.
      • reset

        public void reset()
        Specified by:
        reset in interface com.ibm.websphere.command.Command
      • setCatalogGroupDataBean

        public void setCatalogGroupDataBean(CategoryDataBean catgrpDataBean)
        Parameters:
        catgrpDataBean - the category data bean to be used for compose.
      • setPagingParams

        public void setPagingParams(java.math.BigInteger begIndex,
                                    java.math.BigInteger dispNum)
        Paging is not supported for this command, the parameters passed will be ignored.
        Specified by:
        setPagingParams in interface ComposeCatalogGroupTaskCmd
        Parameters:
        begIndex - the beginning index.
        dispNum - the paging size.