@atomic-ehr/fhirpath 0.0.4 → 0.0.5-canary.20260203152749.7038489

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- import { F as FHIRModelProviderBase, R as Resource } from './model-provider.common-oir-zg7r.js';
2
- export { q as ASTMetadata, i as ASTNode, h as AnalysisResult, A as Analyzer, N as AnyCursorNode, w as CompletionItem, C as CompletionKind, x as CompletionOptions, J as CursorArgumentNode, y as CursorContext, H as CursorIdentifierNode, K as CursorIndexNode, B as CursorNode, G as CursorOperatorNode, L as CursorTypeNode, f as Diagnostic, D as DiagnosticSeverity, u as ErrorCodes, t as Errors, E as EvaluateOptions, l as EvaluationResult, a as FHIRModelContext, s as FHIRPathError, k as FunctionDefinition, n as InspectOptions, o as InspectResult, I as Interpreter, M as ModelTypeProvider, O as OperatorDefinition, d as ParseResult, P as Parser, c as Registry, T as TypeInfo, j as TypeName, b as analyze, e as evaluate, g as getVersion, m as inspect, z as isCursorNode, p as parse, v as provideCompletions, r as registry } from './model-provider.common-oir-zg7r.js';
1
+ import { F as FHIRModelProviderBase, R as Resource } from './model-provider.common-CKU_9JxK.js';
2
+ export { q as ASTMetadata, i as ASTNode, h as AnalysisResult, A as Analyzer, N as AnyCursorNode, w as CompletionItem, C as CompletionKind, x as CompletionOptions, J as CursorArgumentNode, y as CursorContext, H as CursorIdentifierNode, K as CursorIndexNode, B as CursorNode, G as CursorOperatorNode, L as CursorTypeNode, f as Diagnostic, D as DiagnosticSeverity, u as ErrorCodes, t as Errors, E as EvaluateOptions, l as EvaluationResult, a as FHIRModelContext, s as FHIRPathError, k as FunctionDefinition, n as InspectOptions, o as InspectResult, I as Interpreter, M as ModelTypeProvider, O as OperatorDefinition, d as ParseResult, P as Parser, c as Registry, T as TypeInfo, j as TypeName, b as analyze, e as evaluate, g as getVersion, m as inspect, z as isCursorNode, p as parse, v as provideCompletions, r as registry } from './model-provider.common-CKU_9JxK.js';
3
3
  import '@atomic-ehr/fhirschema';
4
4
 
5
- type Resolver = (canonicalUrl: string) => Promise<Resource | null>;
5
+ type Resolver = (typeName: string) => Promise<Resource | null>;
6
6
  type Searcher = (kind: 'primitive-type' | 'complex-type' | 'resource') => Promise<Resource[]>;
7
7
  type Options = {
8
8
  resolve: Resolver;
@@ -11,7 +11,7 @@ type Options = {
11
11
  declare class FHIRModelProvider extends FHIRModelProviderBase {
12
12
  private _resolve;
13
13
  private _search;
14
- resolve(canonicalUrl: string): Promise<Resource | null>;
14
+ resolve(typeName: string): Promise<Resource | null>;
15
15
  search(params: {
16
16
  kind: 'primitive-type' | 'complex-type' | 'resource';
17
17
  }): Promise<Resource[]>;
@@ -15264,7 +15264,7 @@ async function analyze(expression, options = {}) {
15264
15264
  return analysisResult;
15265
15265
  }
15266
15266
  function getVersion() {
15267
- return "0.0.4";
15267
+ return "0.0.5-canary.20260203152749.7038489";
15268
15268
  }
15269
15269
  var FHIRModelProviderBase = class _FHIRModelProviderBase {
15270
15270
  constructor() {
@@ -15346,23 +15346,19 @@ var FHIRModelProviderBase = class _FHIRModelProviderBase {
15346
15346
  this.initialized = true;
15347
15347
  }
15348
15348
  }
15349
- async resolve(_canonicalUrl) {
15349
+ async resolve(_typeName) {
15350
15350
  throw new Error("Resolve not implemented.");
15351
15351
  }
15352
15352
  async search(_params) {
15353
15353
  throw new Error("Search not implemented.");
15354
15354
  }
15355
- buildCanonicalUrl(typeName) {
15356
- return `http://hl7.org/fhir/StructureDefinition/${typeName}`;
15357
- }
15358
15355
  // Public method to get schema with automatic caching
15359
15356
  async getSchema(typeName) {
15360
15357
  if (this.schemaCache.has(typeName)) {
15361
15358
  return this.schemaCache.get(typeName);
15362
15359
  }
15363
15360
  try {
15364
- const canonicalUrl = this.buildCanonicalUrl(typeName);
15365
- const resource = await this.resolve(canonicalUrl);
15361
+ const resource = await this.resolve(typeName);
15366
15362
  if (!resource || resource.resourceType !== "StructureDefinition") {
15367
15363
  return void 0;
15368
15364
  }
@@ -15736,8 +15732,8 @@ var FHIRModelProviderBase = class _FHIRModelProviderBase {
15736
15732
 
15737
15733
  // src/model-provider.browser.ts
15738
15734
  var FHIRModelProvider = class extends FHIRModelProviderBase {
15739
- async resolve(canonicalUrl) {
15740
- return await this._resolve(canonicalUrl);
15735
+ async resolve(typeName) {
15736
+ return await this._resolve(typeName);
15741
15737
  }
15742
15738
  async search(params) {
15743
15739
  return await this._search(params.kind);