minotor
Version:
A lightweight client-side transit routing library.
21 lines (20 loc) • 759 B
TypeScript
import { Parser } from 'csv-parse';
export type Maybe<T> = T | undefined;
/**
* Generates a simple hash from an array of numeric IDs.
*
* This function computes a hash for a given array of numbers by iterating over each
* ID and applying bitwise operations to accumulate a hash value.
* The final hash is then converted to a base-36 string.
*
* @param ids - The array of numeric IDs to hash.
* @returns A hashed string representation of the input array.
*/
export declare const hashIds: (ids: number[]) => string;
/**
* Parses a CSV stream with a sensible configuration for GTFS feeds.
*
* @param stream The CSV stream.
* @returns A parser from the csv-parse library.
*/
export declare const parseCsv: (stream: NodeJS.ReadableStream) => Parser;