/** * Utility pathing and routing service */ import { MonoTypeOperatorFunction, Observable } from 'rxjs'; import { Coords } from '../interfaces/coords.interface'; import { Entries, HashMap } from './types'; export declare enum LOG_LEVEL { 'LOG' = 0, 'ERROR' = 1 } export declare let __DEV__: boolean; export declare let __LOG__: LOG_LEVEL; export declare function enableDiagramProdMode(): void; export declare function setLogLevel(level: LOG_LEVEL): void; export declare function isDev(): boolean; export declare function log(message: string, level?: LOG_LEVEL, ...args: any[]): void; /** * rxjs log operator * @internal */ export declare function withLog(message: string, level?: LOG_LEVEL, ...args: any): (source: Observable) => Observable; /** * rxjs entity properties operator * @internal */ export declare function entityProperty(destroyedNotifier: Observable, replayBy?: number, logMessage?: string): MonoTypeOperatorFunction; export declare type ID = string; /** * Generates a unique ID */ export declare function UID(): ID; export declare function isArray(val: any): val is T[]; export declare function isString(val: any): val is string; export declare function isFunction(val: any): val is (...args: any) => any; export declare function isNil(v: any): boolean; export declare function coerceArray(value: T | T[]): T[]; export declare function isEmptyArray(arr: T[]): boolean; export declare function mapToArray(map: HashMap): T[]; export declare function mapToEntries(map: HashMap): Entries; export declare function unique(arr: T[]): T[]; export declare function arrayToMap(arr: Array<{ id: ID; } & T>): HashMap; export declare function generateLinePath(firstPoint: any, lastPoint: any): string; export declare function generateCurvePath(firstPoint: Coords, lastPoint: Coords, curvy?: number): string; export declare function generateDynamicPath(pathCoords: number[][]): any;