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

Method constructor

repos/effect/packages/effect/src/SchemaAST.ts:1617–1643  ·  view source on GitHub ↗
(
    isMutable: boolean,
    elements: ReadonlyArray<AST>,
    rest: ReadonlyArray<AST>,
    annotations?: Schema.Annotations.Annotations,
    checks?: Checks,
    encoding?: Encoding,
    context?: Context,
    encodingChecks?: Checks
  )

Source from the content-addressed store, hash-verified

1615 symbol: symbol,
1616 annotations?: Schema.Annotations.Annotations,
1617 checks?: Checks,
1618 encoding?: Encoding,
1619 context?: Context
1620) => UniqueSymbol = class extends ASTNodeImpl {
1621 readonly _tag = "UniqueSymbol"
1622 readonly symbol: symbol
1623
1624 constructor(
1625 symbol: symbol,
1626 annotations?: Schema.Annotations.Annotations,
1627 checks?: Checks,
1628 encoding?: Encoding,
1629 context?: Context
1630 ) {
1631 super(annotations, checks, encoding, context)
1632 this.symbol = symbol
1633 }
1634 /** @internal */
1635 getParser() {
1636 return fromConst(this, this.symbol)
1637 }
1638 /** @internal */
1639 toCodecStringTree(): AST {
1640 const key = globalThis.Symbol.keyFor(this.symbol)
1641 return replaceEncoding(this, [
1642 new Link(
1643 key === undefined ? never : new Literal(globalThis.String(this.symbol)),
1644 symbolToString.transformation
1645 )
1646 ])

Callers

nothing calls this directly

Calls 2

isOptionalFunction · 0.85
someMethod · 0.80

Tested by

no test coverage detected