MCPcopy Create free account
hub / github.com/effect-app/libs / toCodecStringTree

Method toCodecStringTree

repos/effect/packages/effect/src/SchemaAST.ts:1046–1060  ·  view source on GitHub ↗

@internal

()

Source from the content-addressed store, hash-verified

1044 *
1045 * **Details**
1046 *
1047 * Holds `enums` as an array of `[name, value]` pairs where values are
1048 * `string | number`. Parsing succeeds when the input matches any enum value.
1049 *
1050 * @see {@link isEnum}
1051 * @category models
1052 * @since 4.0.0
1053 */
1054export class Enum extends Base {
1055 readonly _tag = "Enum"
1056 readonly enums: ReadonlyArray<readonly [string, string | number]>
1057
1058 constructor(
1059 enums: ReadonlyArray<readonly [string, string | number]>,
1060 annotations?: Schema.Annotations.Annotations,
1061 checks?: Checks,
1062 encoding?: Encoding,
1063 context?: Context

Callers 13

Schema.tst.tsFile · 0.45
toCodec.test.tsFile · 0.45
assertXmlFunction · 0.45
assertXmlFailureFunction · 0.45
SchemaAST.tsFile · 0.45
schemaFunction · 0.45
Schema.tsFile · 0.45
transformResponseFunction · 0.45
transformPayloadFunction · 0.45
makeSchemaPrimitiveFunction · 0.45
compileUriTemplateFunction · 0.45

Calls 4

replaceEncodingFunction · 0.85
someMethod · 0.80
mapMethod · 0.65
transformMethod · 0.65

Tested by 2

assertXmlFunction · 0.36
assertXmlFailureFunction · 0.36