com.ibm.commerce.account.commands
Class AccountSaveCmdImpl

com.ibm.commerce.command.AbstractECTargetableCommand
  |
  +--com.ibm.commerce.command.ControllerCommandImpl
        |
        +--com.ibm.commerce.account.commands.AccountSaveCmdImpl
All Implemented Interfaces:
AccCommand, AccountSaveCmd, ControllerCommand, ECCommand, ECTargetableCommand, Protectable

public class AccountSaveCmdImpl
extends ControllerCommandImpl
implements AccountSaveCmd

This is the default implementation of the AccountSave controller command.

See Also:
AccountSaveCmd

Field Summary
static java.lang.String CLASSNAME
           
static java.lang.String COPYRIGHT
           
 
Fields inherited from class com.ibm.commerce.command.ControllerCommandImpl
requestProperties, responseProperties, retriable, viewReqProperties
 
Fields inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
commandContext
 
Fields inherited from interface com.ibm.commerce.account.commands.AccountSaveCmd
defaultCommandClassName, NAME
 
Constructor Summary
AccountSaveCmdImpl()
           
 
Method Summary
 java.lang.Long getAccountId()
           
 java.lang.Integer getAccountState()
           
 AccessVector getResources()
          Gets the access vector accessed by this command.
 TypedProperty getViewInputProperties()
          Retrieves the request properties set by the setRequestProperties() method that will be passed onto the view command.
 boolean isInRightStateToUpdate()
           
 boolean isUpdate()
           
 void performExecute()
          Contains the actual business logic of the command It should be implemented by all the command writer.
 void setAccountId(java.lang.Long newAccountId)
           
 void setAccountState(java.lang.Integer newAccountState)
           
 void setCurrentAccountState(java.lang.Integer newAccountState)
           
 void setLanguageId(java.lang.Integer newLangId)
           
 void setRequestProperties(TypedProperty aRequestProperties)
          The WebController calls this method before invoking the execute method in this command to set the request properties for this command.
 void validateParameters()
          Performs server side parameter checking.
 
Methods inherited from class com.ibm.commerce.command.ControllerCommandImpl
fulfills, getForUserId, getGeneric, getOwner, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, isGeneric, isRetriable, mergeProperties, setForUserId, setGeneric, setOwner, setResponseProperties, setRetriable, setViewInputProperties
 
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
accessControlCheck, checkIsAllowed, checkResourcePermission, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties
 
Methods inherited from interface com.ibm.commerce.command.ControllerCommand
execute, getGeneric, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, isGeneric, isRetriable, mergeProperties, setGeneric, setRetriable, setViewInputProperties
 
Methods inherited from interface com.ibm.commerce.command.AccCommand
accessControlCheck, getAccCheck, getForUserId, setAccCheck, setForUserId, setOwner
 
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getStoreId, getUser, getUserId, setCommandContext, setCommandIfName, setDefaultProperties
 
Methods inherited from interface com.ibm.commerce.security.Protectable
fulfills, getOwner
 

Field Detail

CLASSNAME

public static final java.lang.String CLASSNAME

COPYRIGHT

public static final java.lang.String COPYRIGHT
Constructor Detail

AccountSaveCmdImpl

public AccountSaveCmdImpl()
Method Detail

getAccountId

public java.lang.Long getAccountId()

getAccountState

public java.lang.Integer getAccountState()

getResources

public AccessVector getResources()
                          throws ECException
Description copied from interface: ECCommand
Gets the access vector accessed by this command. The default implementation returns null indicating that no protectable resource is accessed by this command. It is the responsibilities of the command writer to return the protectable primary resource(s) and the corresponding actions accessed by this command.

Specified by:
getResources in interface ECCommand
Overrides:
getResources in class AbstractECTargetableCommand
Following copied from interface: com.ibm.commerce.command.ECCommand
Returns:
AccessVector - a vector of resource action pairs

getViewInputProperties

public TypedProperty getViewInputProperties()
Description copied from interface: ControllerCommand
Retrieves the request properties set by the setRequestProperties() method that will be passed onto the view command. Command writer can overwrite this method to return all, part or non of the request properties to be passed to the view command
Specified by:
getViewInputProperties in interface ControllerCommand
Overrides:
getViewInputProperties in class ControllerCommandImpl
Following copied from interface: com.ibm.commerce.command.ControllerCommand
Returns:
com.ibm.commerce.datatype.TypeProperty

isInRightStateToUpdate

public boolean isInRightStateToUpdate()

isUpdate

public boolean isUpdate()

performExecute

public void performExecute()
                    throws ECException
Description copied from interface: ECCommand
Contains the actual business logic of the command It should be implemented by all the command writer.
Specified by:
performExecute in interface ECCommand
Overrides:
performExecute in class AbstractECTargetableCommand
Following copied from interface: com.ibm.commerce.command.ECCommand
Throws:
com.ibm.commerce.command.CommandException - The superclass for all ECExceptions.

setAccountId

public void setAccountId(java.lang.Long newAccountId)

setAccountState

public void setAccountState(java.lang.Integer newAccountState)

setCurrentAccountState

public void setCurrentAccountState(java.lang.Integer newAccountState)

setLanguageId

public void setLanguageId(java.lang.Integer newLangId)

setRequestProperties

public void setRequestProperties(TypedProperty aRequestProperties)
                          throws ECApplicationException
Description copied from interface: ControllerCommand
The WebController calls this method before invoking the execute method in this command to set the request properties for this command. It is the responsibility of the implementer of the ControllerCommand to extract the required input parameters from the request properties and perform parameter checking.
Specified by:
setRequestProperties in interface AccountSaveCmd
Overrides:
setRequestProperties in class ControllerCommandImpl
Following copied from interface: com.ibm.commerce.command.ControllerCommand
Parameters:
requestProperties - com.ibm.commerce.datatype.TypedProperty
Throws:
com.ibm.commerce.exception.ECException. -  

validateParameters

public void validateParameters()
                        throws ECException
Description copied from interface: ECCommand
Performs server side parameter checking. This method replaces the checkParameters() method in a previous version of the code.

Specified by:
validateParameters in interface ECCommand
Overrides:
validateParameters in class AbstractECTargetableCommand
Following copied from interface: com.ibm.commerce.command.ECCommand
Throws:
ECException. -