@brimdata/zealot
Advanced tools
Comparing version 0.0.15 to 0.0.16
import { Context } from "."; | ||
import * as zjson from "../zjson"; | ||
import { TypeArray } from "./types/type-array"; | ||
import { TypeMap } from "./types/type-map"; | ||
import { TypeField, TypeRecord } from "./types/type-record"; | ||
import { TypeSet } from "./types/type-set"; | ||
import { TypeUnion } from "./types/type-union"; | ||
import { ContainerType, SerializeTypeDefs, Type } from "./types/types"; | ||
@@ -23,4 +25,4 @@ import { Field } from "./values/field"; | ||
lookupTypeSet(type: Type): TypeSet; | ||
lookupTypeUnion(types: Type[]): Type; | ||
lookupTypeMap(keyType: Type, valType: Type): Type; | ||
lookupTypeUnion(types: Type[]): Type | TypeUnion; | ||
lookupTypeMap(keyType: Type, valType: Type): Type | TypeMap; | ||
lookupTypeAlias(name: string, type: Type): Type; | ||
@@ -27,0 +29,0 @@ alloc<T extends ContainerType>(key: string, type: T): T; |
@@ -61,1 +61,2 @@ export { ZedContext as Context } from "./context"; | ||
export * from "./utils"; | ||
export * from "./is-type"; |
@@ -132,1 +132,2 @@ "use strict"; | ||
__exportStar(require("./utils"), exports); | ||
__exportStar(require("./is-type"), exports); |
@@ -26,2 +26,2 @@ declare const primitives: { | ||
export declare type PrimitiveName = keyof typeof primitives; | ||
export declare type PrimitiveTypes = typeof primitives[PrimitiveName]; | ||
export declare type PrimitiveType = typeof primitives[PrimitiveName]; |
@@ -8,7 +8,7 @@ import { Field } from "../index"; | ||
import { TypeMap } from "./type-map"; | ||
import { PrimitiveTypes } from "./type-primitives"; | ||
import { PrimitiveType } from "./type-primitives"; | ||
import { TypeRecord } from "./type-record"; | ||
import { TypeSet } from "./type-set"; | ||
import { TypeUnion } from "./type-union"; | ||
export declare type ZedType = PrimitiveTypes | TypeRecord | TypeArray | TypeSet | TypeUnion | TypeMap | TypeAlias; | ||
export declare type ZedType = PrimitiveType | TypeRecord | TypeArray | TypeSet | TypeUnion | TypeMap | TypeAlias; | ||
export declare type SerializeTypeDefs = { | ||
@@ -19,2 +19,3 @@ [key: string]: zjson.Type; | ||
id?: string | number; | ||
name?: string; | ||
toString(): string; | ||
@@ -21,0 +22,0 @@ serialize(typedefs: SerializeTypeDefs): zjson.Type; |
import { Array, Primitive, Set, TypeAlias, TypeRecord } from "./index"; | ||
import { PrimitiveName, PrimitiveTypes } from "./types/type-primitives"; | ||
import { PrimitiveName, PrimitiveType } from "./types/type-primitives"; | ||
import { Type } from "./types/types"; | ||
@@ -21,3 +21,3 @@ import { BString } from "./values/bstring"; | ||
export declare function isFloat64(value: unknown): value is Float64; | ||
export declare function getPrimitiveType(name: PrimitiveName): PrimitiveTypes; | ||
export declare function getPrimitiveType(name: PrimitiveName): PrimitiveType; | ||
export declare function isPrimitive(value: unknown): value is Primitive; | ||
@@ -24,0 +24,0 @@ export declare function isPrimitiveName(name: string): name is PrimitiveName; |
{ | ||
"name": "@brimdata/zealot", | ||
"version": "0.0.15", | ||
"version": "0.0.16", | ||
"description": "The Javascript Client for Zed Lakes", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -61,1 +61,2 @@ export { ZedContext as Context } from "./context"; | ||
export * from "./utils"; | ||
export * from "./is-type"; |
@@ -51,2 +51,2 @@ import { TypeBool } from "./type-bool"; | ||
export type PrimitiveName = keyof typeof primitives; | ||
export type PrimitiveTypes = typeof primitives[PrimitiveName]; | ||
export type PrimitiveType = typeof primitives[PrimitiveName]; |
@@ -8,3 +8,3 @@ import { Field } from "../index"; | ||
import { TypeMap } from "./type-map"; | ||
import { PrimitiveTypes } from "./type-primitives"; | ||
import { PrimitiveType } from "./type-primitives"; | ||
import { TypeRecord } from "./type-record"; | ||
@@ -15,3 +15,3 @@ import { TypeSet } from "./type-set"; | ||
export type ZedType = | ||
| PrimitiveTypes | ||
| PrimitiveType | ||
| TypeRecord | ||
@@ -30,2 +30,3 @@ | TypeArray | ||
id?: string | number; | ||
name?: string; | ||
toString(): string; | ||
@@ -32,0 +33,0 @@ serialize(typedefs: SerializeTypeDefs): zjson.Type; |
@@ -15,3 +15,3 @@ import { | ||
PrimitiveName, | ||
PrimitiveTypes, | ||
PrimitiveType, | ||
} from "./types/type-primitives"; | ||
@@ -98,3 +98,3 @@ import { Type } from "./types/types"; | ||
export function getPrimitiveType(name: PrimitiveName) { | ||
return primitives[name] as PrimitiveTypes; | ||
return primitives[name] as PrimitiveType; | ||
} | ||
@@ -101,0 +101,0 @@ |
Sorry, the diff of this file is too big to display
1373665
300
40758