OfferedFailure implements ErrorHandler
FinalYes
The branch pipeline's handler - it remembers the last loading or transformation error it was offered and leaves every decision to $handler.
Interfaces
Methods
- __construct() : mixed
- describe() : null|Description
- forget() : void
- fromDescription() : static
- onExtraction() : ExtractionAction
- onLoading() : LoadingAction
- onTransformation() : TransformationAction
- undecided() : LoadingError|TransformationError|null
- The error $failure was offered in, by identity, when no handler decided it: PipelineSteps hands the handler the failure and rethrows the same instance. null when a handler decided it or no user step raised it.
Methods
__construct()
public
__construct(null|ErrorHandler $handler) : mixed
Parameters
- $handler : null|ErrorHandler
-
null when nothing inside the branch decides: every error propagates, and the caller decides it through undecided()
describe()
public
describe() : null|Description
Return values
null|Description —null when this instance cannot cross a process boundary (a live client, a custom collaborator)
forget()
public
forget() : void
fromDescription()
public
static fromDescription(array<string|int, mixed> $data, Rebuild $rebuild) : static
Parameters
- $data : array<string|int, mixed>
- $rebuild : Rebuild
Return values
staticonExtraction()
public
onExtraction(ExtractionError $error) : ExtractionAction
Parameters
- $error : ExtractionError
Return values
ExtractionActiononLoading()
public
onLoading(LoadingError $error) : LoadingAction
Parameters
- $error : LoadingError
Return values
LoadingActiononTransformation()
public
onTransformation(TransformationError $error) : TransformationAction
Parameters
- $error : TransformationError
Return values
TransformationActionundecided()
The error $failure was offered in, by identity, when no handler decided it: PipelineSteps hands the handler the failure and rethrows the same instance. null when a handler decided it or no user step raised it.
public
undecided(Throwable $failure) : LoadingError|TransformationError|null
Parameters
- $failure : Throwable