NullAST node matching the null literal value.
Details
Parsing succeeds only when the input is exactly null.
Source effect/SchemaAST.ts:71511 lines
export class class Nullclass Null {
_tag: 'Null';
getParser: () => SchemaParser.Parser;
getExpected: () => string;
annotations: Schema.Annotations.Annotations | undefined;
checks: Checks | undefined;
encoding: Encoding | undefined;
context: Context | undefined;
toString: () => string;
}
AST node matching the null literal value.
Details
Parsing succeeds only when the input is exactly null.
Null extends class BaseRepresents the abstract base class for all
AST
node variants.
Details
Every AST node extends Base and inherits these fields:
annotations — user-supplied metadata (identifier, title, description,
arbitrary keys).
checks — optional
Checks
for post-type-match validation.
encoding — optional
Encoding
chain for type ↔ wire
transformations.
context — optional
Context
for per-property metadata.
Subclasses add a _tag discriminant and variant-specific data.
Base {
readonly Null._tag: "Null"_tag = "Null"
/** @internal */
Null.getParser(): SchemaParser.ParsergetParser() {
return function fromConst<T>(
ast: AST,
value: T
): SchemaParser.Parser
fromConst(this, null)
}
/** @internal */
Null.getExpected(): stringgetExpected(): string {
return "null"
}
}Referenced by 2 symbols