supply-chain-0.0.1.0: Composable request-response pipelines
Safe HaskellSafe-Inferred
LanguageGHC2021

SupplyChain.JobAndVendor

Description

Job + vendor

Synopsis

Connection

(>-) Source #

Arguments

:: Vendor up down action

Upstream

-> Job down action product

Downstream

-> Job up action product 

Modify a job with a vendor that interprets its requests

(>+) Source #

Arguments

:: Vendor up down action

Upstream

-> Job down action product

Downstream

-> Job up action (Referral up down action product) 

Connect a vendor to a job, producing a job which returns both the product and a new version of the vendor.

Use this function instead of (>-) if you need to attach a succession of jobs to one stateful vendor.

Conversion

once Source #

Arguments

:: Vendor up (Unit product) action

Vendor

-> Job up action product

Job

loop Source #

Arguments

:: Job up action product

Job

-> Vendor up (Unit product) action

Vendor

loop' Source #

Arguments

:: (forall x. down x -> Job up action x)

Stateless handler

-> Vendor up down action

Vendor