/** * Extension SD Fetcher * * Fetches and caches Extension StructureDefinitions from remote registries. * This enables HAPI-level validation of extensions by loading their SDs. * * Key Features: * - Fetch Extension SDs from packages.fhir.org * - Cache with configurable TTL * - Support for multiple registries * - Fallback behavior for unavailable SDs */ import type { StructureDefinition } from '../core/structure-definition-types'; export interface ExtensionSDCache { sd: StructureDefinition | null; fetchedAt: number; error?: string; } export interface FetcherConfig { /** Registry URLs to try */ registries: string[]; /** TTL for cached entries in ms */ cacheTtlMs: number; /** Timeout for fetch requests */ timeoutMs: number; /** Whether to fetch remote SDs */ enableRemoteFetch: boolean; } export declare class ExtensionSDFetcher { private cache; private config; private inFlightRequests; constructor(config?: Partial); /** * Fetch an extension StructureDefinition by URL */ fetch(extensionUrl: string): Promise; /** * Try fetching from multiple registries */ private fetchFromRegistries; /** * Fetch from a specific registry */ private fetchFromRegistry; /** * Extract package info from extension URL */ private extractPackageInfo; /** * Preload common extensions */ preloadCommon(): Promise; /** * Clear cache */ clearCache(): void; /** * Get cache stats */ getCacheStats(): { size: number; hitRate: number; }; } export declare const extensionSDFetcher: ExtensionSDFetcher; //# sourceMappingURL=extension-sd-fetcher.d.ts.map