UNPKG

@seasketch/geoprocessing

Version:

Geoprocessing and reporting framework for SeaSketch 2.0

26 lines 795 B
import { jsonSchema } from "./base.js"; import { z } from "zod"; /** Dimensions used in Metric */ export const MetricDimensions = [ "metricId", "geographyId", "sketchId", "groupId", "classId", ]; export const metricSchema = z.object({ metricId: z.string(), value: z.number(), extra: z.record(jsonSchema).optional(), classId: z.string().nullable(), groupId: z.string().nullable(), geographyId: z.string().nullable(), sketchId: z.string().nullable(), // // Time // /** Metric duration of time */ // // duration: Nullable<ISO8601Duration>; // /** Metric for event at specific time */ // // startTime: Nullable<ISO8601DateTime>; }); export const metricsSchema = z.array(metricSchema); //# sourceMappingURL=metrics.js.map