Comparing version 0.11.0 to 0.11.1
{ | ||
"name": "horpyna", | ||
"version": "0.11.0", | ||
"version": "0.11.1", | ||
"description": "utility to manage async processes", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -101,22 +101,24 @@ # HORPYNA | ||
let validateParamsComponent = new ValidateParams(); | ||
const validateParamsComponent = new ValidateParams(); | ||
let validateErrorMessageComponent = new SendResponse(options); | ||
const validateErrorMessageComponent = new SendResponse(options); | ||
validateParamsComponent.addJoint(validateErrorMessageComponent, "customErrorChannel"); | ||
let getUserList = new GetEntityFromDb(options); | ||
const getUserList = new GetEntityFromDb(options); | ||
validateParamsComponent.addJoint(getUserList); | ||
let zeroUsersErrorMessageComponent = new SendResponse(options); | ||
const zeroUsersErrorMessageComponent = new SendResponse(options); | ||
getUserList.addJoint(zeroUsersErrorMessageComponent, "otherCustomErrorChannel"); | ||
let calculateWhenOneEntity = new CalculateSomething(options); | ||
const calculateWhenOneEntity = new CalculateSomething(options); | ||
getUserList.addJoint(calculateWhenOneEntity, "oneEntityChannel"); | ||
let calculateWhenManyEntities = new CalculateSomething(options); | ||
const calculateWhenManyEntities = new CalculateSomething(options); | ||
getUserList.addJoint(calculateWhenManyEntities, "manyEntitiesChannel"); | ||
validateParamsComponent.start(startParameters, outputChannel => { | ||
//callback when chain finished calculation | ||
getUserList.addCallback((value, channel) => { | ||
//callback when getUserList finished calculation | ||
}); | ||
validateParamsComponent.start(startParameters); | ||
@@ -123,0 +125,0 @@ |
Sorry, the diff of this file is not supported yet
161
103966