Hyperlinkv0.8.0-beta.28

effect

Effect235

Constructors

callbackconstCreates an Effect from a callback-based asynchronous API.dieconstCreates an effect that terminates a fiber with a specified error.failconstCreates an Effect that represents a recoverable error.failCauseconstCreates an Effect that represents a failure with a specific Cause.failCauseSyncconstCreates an Effect that represents a failure with a Cause computed lazily.failSyncconstCreates an Effect that represents a recoverable error using a lazy evaluation.gennamespaceProvides a way to write effectful code using generator functions, simplifying control flow and error handling.neverconstReturns an effect that will never produce anything.promiseconstCreates an Effect that represents an asynchronous computation guaranteed to succeed.succeedconstCreates an Effect that always succeeds with a given value.succeedNoneconstReturns an effect which succeeds with None.succeedSomeconstReturns an effect which succeeds with the value wrapped in a Some.suspendconstCreates an Effect lazily, delaying construction until it is needed.syncconstCreates an Effect that represents a synchronous side-effectful computation.tryPromiseconstCreates an Effect from an asynchronous computation that may throw or reject, mapping failures into the error channel.withFiberconstProvides access to the current fiber within an effect computation.yieldNowconstYields control back to the Effect runtime, allowing other fibers to execute.yieldNowWithconstYields control back to the Effect runtime with a specified priority, allowing other fibers to execute.

Models

Type Ids

Guards

Mapping

Filtering

Sequencing

Context

Logging

Caching

Clock

Collecting

Condition Checking

Conditional Operators

Converting

Converting Failures To Defects

Delays & Timeouts

Do Notation

Eager

Effectify

Environment

Error Accumulation

Error Handling

catchCauseconstHandles both recoverable and unrecoverable errors by providing a recovery effect.catchCauseFilterconstRecovers from specific failures based on a Filter.catchCauseIfconstRecovers from specific failures based on a predicate.catchDefectconstRecovers from defects using a provided recovery function.catchFilterconstRecovers from specific errors using a Filter.catchIfconstRecovers from specific errors using a Predicate or Refinement.catchNoSuchElementconstCatches NoSuchElementError failures and converts them to Option.none.catchReasonconstCatches a specific reason within a tagged error.catchReasonsconstCatches multiple reasons within a tagged error using an object of handlers.catchTagconstCatches and handles specific errors by their _tag field, which is used as a discriminator.catchTagsconstHandles multiple errors in a single block of code using their _tag field.ignoreconstDiscards both the success and failure values of an effect.ignoreCauseconstIgnores the effect's failure cause, including defects and interruptions.mapErrorconstTransforms the failure value of an effect without changing its success value.retryconstRetries typed failures from an effect according to a retry policy.retryOrElseconstRetries a failing effect and runs a fallback effect if retries are exhausted.sandboxconstExposes an effect's full failure cause in the error channel as Cause<E>.TagsWithReasontypeType helper that keeps only error tags whose tagged error contains a tagged reason field.unwrapReasonconstPromotes nested reason errors into the Effect error channel, replacing the parent error.withErrorReportingconstRuns an effect and reports any errors to the configured ErrorReporters.

Fallback

Functions

Interruption

Outcome Encapsulation

Pattern Matching

Racing

References

Repetition

Requests & Batching

Resource Management

Running

Supervision & Fibers

Tracing

Tracking

Transactions

Type Lambdas

Utility Types

Zipping

Namespaces