com.ibm.commerce.tools.campaigns
Class CampaignInitiativeScheduleUpdateCmdImpl

java.lang.Object
  |
  +--CacheableCommandImpl
        |
        +--com.ibm.commerce.command.AbstractECTargetableCommand
              |
              +--com.ibm.commerce.command.TaskCommandImpl
                    |
                    +--com.ibm.commerce.tools.campaigns.CampaignInitiativeScheduleUpdateCmdImpl
All Implemented Interfaces:
CampaignInitiativeScheduleUpdateCmd, ECCommand, ECTargetableCommand, TaskCommand

public class CampaignInitiativeScheduleUpdateCmdImpl
extends TaskCommandImpl
implements CampaignInitiativeScheduleUpdateCmd

This class implements the CampaignInitiativeScheduleUpdateCmd interface to provide the task command that schedules an initiative onto an e-Marketing Spot. Different implementations of this interface can be provided for different stores.

See Also:
Serialized Form

Field Summary
protected  java.lang.Integer _eMarketingSpotId
          e-Marketing Spot ID.
protected  java.sql.Timestamp _endDate
          Initiative schedule end date.
protected  java.lang.Integer _initiativeId
          Campaign initiative ID.
protected  java.lang.Integer _initiativeScheduleId
          Initiative schedule ID.
protected  java.lang.Integer _priority
          Initiative schedule priority.
protected  java.sql.Timestamp _startDate
          Initiative schedule start date.
static java.lang.String COPYRIGHT
          IBM copyright notice field.
 
Fields inherited from class com.ibm.commerce.command. AbstractECTargetableCommand
commandContext
 
Fields inherited from interface com.ibm.commerce.tools.campaigns. CampaignInitiativeScheduleUpdateCmd
defaultCommandClassName, Name
 
Fields inherited from interface com.ibm.commerce.command. ECCommand
defaultCommandClassName
 
Constructor Summary
CampaignInitiativeScheduleUpdateCmdImpl()
           
 
Method Summary
protected  void checkConflict()
          Checks to see if there is any conflict existed between the new schedule and any schedules already exist in the same time period.
 boolean isReadyToCallExecute()
          Checks to see if the command is ready to call.
 void performExecute()
          Performs the execution of the command.
 void setEMarketingSpotId(java.lang.Integer eMarketingSpotId)
          Sets the e-Marketing Spot ID of the initiative schedule.
 void setEndDate(java.sql.Timestamp endDate)
          Sets the end date of the initiative schedule.
 void setInitiativeId(java.lang.Integer initiativeId)
          Sets the initiative ID of the initiative schedule.
 void setInitiativeScheduleId(java.lang.Integer initiativeSchedule)
          Sets the ID of the initiative schedule.
 void setPriority(java.lang.Integer priority)
          Sets the priority of the initiative schedule.
 void setStartDate(java.sql.Timestamp startDate)
          Sets the start date of the initiative schedule.
 
Methods inherited from class com.ibm.commerce.command. AbstractECTargetableCommand
accessControlCheck, checkIsAllowed, checkParameters, checkResourcePermission, createCommandExecutionEvent, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getResources, getStoreId, getUser, getUserId, reset, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameters
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

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

_initiativeScheduleId

protected java.lang.Integer _initiativeScheduleId
Initiative schedule ID.

_initiativeId

protected java.lang.Integer _initiativeId
Campaign initiative ID.

_eMarketingSpotId

protected java.lang.Integer _eMarketingSpotId
e-Marketing Spot ID.

_startDate

protected java.sql.Timestamp _startDate
Initiative schedule start date.

_endDate

protected java.sql.Timestamp _endDate
Initiative schedule end date.

_priority

protected java.lang.Integer _priority
Initiative schedule priority.
Constructor Detail

CampaignInitiativeScheduleUpdateCmdImpl

public CampaignInitiativeScheduleUpdateCmdImpl()
Method Detail

isReadyToCallExecute

public boolean isReadyToCallExecute()
Checks to see if the command is ready to call. This method will return false if the initiative schedule ID is null.
Overrides:
isReadyToCallExecute in class AbstractECTargetableCommand
Returns:
true if the command is ready to go.

checkConflict

protected void checkConflict()
                      throws java.lang.Exception
Checks to see if there is any conflict existed between the new schedule and any schedules already exist in the same time period.
Throws:
java.lang.Exception - Thrown when an error is encountered during the execution of the conflict check.

performExecute

public void performExecute()
                    throws ECException
Performs the execution of the command.
Specified by:
performExecute in interface ECCommand
Overrides:
performExecute in class AbstractECTargetableCommand
Throws:
ECException
See Also:
ECCommand#performExecute()

setEMarketingSpotId

public void setEMarketingSpotId(java.lang.Integer eMarketingSpotId)
Sets the e-Marketing Spot ID of the initiative schedule.
Specified by:
setEMarketingSpotId in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
eMarketingSpotId - The e-Marketing Spot ID of the initiative schedule.

setEndDate

public void setEndDate(java.sql.Timestamp endDate)
Sets the end date of the initiative schedule.
Specified by:
setEndDate in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
endDate - The end date of the initiative schedule.

setInitiativeId

public void setInitiativeId(java.lang.Integer initiativeId)
Sets the initiative ID of the initiative schedule.
Specified by:
setInitiativeId in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
initiativeId - The initiative ID of the initiative schedule.

setInitiativeScheduleId

public void setInitiativeScheduleId(java.lang.Integer initiativeSchedule)
Sets the ID of the initiative schedule.
Specified by:
setInitiativeScheduleId in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
initiativeSchedule - The ID of the initiative schedule.

setPriority

public void setPriority(java.lang.Integer priority)
Sets the priority of the initiative schedule.
Specified by:
setPriority in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
priority - The priority of the initiative schedule.

setStartDate

public void setStartDate(java.sql.Timestamp startDate)
Sets the start date of the initiative schedule.
Specified by:
setStartDate in interface CampaignInitiativeScheduleUpdateCmd
Parameters:
startDate - The start date of the initiative schedule.