Class BaseCommand
java.lang.Object
com.echothree.util.server.control.BaseCommand
- All Implemented Interfaces:
ExecutionErrorAccumulator,ExecutionWarningAccumulator,SecurityMessageAccumulator
- Direct Known Subclasses:
BaseEditCommand,BaseSimpleCommand
public abstract class BaseCommand
extends Object
implements ExecutionWarningAccumulator, ExecutionErrorAccumulator, SecurityMessageAccumulator
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedBaseCommand(UserVisitPK userVisitPK, CommandSecurityDefinition commandSecurityDefinition) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddExecutionError(Message message) voidaddExecutionError(String key, Object... values) voidaddExecutionWarning(Message message) voidaddExecutionWarning(String key, Object... values) voidaddSecurityMessage(Message message) voidaddSecurityMessage(String key, Object... values) protected booleanprotected booleanprotected booleanprotected abstract BaseResultexecute()protected BaseResultbooleanprotected CommandSecurityDefinitionprotected CoreControlprotected EntityInstanceprotected SecurityResultprotected final org.apache.commons.logging.LoggetLog()booleangetParty()getPreferredCurrency(Party party) getPreferredDateTimeFormat(Party party) getPreferredLanguage(Party party) getPreferredTimeZone(Party party) booleanbooleanbooleanbooleanprotected voidprotected voidremoveFilteredTransferProperty(Class clazz, String property) This should only be called an override of setupSession().protected voidremoveOption(String option) This should only be called an override of setupSession().final CommandResultrun()final Future<CommandResult>runAsync()protected SecurityResultsecurity()protected SecurityResultprotected EventsendEvent(EntityInstance entityInstance, EventTypes eventType, EntityInstance relatedEntityInstance, EventTypes relatedEventType, BasePK createdByBasePK) protected EventsendEvent(EntityInstance entityInstance, EventTypes eventType, BasePK relatedBasePK, EventTypes relatedEventType, BasePK createdByBasePK) protected EventsendEvent(BasePK basePK, EventTypes eventType, BasePK relatedBasePK, EventTypes relatedEventType, BasePK createdByBasePK) voidsetCheckIdentityVerifiedTime(boolean checkIdentityVerifiedTime) voidsetLogCommand(boolean logCommand) voidsetUpdateLastCommandTime(boolean updateLastCommandTime) protected voidvoidsetUserVisitPK(UserVisitPK userVisitPK) protected voidprotected ValidationResultvalidate()
-
Field Details
-
session
-
-
Constructor Details
-
BaseCommand
-
-
Method Details
-
getLog
-
getComponentVendorName
-
getCommandName
-
getCompanyParty
-
getPartyPK
-
getParty
-
getPartyType
-
getPartyTypeName
-
getUserVisitPK
-
setUserVisitPK
-
getUserVisit
-
getUserVisitForUpdate
-
getUserSession
-
getSession
-
getUserControl
-
getPreferredLanguage
-
getPreferredLanguage
-
getPreferredCurrency
-
getPreferredCurrency
-
getPreferredTimeZone
-
getPreferredTimeZone
-
getPreferredDateTimeFormat
-
getPreferredDateTimeFormat
-
getCheckIdentityVerifiedTime
-
setCheckIdentityVerifiedTime
-
getUpdateLastCommandTime
-
setUpdateLastCommandTime
-
getLogCommand
-
setLogCommand
-
getCommandSecurityDefinition
-
checkCommandSecurityDefinition
-
checkOptionalSecurityRoles
-
security
-
addSecurityMessage
- Specified by:
addSecurityMessagein interfaceSecurityMessageAccumulator
-
addSecurityMessage
- Specified by:
addSecurityMessagein interfaceSecurityMessageAccumulator
-
getSecurityMessages
- Specified by:
getSecurityMessagesin interfaceSecurityMessageAccumulator
-
hasSecurityMessages
- Specified by:
hasSecurityMessagesin interfaceSecurityMessageAccumulator
-
validate
-
execute
-
addExecutionWarning
- Specified by:
addExecutionWarningin interfaceExecutionWarningAccumulator
-
addExecutionWarning
- Specified by:
addExecutionWarningin interfaceExecutionWarningAccumulator
-
getExecutionWarnings
- Specified by:
getExecutionWarningsin interfaceExecutionWarningAccumulator
-
hasExecutionWarnings
- Specified by:
hasExecutionWarningsin interfaceExecutionWarningAccumulator
-
addExecutionError
- Specified by:
addExecutionErrorin interfaceExecutionErrorAccumulator
-
addExecutionError
- Specified by:
addExecutionErrorin interfaceExecutionErrorAccumulator
-
getExecutionErrors
- Specified by:
getExecutionErrorsin interfaceExecutionErrorAccumulator
-
hasExecutionErrors
- Specified by:
hasExecutionErrorsin interfaceExecutionErrorAccumulator
-
getBaseResultAfterErrors
-
runAsync
-
setupSession
-
initSession
-
teardownSession
-
run
- Throws:
BaseException
-
canSpecifyParty
-
selfOnly
-
getInsufficientSecurityResult
-
getCoreControl
-
getEntityInstanceByBasePK
-
sendEvent
protected Event sendEvent(BasePK basePK, EventTypes eventType, BasePK relatedBasePK, EventTypes relatedEventType, BasePK createdByBasePK) -
sendEvent
protected Event sendEvent(EntityInstance entityInstance, EventTypes eventType, BasePK relatedBasePK, EventTypes relatedEventType, BasePK createdByBasePK) -
sendEvent
protected Event sendEvent(EntityInstance entityInstance, EventTypes eventType, EntityInstance relatedEntityInstance, EventTypes relatedEventType, BasePK createdByBasePK) -
removeOption
This should only be called an override of setupSession(). After that, TransferCaches may have cached knowledge that specific options were set.- Parameters:
option- The option to remove.
-
removeFilteredTransferProperty
This should only be called an override of setupSession(). After that, TransferCaches may have cached knowledge that specific properties were filtered.- Parameters:
clazz- The Class whose properties should be examined.property- The property to remove.
-