Class ProcessUtil
- java.lang.Object
-
- de.hybris.platform.yacceleratorordermanagement.integration.util.BaseUtil
-
- de.hybris.platform.yacceleratorordermanagement.integration.util.ProcessUtil
-
- Direct Known Subclasses:
CancellationUtil,DeclineUtil,ReturnUtil,WorkflowUtil
public class ProcessUtil extends BaseUtil
this class is mainly to create and modify processes
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.StringCONSIGNMENT_ACTION_EVENT_NAMEprotected static java.lang.StringORDER_ACTION_EVENT_NAMEprotected static java.lang.StringORDER_PROCESS_DEFINITION_NAMEprotected static java.lang.StringORDER_TEST_PROCESSprotected static java.lang.StringRETURN_PROCESS_DEFINITION_NAMEprotected static inttimeOut-
Fields inherited from class de.hybris.platform.yacceleratorordermanagement.integration.util.BaseUtil
allocationService, atpFormulas, automatedWorkflowActionTemplates, baseStores, baseStoreService, businessProcessService, calculationService, CAMERA_CODE, CAMERA_QTY, cartService, catalogVersionService, checkOrderAction, commentTypes, commerceStockService, commonI18NService, components, consignmentBusinessProcessService, consignmentCancellationService, csAgentGroups, deliveryMode, deliveryModes, deliveryModeService, domains, emailAddresses, LENS_CODE, MEMORY_CARD_CODE, MEMORY_CARD_QTY, modelService, newestWorkflowService, order, order2, orderBusinessProcessService, orderCancelService, orders, paymentInfos, pointOfServiceService, pointsOfService, processDefinitionFactory, products, productService, refundService, restockConfigModel, restockConfigs, returnBusinessProcessService, returnRequests, returnService, sourceOrderAction, sourcingBanService, sourcingConfigs, sourcingService, stockLevels, stockService, users, userService, warehouses, warehouseStockService, warehousingWorkflowDao, workflowActionTemplates, workflowDecisionTemplates, workflowTemplates, workflowTemplateService
-
-
Constructor Summary
Constructors Constructor Description ProcessUtil()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BusinessProcessServicegetBusinessProcessService()WarehousingBusinessProcessService<ReturnRequestModel>getReturnBusinessProcessService()voidmoveOrderProcess(OrderModel order, OrderProcessModel orderProcessModel, java.lang.String choice)Moves theOrderProcessModelaccording to the given choice and waits for the consignment and order process to finish or until timeout occursvoidsetBusinessProcessService(BusinessProcessService businessProcessService)voidsetReturnBusinessProcessService(WarehousingBusinessProcessService<ReturnRequestModel> returnBusinessProcessService)voidwaitUntilConsignmentProcessIsNotRunning(OrderProcessModel orderProcessModel, ConsignmentModel consignment, int timeOut)wait for consignment process is not runningvoidwaitUntilProcessIsNotRunning(BusinessProcessModel process, int timeOut)wait until process is not runningvoidwaitUntilReturnProcessExist(ReturnRequestModel returnRequest, java.lang.String processName, int timeOut)voidwaitUntilReturnProcessIsNotRunning(ReturnRequestModel returnRequestModel, int timeOut)wait for return process is not running-
Methods inherited from class de.hybris.platform.yacceleratorordermanagement.integration.util.BaseUtil
assertProcessState, createCameraAndMemoryCardShippingOrder, createCameraPickUpOrder, createCameraShippedOrder, createOrder, getAllocationService, getAtpFormulas, getAutomatedWorkflowActionTemplates, getBaseStores, getBaseStoreService, getCalculationService, getCartService, getCatalogVersionService, getCheckOrderAction, getCommentTypes, getCommerceStockService, getCommonI18NService, getComponents, getConsignmentBusinessProcessService, getConsignmentCancellationService, getCsAgentGroups, getDeliveryMode, getDeliveryModes, getDeliveryModeService, getDomains, getEmailAddresses, getModelService, getNewestWorkflowService, getOrder, getOrderBusinessProcessService, getOrderCancelService, getOrderEntryModel_Camera, getOrderEntryModel_MemoryCard, getOrders, getPaymentInfos, getPointOfServiceService, getPointsOfService, getProcessDefinitionFactory, getProducts, getProductService, getRefundService, getRestockConfigModel, getRestockConfigs, getReturnRequests, getReturnService, getSourceOrderAction, getSourcingBanService, getSourcingConfigs, getSourcingService, getStockLevels, getStockService, getUsers, getUserService, getWarehouses, getWarehouseStockService, getWarehousingWorkflowDao, getWorkflowActionTemplates, getWorkflowDecisionTemplates, getWorkflowTemplates, getWorkflowTemplateService, refreshOrder, saveAll, setAllocationService, setAtpFormulas, setAutomatedWorkflowActionTemplates, setBaseStores, setBaseStoreService, setCalculatedStatus, setCalculationService, setCartService, setCatalogVersionService, setCheckOrderAction, setCommentTypes, setCommerceStockService, setCommonI18NService, setComponents, setConsignmentBusinessProcessService, setConsignmentCancellationService, setCsAgentGroups, setDeliveryMode, setDeliveryModes, setDeliveryModeService, setDomains, setDummyOrderTransaction, setDummyPriceRowModel, setEmailAddresses, setModelService, setNewestWorkflowService, setOrder, setOrderBusinessProcessService, setOrderCancelService, setOrders, setPaymentInfos, setPointOfServiceService, setPointsOfService, setProcessDefinitionFactory, setProducts, setProductService, setRefundService, setRestockConfigModel, setRestockConfigs, setReturnRequests, setReturnService, setSourceOrderAction, setSourcingBanService, setSourcingConfigs, setSourcingFactors, setSourcingService, setStockLevels, setStockService, setUsers, setUserService, setWarehouses, setWarehouseStockService, setWarehousingWorkflowDao, setWorkflowActionTemplates, setWorkflowDecisionTemplates, setWorkflowTemplates, setWorkflowTemplateService
-
-
-
-
Field Detail
-
ORDER_TEST_PROCESS
protected static final java.lang.String ORDER_TEST_PROCESS
- See Also:
- Constant Field Values
-
ORDER_PROCESS_DEFINITION_NAME
protected static final java.lang.String ORDER_PROCESS_DEFINITION_NAME
- See Also:
- Constant Field Values
-
RETURN_PROCESS_DEFINITION_NAME
protected static final java.lang.String RETURN_PROCESS_DEFINITION_NAME
- See Also:
- Constant Field Values
-
CONSIGNMENT_ACTION_EVENT_NAME
protected static final java.lang.String CONSIGNMENT_ACTION_EVENT_NAME
- See Also:
- Constant Field Values
-
ORDER_ACTION_EVENT_NAME
protected static final java.lang.String ORDER_ACTION_EVENT_NAME
- See Also:
- Constant Field Values
-
timeOut
protected static final int timeOut
- See Also:
- Constant Field Values
-
-
Method Detail
-
waitUntilProcessIsNotRunning
public void waitUntilProcessIsNotRunning(BusinessProcessModel process, int timeOut) throws java.lang.InterruptedException
wait until process is not running- Parameters:
process-timeOut-- Throws:
java.lang.InterruptedException
-
waitUntilReturnProcessExist
public void waitUntilReturnProcessExist(ReturnRequestModel returnRequest, java.lang.String processName, int timeOut) throws java.lang.InterruptedException
- Throws:
java.lang.InterruptedException
-
waitUntilConsignmentProcessIsNotRunning
public void waitUntilConsignmentProcessIsNotRunning(OrderProcessModel orderProcessModel, ConsignmentModel consignment, int timeOut) throws java.lang.InterruptedException
wait for consignment process is not running- Parameters:
orderProcessModel-consignment-timeOut-- Throws:
java.lang.InterruptedException
-
waitUntilReturnProcessIsNotRunning
public void waitUntilReturnProcessIsNotRunning(ReturnRequestModel returnRequestModel, int timeOut) throws java.lang.InterruptedException
wait for return process is not running- Parameters:
returnRequestModel-timeOut-- Throws:
java.lang.InterruptedException
-
moveOrderProcess
public void moveOrderProcess(OrderModel order, OrderProcessModel orderProcessModel, java.lang.String choice) throws java.lang.InterruptedException
Moves theOrderProcessModelaccording to the given choice and waits for the consignment and order process to finish or until timeout occurs- Parameters:
order- the givenOrderModelorderProcessModel- the associatedOrderProcessModelwith the givenOrderModelchoice- the choice with which to move the givenOrderProcessModel- Throws:
java.lang.InterruptedException
-
getReturnBusinessProcessService
public WarehousingBusinessProcessService<ReturnRequestModel> getReturnBusinessProcessService()
- Overrides:
getReturnBusinessProcessServicein classBaseUtil
-
setReturnBusinessProcessService
public void setReturnBusinessProcessService(WarehousingBusinessProcessService<ReturnRequestModel> returnBusinessProcessService)
- Overrides:
setReturnBusinessProcessServicein classBaseUtil
-
getBusinessProcessService
public BusinessProcessService getBusinessProcessService()
- Overrides:
getBusinessProcessServicein classBaseUtil
-
setBusinessProcessService
public void setBusinessProcessService(BusinessProcessService businessProcessService)
- Overrides:
setBusinessProcessServicein classBaseUtil
-
-