@sinclair/typebox 0.24.51 → 0.24.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/compiler/compiler.d.ts +25 -28
  2. package/compiler/compiler.js +408 -409
  3. package/compiler/index.d.ts +2 -2
  4. package/compiler/index.js +47 -47
  5. package/conditional/conditional.d.ts +17 -17
  6. package/conditional/conditional.js +91 -91
  7. package/conditional/index.d.ts +2 -2
  8. package/conditional/index.js +45 -45
  9. package/conditional/structural.d.ts +11 -11
  10. package/conditional/structural.js +657 -657
  11. package/errors/errors.d.ts +60 -60
  12. package/errors/errors.js +398 -398
  13. package/errors/index.d.ts +1 -1
  14. package/errors/index.js +44 -44
  15. package/format/format.d.ts +12 -12
  16. package/format/format.js +55 -55
  17. package/format/index.d.ts +1 -1
  18. package/format/index.js +44 -44
  19. package/guard/guard.d.ts +56 -56
  20. package/guard/guard.js +351 -351
  21. package/guard/index.d.ts +1 -1
  22. package/guard/index.js +44 -44
  23. package/license +22 -22
  24. package/package.json +43 -40
  25. package/readme.md +1152 -1152
  26. package/typebox.d.ts +408 -408
  27. package/typebox.js +383 -383
  28. package/value/cast.d.ts +26 -26
  29. package/value/cast.js +364 -364
  30. package/value/check.d.ts +8 -8
  31. package/value/check.js +331 -331
  32. package/value/clone.d.ts +3 -3
  33. package/value/clone.js +65 -65
  34. package/value/create.d.ts +14 -14
  35. package/value/create.js +357 -357
  36. package/value/delta.d.ts +22 -22
  37. package/value/delta.js +168 -168
  38. package/value/equal.d.ts +3 -3
  39. package/value/equal.js +74 -74
  40. package/value/index.d.ts +3 -3
  41. package/value/index.js +48 -48
  42. package/value/is.d.ts +10 -10
  43. package/value/is.js +49 -49
  44. package/value/pointer.d.ts +24 -24
  45. package/value/pointer.js +142 -142
  46. package/value/value.d.ts +31 -31
  47. package/value/value.js +81 -81
