structural

package
v1.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 1, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package structural provides structural validation of FHIR resources against StructureDefinitions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Validator

type Validator struct {
	// contains filtered or unexported fields
}

Validator performs structural validation of FHIR resources.

func New

func New(reg *registry.Registry) *Validator

New creates a new structural Validator.

func (*Validator) GetElementsChecked

func (v *Validator) GetElementsChecked() int

GetElementsChecked returns the number of elements that were checked. This is used for statistics.

func (*Validator) Validate

func (v *Validator) Validate(resource []byte, sd *registry.StructureDefinition) *issue.Result

Validate validates the structure of a FHIR resource against its StructureDefinition. Deprecated: Use ValidateData for better performance when JSON is already parsed.

func (*Validator) ValidateData

func (v *Validator) ValidateData(data map[string]any, sd *registry.StructureDefinition) *issue.Result

ValidateData validates the structure of a pre-parsed FHIR resource against its StructureDefinition. This is the preferred method when JSON has already been parsed to avoid redundant parsing.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL