11import type { AllStates } from '../typings/AllStates' ;
2- import type { ExecutionResult } from '../typings/StateActions' ;
2+ import type { ActionResult } from '../typings/StateActions' ;
33import type { RetryResult , CatchResult , StateHandlers } from '../typings/StateExecutor' ;
44import type { ExecuteOptions } from '../typings/StateMachineImplementation' ;
55import type { ErrorOutput } from '../typings/ErrorHandling' ;
@@ -105,7 +105,7 @@ export class StateExecutor {
105105 /**
106106 * Execute the current state.
107107 */
108- async execute ( input : JSONValue , context : Context , options : ExecuteOptions ) : Promise < ExecutionResult > {
108+ async execute ( input : JSONValue , context : Context , options : ExecuteOptions ) : Promise < ActionResult > {
109109 const rawInput = cloneDeep ( input ) ;
110110
111111 try {
@@ -274,7 +274,7 @@ export class StateExecutor {
274274 context : Context ,
275275 stateName : string ,
276276 options : ExecuteOptions
277- ) : Promise < ExecutionResult > {
277+ ) : Promise < ActionResult > {
278278 const overrideFn = options . runOptions ?. overrides ?. taskResourceLocalHandlers ?. [ stateName ] ;
279279 const awsConfig = options . stateMachineOptions ?. awsConfig ;
280280
@@ -297,7 +297,7 @@ export class StateExecutor {
297297 context : Context ,
298298 stateName : string ,
299299 options : ExecuteOptions
300- ) : Promise < ExecutionResult > {
300+ ) : Promise < ActionResult > {
301301 const parallelStateAction = new ParallelStateAction ( stateDefinition , stateName ) ;
302302 const executionResult = await parallelStateAction . execute ( input , context , {
303303 stateMachineOptions : options . stateMachineOptions ,
@@ -323,7 +323,7 @@ export class StateExecutor {
323323 context : Context ,
324324 stateName : string ,
325325 options : ExecuteOptions
326- ) : Promise < ExecutionResult > {
326+ ) : Promise < ActionResult > {
327327 const mapStateAction = new MapStateAction ( stateDefinition , stateName ) ;
328328 const executionResult = await mapStateAction . execute ( input , context , {
329329 stateMachineOptions : options . stateMachineOptions ,
@@ -350,7 +350,7 @@ export class StateExecutor {
350350 stateName : string ,
351351 // eslint-disable-next-line @typescript-eslint/no-unused-vars
352352 options : ExecuteOptions
353- ) : Promise < ExecutionResult > {
353+ ) : Promise < ActionResult > {
354354 const passStateAction = new PassStateAction ( stateDefinition , stateName ) ;
355355 const executionResult = await passStateAction . execute ( input , context ) ;
356356
@@ -370,7 +370,7 @@ export class StateExecutor {
370370 context : Context ,
371371 stateName : string ,
372372 options : ExecuteOptions
373- ) : Promise < ExecutionResult > {
373+ ) : Promise < ActionResult > {
374374 const waitTimeOverrideOption = options . runOptions ?. overrides ?. waitTimeOverrides ?. [ stateName ] ;
375375
376376 const waitStateAction = new WaitStateAction ( stateDefinition , stateName ) ;
@@ -406,7 +406,7 @@ export class StateExecutor {
406406 stateName : string ,
407407 // eslint-disable-next-line @typescript-eslint/no-unused-vars
408408 options : ExecuteOptions
409- ) : Promise < ExecutionResult > {
409+ ) : Promise < ActionResult > {
410410 const choiceStateAction = new ChoiceStateAction ( stateDefinition , stateName ) ;
411411 const executionResult = await choiceStateAction . execute ( input , context ) ;
412412
@@ -427,7 +427,7 @@ export class StateExecutor {
427427 stateName : string ,
428428 // eslint-disable-next-line @typescript-eslint/no-unused-vars
429429 options : ExecuteOptions
430- ) : Promise < ExecutionResult > {
430+ ) : Promise < ActionResult > {
431431 const succeedStateAction = new SucceedStateAction ( stateDefinition , stateName ) ;
432432 const executionResult = await succeedStateAction . execute ( input , context ) ;
433433
@@ -448,7 +448,7 @@ export class StateExecutor {
448448 stateName : string ,
449449 // eslint-disable-next-line @typescript-eslint/no-unused-vars
450450 options : ExecuteOptions
451- ) : Promise < ExecutionResult > {
451+ ) : Promise < ActionResult > {
452452 const failStateAction = new FailStateAction ( stateDefinition , stateName ) ;
453453 const executionResult = await failStateAction . execute ( input , context ) ;
454454
0 commit comments