package/errors/index.d.ts CHANGED
@@ -1 +1 @@
1
- export * from './errors';
1
+ export * from './errors';
package/errors/index.js CHANGED
@@ -1,44 +1,44 @@
1
- "use strict";
2
- /*--------------------------------------------------------------------------
3
-
4
- @sinclair/typebox/errors
5
-
6
- The MIT License (MIT)
7
-
8
- Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
-
10
- Permission is hereby granted, free of charge, to any person obtaining a copy
11
- of this software and associated documentation files (the "Software"), to deal
12
- in the Software without restriction, including without limitation the rights
13
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
- copies of the Software, and to permit persons to whom the Software is
15
- furnished to do so, subject to the following conditions:
16
-
17
- The above copyright notice and this permission notice shall be included in
18
- all copies or substantial portions of the Software.
19
-
20
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
- THE SOFTWARE.
27
-
28
- ---------------------------------------------------------------------------*/
29
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
30
- if (k2 === undefined) k2 = k;
31
- var desc = Object.getOwnPropertyDescriptor(m, k);
32
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
33
- desc = { enumerable: true, get: function() { return m[k]; } };
34
- }
35
- Object.defineProperty(o, k2, desc);
36
- }) : (function(o, m, k, k2) {
37
- if (k2 === undefined) k2 = k;
38
- o[k2] = m[k];
39
- }));
40
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
41
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
42
- };
43
- Object.defineProperty(exports, "__esModule", { value: true });
44
- __exportStar(require("./errors"), exports);
1
+ "use strict";
2
+ /*--------------------------------------------------------------------------
3
+
4
+ @sinclair/typebox/errors
5
+
6
+ The MIT License (MIT)
7
+
8
+ Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
+
10
+ Permission is hereby granted, free of charge, to any person obtaining a copy
11
+ of this software and associated documentation files (the "Software"), to deal
12
+ in the Software without restriction, including without limitation the rights
13
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
+ copies of the Software, and to permit persons to whom the Software is
15
+ furnished to do so, subject to the following conditions:
16
+
17
+ The above copyright notice and this permission notice shall be included in
18
+ all copies or substantial portions of the Software.
19
+
20
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
+ THE SOFTWARE.
27
+
28
+ ---------------------------------------------------------------------------*/
29
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
30
+ if (k2 === undefined) k2 = k;
31
+ var desc = Object.getOwnPropertyDescriptor(m, k);
32
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
33
+ desc = { enumerable: true, get: function() { return m[k]; } };
34
+ }
35
+ Object.defineProperty(o, k2, desc);
36
+ }) : (function(o, m, k, k2) {
37
+ if (k2 === undefined) k2 = k;
38
+ o[k2] = m[k];
39
+ }));
40
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
41
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
42
+ };
43
+ Object.defineProperty(exports, "__esModule", { value: true });
44
+ __exportStar(require("./errors"), exports);
@@ -1,12 +1,12 @@
1
- export declare type FormatValidationFunction = (value: string) => boolean;
2
- /** Shared string formats used by the TypeCompiler and Value modules */
3
- export declare namespace Format {
4
- /** Clears all formats */
5
- function Clear(): void;
6
- /** Returns true if the string format exists */
7
- function Has(format: string): boolean;
8
- /** Sets a string format validation function */
9
- function Set(format: string, func: FormatValidationFunction): void;
10
- /** Gets a string format validation function */
11
- function Get(format: string): FormatValidationFunction | undefined;
12
- }
1
+ export declare type FormatValidationFunction = (value: string) => boolean;
2
+ /** Shared string formats used by the TypeCompiler and Value modules */
3
+ export declare namespace Format {
4
+ /** Clears all formats */
5
+ function Clear(): void;
6
+ /** Returns true if the string format exists */
7
+ function Has(format: string): boolean;
8
+ /** Sets a string format validation function */
9
+ function Set(format: string, func: FormatValidationFunction): void;
10
+ /** Gets a string format validation function */
11
+ function Get(format: string): FormatValidationFunction | undefined;
12
+ }
package/format/format.js CHANGED
@@ -1,55 +1,55 @@
1
- "use strict";
2
- /*--------------------------------------------------------------------------
3
-
4
- @sinclair/typebox/format
5
-
6
- The MIT License (MIT)
7
-
8
- Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
-
10
- Permission is hereby granted, free of charge, to any person obtaining a copy
11
- of this software and associated documentation files (the "Software"), to deal
12
- in the Software without restriction, including without limitation the rights
13
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
- copies of the Software, and to permit persons to whom the Software is
15
- furnished to do so, subject to the following conditions:
16
-
17
- The above copyright notice and this permission notice shall be included in
18
- all copies or substantial portions of the Software.
19
-
20
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
- THE SOFTWARE.
27
-
28
- ---------------------------------------------------------------------------*/
29
- Object.defineProperty(exports, "__esModule", { value: true });
30
- exports.Format = void 0;
31
- /** Shared string formats used by the TypeCompiler and Value modules */
32
- var Format;
33
- (function (Format) {
34
- const formats = new Map();
35
- /** Clears all formats */
36
- function Clear() {
37
- return formats.clear();
38
- }
39
- Format.Clear = Clear;
40
- /** Returns true if the string format exists */
41
- function Has(format) {
42
- return formats.has(format);
43
- }
44
- Format.Has = Has;
45
- /** Sets a string format validation function */
46
- function Set(format, func) {
47
- formats.set(format, func);
48
- }
49
- Format.Set = Set;
50
- /** Gets a string format validation function */
51
- function Get(format) {
52
- return formats.get(format);
53
- }
54
- Format.Get = Get;
55
- })(Format = exports.Format || (exports.Format = {}));
1
+ "use strict";
2
+ /*--------------------------------------------------------------------------
3
+
4
+ @sinclair/typebox/format
5
+
6
+ The MIT License (MIT)
7
+
8
+ Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
+
10
+ Permission is hereby granted, free of charge, to any person obtaining a copy
11
+ of this software and associated documentation files (the "Software"), to deal
12
+ in the Software without restriction, including without limitation the rights
13
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
+ copies of the Software, and to permit persons to whom the Software is
15
+ furnished to do so, subject to the following conditions:
16
+
17
+ The above copyright notice and this permission notice shall be included in
18
+ all copies or substantial portions of the Software.
19
+
20
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
+ THE SOFTWARE.
27
+
28
+ ---------------------------------------------------------------------------*/
29
+ Object.defineProperty(exports, "__esModule", { value: true });
30
+ exports.Format = void 0;
31
+ /** Shared string formats used by the TypeCompiler and Value modules */
32
+ var Format;
33
+ (function (Format) {
34
+ const formats = new Map();
35
+ /** Clears all formats */
36
+ function Clear() {
37
+ return formats.clear();
38
+ }
39
+ Format.Clear = Clear;
40
+ /** Returns true if the string format exists */
41
+ function Has(format) {
42
+ return formats.has(format);
43
+ }
44
+ Format.Has = Has;
45
+ /** Sets a string format validation function */
46
+ function Set(format, func) {
47
+ formats.set(format, func);
48
+ }
49
+ Format.Set = Set;
50
+ /** Gets a string format validation function */
51
+ function Get(format) {
52
+ return formats.get(format);
53
+ }
54
+ Format.Get = Get;
55
+ })(Format = exports.Format || (exports.Format = {}));
package/format/index.d.ts CHANGED
@@ -1 +1 @@
1
- export * from './format';
1
+ export * from './format';
package/format/index.js CHANGED
@@ -1,44 +1,44 @@
1
- "use strict";
2
- /*--------------------------------------------------------------------------
3
-
4
- @sinclair/typebox/format
5
-
6
- The MIT License (MIT)
7
-
8
- Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
-
10
- Permission is hereby granted, free of charge, to any person obtaining a copy
11
- of this software and associated documentation files (the "Software"), to deal
12
- in the Software without restriction, including without limitation the rights
13
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
- copies of the Software, and to permit persons to whom the Software is
15
- furnished to do so, subject to the following conditions:
16
-
17
- The above copyright notice and this permission notice shall be included in
18
- all copies or substantial portions of the Software.
19
-
20
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
- THE SOFTWARE.
27
-
28
- ---------------------------------------------------------------------------*/
29
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
30
- if (k2 === undefined) k2 = k;
31
- var desc = Object.getOwnPropertyDescriptor(m, k);
32
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
33
- desc = { enumerable: true, get: function() { return m[k]; } };
34
- }
35
- Object.defineProperty(o, k2, desc);
36
- }) : (function(o, m, k, k2) {
37
- if (k2 === undefined) k2 = k;
38
- o[k2] = m[k];
39
- }));
40
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
41
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
42
- };
43
- Object.defineProperty(exports, "__esModule", { value: true });
44
- __exportStar(require("./format"), exports);
1
+ "use strict";
2
+ /*--------------------------------------------------------------------------
3
+
4
+ @sinclair/typebox/format
5
+
6
+ The MIT License (MIT)
7
+
8
+ Copyright (c) 2022 Haydn Paterson (sinclair) <haydn.developer@gmail.com>
9
+
10
+ Permission is hereby granted, free of charge, to any person obtaining a copy
11
+ of this software and associated documentation files (the "Software"), to deal
12
+ in the Software without restriction, including without limitation the rights
13
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
+ copies of the Software, and to permit persons to whom the Software is
15
+ furnished to do so, subject to the following conditions:
16
+
17
+ The above copyright notice and this permission notice shall be included in
18
+ all copies or substantial portions of the Software.
19
+
20
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26
+ THE SOFTWARE.
27
+
28
+ ---------------------------------------------------------------------------*/
29
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
30
+ if (k2 === undefined) k2 = k;
31
+ var desc = Object.getOwnPropertyDescriptor(m, k);
32
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
33
+ desc = { enumerable: true, get: function() { return m[k]; } };
34
+ }
35
+ Object.defineProperty(o, k2, desc);
36
+ }) : (function(o, m, k, k2) {
37
+ if (k2 === undefined) k2 = k;
38
+ o[k2] = m[k];
39
+ }));
40
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
41
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
42
+ };
43
+ Object.defineProperty(exports, "__esModule", { value: true });
44
+ __exportStar(require("./format"), exports);
package/guard/guard.d.ts CHANGED
@@ -1,56 +1,56 @@
1
- import * as Types from '../typebox';
2
- export declare class TypeGuardInvalidTypeError extends Error {
3
- readonly schema: unknown;
4
- constructor(schema: unknown);
5
- }
6
- /** TypeGuard tests that values conform to a known TypeBox type specification */
7
- export declare namespace TypeGuard {
8
- /** Returns true if the given schema is TAny */
9
- function TAny(schema: unknown): schema is Types.TAny;
10
- /** Returns true if the given schema is TArray */
11
- function TArray(schema: unknown): schema is Types.TArray;
12
- /** Returns true if the given schema is TBoolean */
13
- function TBoolean(schema: unknown): schema is Types.TBoolean;
14
- /** Returns true if the given schema is TConstructor */
15
- function TConstructor(schema: unknown): schema is Types.TConstructor;
16
- /** Returns true if the given schema is TFunction */
17
- function TFunction(schema: unknown): schema is Types.TFunction;
18
- /** Returns true if the given schema is TInteger */
19
- function TInteger(schema: unknown): schema is Types.TInteger;
20
- /** Returns true if the given schema is TLiteral */
21
- function TLiteral(schema: unknown): schema is Types.TLiteral;
22
- /** Returns true if the given schema is TNever */
23
- function TNever(schema: unknown): schema is Types.TNever;
24
- /** Returns true if the given schema is TNull */
25
- function TNull(schema: unknown): schema is Types.TNull;
26
- /** Returns true if the given schema is TNumber */
27
- function TNumber(schema: unknown): schema is Types.TNumber;
28
- /** Returns true if the given schema is TObject */
29
- function TObject(schema: unknown): schema is Types.TObject;
30
- /** Returns true if the given schema is TPromise */
31
- function TPromise(schema: unknown): schema is Types.TPromise;
32
- /** Returns true if the given schema is TRecord */
33
- function TRecord(schema: unknown): schema is Types.TRecord;
34
- /** Returns true if the given schema is TSelf */
35
- function TSelf(schema: unknown): schema is Types.TSelf;
36
- /** Returns true if the given schema is TRef */
37
- function TRef(schema: unknown): schema is Types.TRef;
38
- /** Returns true if the given schema is TString */
39
- function TString(schema: unknown): schema is Types.TString;
40
- /** Returns true if the given schema is TTuple */
41
- function TTuple(schema: unknown): schema is Types.TTuple;
42
- /** Returns true if the given schema is TUndefined */
43
- function TUndefined(schema: unknown): schema is Types.TUndefined;
44
- /** Returns true if the given schema is TUnion */
45
- function TUnion(schema: unknown): schema is Types.TUnion;
46
- /** Returns true if the given schema is TUint8Array */
47
- function TUint8Array(schema: unknown): schema is Types.TUint8Array;
48
- /** Returns true if the given schema is TUnknown */
49
- function TUnknown(schema: unknown): schema is Types.TUnknown;
50
- /** Returns true if the given schema is TVoid */
51
- function TVoid(schema: unknown): schema is Types.TVoid;
52
- /** Returns true if the given schema is TSchema */
53
- function TSchema(schema: unknown): schema is Types.TSchema;
54
- /** Asserts if this schema and associated references are valid. */
55
- function Assert<T extends Types.TSchema>(schema: T, references?: Types.TSchema[]): void;
56
- }
1
+ import * as Types from '../typebox';
2
+ export declare class TypeGuardInvalidTypeError extends Error {
3
+ readonly schema: unknown;
4
+ constructor(schema: unknown);
5
+ }
6
+ /** TypeGuard tests that values conform to a known TypeBox type specification */
7
+ export declare namespace TypeGuard {
8
+ /** Returns true if the given schema is TAny */
9
+ function TAny(schema: unknown): schema is Types.TAny;
10
+ /** Returns true if the given schema is TArray */
11
+ function TArray(schema: unknown): schema is Types.TArray;
12
+ /** Returns true if the given schema is TBoolean */
13
+ function TBoolean(schema: unknown): schema is Types.TBoolean;
14
+ /** Returns true if the given schema is TConstructor */
15
+ function TConstructor(schema: unknown): schema is Types.TConstructor;
16
+ /** Returns true if the given schema is TFunction */
17
+ function TFunction(schema: unknown): schema is Types.TFunction;
18
+ /** Returns true if the given schema is TInteger */
19
+ function TInteger(schema: unknown): schema is Types.TInteger;
20
+ /** Returns true if the given schema is TLiteral */
21
+ function TLiteral(schema: unknown): schema is Types.TLiteral;
22
+ /** Returns true if the given schema is TNever */
23
+ function TNever(schema: unknown): schema is Types.TNever;
24
+ /** Returns true if the given schema is TNull */
25
+ function TNull(schema: unknown): schema is Types.TNull;
26
+ /** Returns true if the given schema is TNumber */
27
+ function TNumber(schema: unknown): schema is Types.TNumber;
28
+ /** Returns true if the given schema is TObject */
29
+ function TObject(schema: unknown): schema is Types.TObject;
30
+ /** Returns true if the given schema is TPromise */
31
+ function TPromise(schema: unknown): schema is Types.TPromise;
32
+ /** Returns true if the given schema is TRecord */
33
+ function TRecord(schema: unknown): schema is Types.TRecord;
34
+ /** Returns true if the given schema is TSelf */
35
+ function TSelf(schema: unknown): schema is Types.TSelf;
36
+ /** Returns true if the given schema is TRef */
37
+ function TRef(schema: unknown): schema is Types.TRef;
38
+ /** Returns true if the given schema is TString */
39
+ function TString(schema: unknown): schema is Types.TString;
40
+ /** Returns true if the given schema is TTuple */
41
+ function TTuple(schema: unknown): schema is Types.TTuple;
42
+ /** Returns true if the given schema is TUndefined */
43
+ function TUndefined(schema: unknown): schema is Types.TUndefined;
44
+ /** Returns true if the given schema is TUnion */
45
+ function TUnion(schema: unknown): schema is Types.TUnion;
46
+ /** Returns true if the given schema is TUint8Array */
47
+ function TUint8Array(schema: unknown): schema is Types.TUint8Array;
48
+ /** Returns true if the given schema is TUnknown */
49
+ function TUnknown(schema: unknown): schema is Types.TUnknown;
50
+ /** Returns true if the given schema is TVoid */
51
+ function TVoid(schema: unknown): schema is Types.TVoid;
52
+ /** Returns true if the given schema is TSchema */
53
+ function TSchema(schema: unknown): schema is Types.TSchema;
54
+ /** Asserts if this schema and associated references are valid. */
55
+ function Assert<T extends Types.TSchema>(schema: T, references?: Types.TSchema[]): void;
56
+ }