Verification monad
The verification monad is similar to ResourceT in intent, in that we can
register handlers to be run to release resources. Unlike ResourceT,
however, we maintain _two_ handlers: a cleanup handler which is run whether
or not verification succeeds, and a finalisation handler which is run only if
verification succeeds.
Cleanup handlers are registered using acquire, and are guaranteed to run just before the computation terminates (after the finalisation handler).
The finalisation handlers are run only when verification succeeds, and can be registered with ifVerified. Finalisation can be used for instance to update the local cache (which should only happen if verification is successful).
Instances4Monad, Functor, Applicative, MonadIO
Monad VerifyDefined in hackage-security-0.6.3.2 · Hackage.Security.Client.VerifyFunctor VerifyDefined in hackage-security-0.6.3.2 · Hackage.Security.Client.VerifyApplicative VerifyDefined in hackage-security-0.6.3.2 · Hackage.Security.Client.VerifyMonadIO VerifyDefined in hackage-security-0.6.3.2 · Hackage.Security.Client.Verify