MCPcopy
hub / github.com/Effect-TS/effect / encode

Function encode

packages/experimental/src/Persistence.ts:252–260  ·  view source on GitHub ↗
(
            method: string,
            key: ResultPersistence.Key<R, IE, E, IA, A>,
            value: Exit.Exit<A, E>
          )

Source from the content-addressed store, hash-verified

250 (_) => PersistenceParseError.make(method, _.issue)
251 )
252 const encode = <R, IE, E, IA, A>(
253 method: string,
254 key: ResultPersistence.Key<R, IE, E, IA, A>,
255 value: Exit.Exit<A, E>
256 ) =>
257 Effect.mapError(
258 Schema.serializeExit(key, value),
259 (_) => PersistenceParseError.make(method, _.issue)
260 )
261 const makeKey = <R, IE, E, IA, A>(
262 key: ResultPersistence.Key<R, IE, E, IA, A>
263 ) => key[PrimaryKey.symbol]()

Callers 1

Persistence.tsFile · 0.70

Calls 1

makeMethod · 0.65

Tested by

no test coverage detected