Class BTWarehouseOperationCreation<I>
java.lang.Object
overit.geocall.bl.BusinessTask<WarehouseOperationCreationEvent<I>>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask<WarehouseOperationCreationEvent<I>>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask<WarehouseOperationCreationEvent<I>>
overit.geocallapp.wfm.inventory.bl.task.BTInventoryManagement<WarehouseOperationCreationEvent<I>>
overit.geocallapp.wfm.inventory.bl.warehouse.operation.task.BTWarehouseOperationCreation<I>
- Type Parameters:
I- the generic type
- All Implemented Interfaces:
Serializable,Tool,ValidExecution
- Direct Known Subclasses:
BTWarehouseOperationCreationFromAccounting,BTWarehouseOperationCreationFromFile,BTWarehouseOperationCreationFromStockChange,BTWarehouseOperationCreationFromTransferRequest,BTWarehouseOperationCreationManual
public abstract class BTWarehouseOperationCreation<I>
extends BTInventoryManagement<WarehouseOperationCreationEvent<I>>
Base business task in order to generate a warehouse operation.
- Since:
- 14.0
- See Also:
- GCApi:
- task
-
Field Summary
Fields inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
LOG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcompleteOperation(PoolKit poolKit) Completes theWarehouseOperationdata.protected abstract BOWarehouseOperationHeadercreateOperationHeader(I input, PoolKit poolKit) Creates theBOWarehouseOperationHeader.protected abstract voidcreateOperationItems(I input, PoolKit poolKit) Creates the operationBOWarehouseOperationItem.protected abstract BOWarehouseOperationHeaderSourcecreateOperationSource(I input, PoolKit poolKit) Creates theBOWarehouseOperationHeaderSource.protected voidexecute(WarehouseOperationCreationEvent<I> event, PoolKit poolKit) Executes the process of creating a newWarehouseOperation.protected abstract LogHelpergetInputLog(I input) Returns the input log.Returns the log helper.protected abstract LonggetOperationType(I input, PoolKit poolKit) Returns the type that the newWarehouseOperationwill have.Returns the warehouse operation.protected BOWarehouseOperationTypeReturns the warehouse operation type.protected voidinitialize(I input, PoolKit poolKit) Initializes all needed element for the process.booleanChecks if the execution is valid.protected voidsaveWarehouseOperation(PoolKit poolKit) Saves the currentWarehouseOperation.protected abstract voidValidates the data before the operation creation.Methods inherited from class overit.geocallapp.wfm.inventory.bl.task.BTInventoryManagement
checkValidExecutionMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
getException, throwExceptionIfInvalidMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask
body, getEventMethods inherited from class overit.geocall.bl.BusinessTask
start, start, startAlone, startInBackground
-
Constructor Details
-
BTWarehouseOperationCreation
public BTWarehouseOperationCreation()
-
-
Method Details
-
getOperationType
protected abstract Long getOperationType(I input, PoolKit poolKit) throws DAException, DAValidateException Returns the type that the newWarehouseOperationwill have.- Parameters:
input- the event inputpoolKit- thePoolKit- Returns:
- the
BOWarehouseOperationTypeid - Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
validate
Validates the data before the operation creation.- Parameters:
input- the event inputpoolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
createOperationHeader
Creates theBOWarehouseOperationHeader.- Parameters:
input- the inputpoolKit- thePoolKit- Returns:
- the BO warehouse operation header
-
createOperationSource
Creates theBOWarehouseOperationHeaderSource.- Parameters:
input- the inputpoolKit- thePoolKit- Returns:
- the BO warehouse operation header source
-
createOperationItems
protected abstract void createOperationItems(I input, PoolKit poolKit) throws DAException, DAValidateException Creates the operationBOWarehouseOperationItem.- Parameters:
input- the inputpoolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
getLogHelper
Returns the log helper.- Returns:
- the log helper
-
getWarehouseOperation
Returns the warehouse operation.- Returns:
- the warehouse operation
-
getWarehouseOperationType
Returns the warehouse operation type.- Returns:
- the warehouse operation type
-
execute
protected void execute(WarehouseOperationCreationEvent<I> event, PoolKit poolKit) throws DAException, DAValidateException Executes the process of creating a newWarehouseOperation.- Specified by:
executein classValidExecutionBusinessTask<WarehouseOperationCreationEvent<I>>- Parameters:
event- the event that extendsWarehouseOperationCreationEventpoolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
getInputLog
Returns the input log.- Parameters:
input- the input- Returns:
- the input log
-
initialize
Initializes all needed element for the process.- Parameters:
input- the inputpoolKit- thePoolKit- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
completeOperation
Completes theWarehouseOperationdata.- Parameters:
poolKit- thePoolKit- Throws:
DAException- the DA exceptionDAValidateException- the DA validate exception
-
saveWarehouseOperation
Saves the currentWarehouseOperation.- Parameters:
poolKit- thePoolKit- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
isValidExecution
public boolean isValidExecution()Checks if the execution is valid.- Returns:
- true, if successful
-