com.ibm.commerce.tools.experimentation.commands

Class CreateExperimentCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, CreateExperimentCmd, com.ibm.websphere.cache.Sizeable, com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, com.ibm.websphere.command.TargetableCommand, java.io.Serializable


    public class CreateExperimentCmdImpl
    extends TaskCommandImpl
    implements CreateExperimentCmd
    This class implements the CreateExperimentCmd interface to provide the task command that creates an experiment. Different implementations of this interface can be provided for different stores.
    See Also:
    Serialized Form
    • Field Detail

      • COPYRIGHT

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

      • CreateExperimentCmdImpl

        public CreateExperimentCmdImpl()
    • Method Detail

      • getExperimentId

        public java.lang.Integer getExperimentId()
        This method returns the ID of the experiment which has been created by this command.
        Specified by:
        getExperimentId in interface CreateExperimentCmd
        Returns:
        The ID of experiment.
      • isReadyToCallExecute

        public boolean isReadyToCallExecute()
        Checks to see if the command is ready to call. This method returns false if the experiment name is null.
        Specified by:
        isReadyToCallExecute in interface com.ibm.websphere.command.Command
        Overrides:
        isReadyToCallExecute in class AbstractECTargetableCommand
        Returns:
        true if the command is ready to call.
      • performExecute

        public void performExecute()
                            throws ECException
        Performs the execution of the command.
        Specified by:
        performExecute in interface ECCommand
        Specified by:
        performExecute in interface com.ibm.websphere.command.TargetableCommand
        Overrides:
        performExecute in class AbstractECTargetableCommand
        Throws:
        ECException - Thrown when an exception occurred while this method attempted to create the experiment in the database or refresh the experiment cache registry.
        See Also:
        ECCommand#performExecute()
      • setDescription

        public void setDescription(java.lang.String description)
        This method sets the description of the experiment to be created.
        Specified by:
        setDescription in interface CreateExperimentCmd
        Parameters:
        description - The description of the experiment.
      • setEndDate

        public void setEndDate(java.sql.Timestamp endDate)
        This method sets the end date of the experiment to be created.
        Specified by:
        setEndDate in interface CreateExperimentCmd
        Parameters:
        endDate - The end date of the experiment.
      • setExpireCount

        public void setExpireCount(java.lang.Integer expireCount)
        This method sets the expire count of the experiment to be created, which is used to determine the number of customers to display the experiment to before the experiment expires.
        Specified by:
        setExpireCount in interface CreateExperimentCmd
        Parameters:
        expireCount - The expire count of the experiment.
      • setExpTypeId

        public void setExpTypeId(java.lang.Integer expTypeId)
        This method sets the ID of the experiment type to which the new experiment will be assigned.
        Specified by:
        setExpTypeId in interface CreateExperimentCmd
        Parameters:
        expTypeId - The ID of the experiment type.
      • setLastUpdate

        public void setLastUpdate(java.sql.Timestamp lastUpdate)
        This method sets the last updated date of the experiment to be created.
        Specified by:
        setLastUpdate in interface CreateExperimentCmd
        Parameters:
        lastUpdate - The last updated date of the experiment.
      • setLastUpdatedBy

        public void setLastUpdatedBy(java.lang.String lastUpdatedBy)
        This method sets the logon ID of the user who creates the experiment.
        Specified by:
        setLastUpdatedBy in interface CreateExperimentCmd
        Parameters:
        lastUpdatedBy - The logon ID of the user.
      • setName

        public void setName(java.lang.String name)
        This method sets the name of the experiment to be created.
        Specified by:
        setName in interface CreateExperimentCmd
        Parameters:
        name - The name of the experiment.
      • setPreferredElement

        public void setPreferredElement(java.lang.Short preferredElement)
        This method sets the preferred element of the experiment to be created.
        Specified by:
        setPreferredElement in interface CreateExperimentCmd
        Parameters:
        preferredElement - The preferred element of the experiment.
      • setPriority

        public void setPriority(java.lang.Short priority)
        This method sets the priority of the experiment to be created.
        Specified by:
        setPriority in interface CreateExperimentCmd
        Parameters:
        priority - The priority of the experiment.
      • setResultScope

        public void setResultScope(java.lang.String resultScope)
        This method sets the result scope of the experiment to be created.
        Specified by:
        setResultScope in interface CreateExperimentCmd
        Parameters:
        resultScope - The result scope of the experiment.
      • setRuleXml

        public void setRuleXml(java.lang.String ruleXml)
        This method sets the rule XML document of the experiment to be created.
        Specified by:
        setRuleXml in interface CreateExperimentCmd
        Parameters:
        ruleXml - The rule XML document of the experiment.
      • setStartDate

        public void setStartDate(java.sql.Timestamp startDate)
        This method sets the start date of the experiment to be created.
        Specified by:
        setStartDate in interface CreateExperimentCmd
        Parameters:
        startDate - The start date of the experiment.
      • setStatus

        public void setStatus(java.lang.String status)
        This method sets the status of the experiment to be created.
        Specified by:
        setStatus in interface CreateExperimentCmd
        Parameters:
        status - The status of the experiment.
      • setStoreId

        public void setStoreId(java.lang.Integer storeId)
        This method sets the ID of the store which the experiment to be created belongs to.
        Specified by:
        setStoreId in interface CreateExperimentCmd
        Parameters:
        storeId - The ID of the store to which the experiment belongs.