digipinjs
Version:
A comprehensive TypeScript library for encoding and decoding Indian geographic coordinates into DIGIPIN format (Indian Postal Digital PIN system). Features CLI tools, caching, batch processing, and Express middleware for seamless integration.
15 lines • 845 B
TypeScript
import type { DigiPinFormat } from './core';
export type Coordinates = {
latitude: number;
longitude: number;
};
export declare function getCachedEncode(lat: number, lng: number, format: DigiPinFormat): string | undefined;
export declare function setCachedEncode(lat: number, lng: number, pin: string, format: DigiPinFormat): void;
export declare function getCachedDecode(pin: string): Coordinates | undefined;
export declare function setCachedDecode(pin: string, coordinates: Coordinates): void;
export declare function getCached(lat: number, lng: number): string | undefined;
export declare function setCached(lat: number, lng: number, pin: string): void;
export declare function clearEncodeCache(): void;
export declare function clearDecodeCache(): void;
export declare function clearCache(): void;
//# sourceMappingURL=cache.d.ts.map