UNPKG

@brimdata/zealot

Version:

The Javascript Client for Zed Lakes

60 lines (59 loc) 1.23 kB
/// <reference types="node" /> /// <reference types="styled-components" /> import * as zed from "./zed"; export declare type QueryFormat = "zjson" | "zng" | "ndjson" | "csv" | "json"; export declare type Order = "desc" | "asc"; export declare type Key = string[]; export interface Response<T> { kind: string; value: T; } export interface PoolLoadArgs { author: string; date?: number; body: string; data: NodeJS.ReadableStream; signal?: AbortSignal; } export interface PoolArgs { name: string; layout?: Layout; } export interface Layout { order: Order; keys: Key[]; } export interface Ts { sec: number; ns: number; } export interface Span { ts: Date; dur: number; } export interface PoolConfig { name: string; id: string; layout: Layout; ts: Date; } export interface PoolStats { size: number; span: Span | null; } export interface BranchConfig { name: string; id: string; parent: string; } export interface BranchMeta { pool: PoolConfig; branch: BranchConfig; } export declare type TypeDefs = { [name: string]: zed.Type; }; export declare type Collector = (vals: { rows: zed.Value[]; shapesMap: TypeDefs; }) => void;