HS.HC.FHIRSQL.Utils
class HS.HC.FHIRSQL.Utils extends %Library.RegisteredObject, HS.HC.FHIRSQL.Utils.Base
Property Inventory
- BaseClass
- BaseStructure
- ClassesToCompile
- CurrentResource
- DataIndexCleanup
- DelayDeleteIndex
- FHIRCore
- Global
- IndexIdx
- Map
- Now
- OnFile
- RepoInstance
- RepositoryId
- ResourceTable
- Specification
- Structure
- StructureArray
Method Inventory
Properties
property BaseClass as %Dictionary.ClassDefinition;
Property methods: BaseClassGet(), BaseClassGetObject(), BaseClassGetObjectId(), BaseClassGetSwizzled(), BaseClassIsValid(), BaseClassNewObject(), BaseClassSet(), BaseClassSetObject(), BaseClassSetObjectId(), BaseClassUnSwizzle()
property BaseStructure as %Dictionary.XDataDefinition;
Property methods: BaseStructureGet(), BaseStructureGetObject(), BaseStructureGetObjectId(), BaseStructureGetSwizzled(), BaseStructureIsValid(), BaseStructureNewObject(), BaseStructureSet(), BaseStructureSetObject(), BaseStructureSetObjectId(), BaseStructureUnSwizzle()
property ClassesToCompile as %String [ MultiDimensional ];
Property methods: ClassesToCompileDisplayToLogical(), ClassesToCompileGet(), ClassesToCompileIsValid(), ClassesToCompileLogicalToDisplay(), ClassesToCompileLogicalToOdbc(), ClassesToCompileNormalize(), ClassesToCompileSet()
property CurrentResource as %DynamicObject;
Property methods: CurrentResourceGet(), CurrentResourceGetObject(), CurrentResourceGetObjectId(), CurrentResourceGetSwizzled(), CurrentResourceIsValid(), CurrentResourceNewObject(), CurrentResourceSet(), CurrentResourceSetObject(), CurrentResourceSetObjectId(), CurrentResourceUnSwizzle()
property DataIndexCleanup as %String [ MultiDimensional ];
After removing an item from a persistent index, queue up entry to cleanup any remaining data
Array Value should be (Class,GlobalName)=$lb(PositionsToCleanup)
Property methods: DataIndexCleanupDisplayToLogical(), DataIndexCleanupGet(), DataIndexCleanupIsValid(), DataIndexCleanupLogicalToDisplay(), DataIndexCleanupLogicalToOdbc(), DataIndexCleanupNormalize(), DataIndexCleanupSet()
property DelayDeleteIndex as %String [ MultiDimensional ];
During cleanup we may determine that we are removing an index (the Extent index on child tables) track here so that they can be removed post-compile
DelayDeleteIndex(class,index)=$lb(global)
Property methods: DelayDeleteIndexDisplayToLogical(), DelayDeleteIndexGet(), DelayDeleteIndexIsValid(), DelayDeleteIndexLogicalToDisplay(), DelayDeleteIndexLogicalToOdbc(), DelayDeleteIndexNormalize(), DelayDeleteIndexSet()
property FHIRCore as %String;
Property methods: FHIRCoreDisplayToLogical(), FHIRCoreGet(), FHIRCoreIsValid(), FHIRCoreLogicalToDisplay(), FHIRCoreLogicalToOdbc(), FHIRCoreNormalize(), FHIRCoreSet()
property Global as %String;
Property methods: GlobalDisplayToLogical(), GlobalGet(), GlobalIsValid(), GlobalLogicalToDisplay(), GlobalLogicalToOdbc(), GlobalNormalize(), GlobalSet()
property IndexIdx as %Integer;
Property methods: IndexIdxDisplayToLogical(), IndexIdxGet(), IndexIdxIsValid(), IndexIdxLogicalToDisplay(), IndexIdxNormalize(), IndexIdxSet()
property Map as %String [ MultiDimensional ];
Property methods: MapDisplayToLogical(), MapGet(), MapIsValid(), MapLogicalToDisplay(), MapLogicalToOdbc(), MapNormalize(), MapSet()
property Now as %String [ MultiDimensional ];
Property methods: NowDisplayToLogical(), NowGet(), NowIsValid(), NowLogicalToDisplay(), NowLogicalToOdbc(), NowNormalize(), NowSet()
property OnFile as %DynamicObject;
Property methods: OnFileGet(), OnFileGetObject(), OnFileGetObjectId(), OnFileGetSwizzled(), OnFileIsValid(), OnFileNewObject(), OnFileSet(), OnFileSetObject(), OnFileSetObjectId(), OnFileUnSwizzle()
property RepoInstance as %ObjectHandle;
Hold the repo instance computed from the path
Property methods: RepoInstanceGet(), RepoInstanceIsValid(), RepoInstanceSet()
property RepositoryId as %Integer;
Hold the repository id, computed from the path
Property methods: RepositoryIdDisplayToLogical(), RepositoryIdGet(), RepositoryIdIsValid(), RepositoryIdLogicalToDisplay(), RepositoryIdNormalize(), RepositoryIdSet()
property ResourceTable as %String;
Property methods: ResourceTableDisplayToLogical(), ResourceTableGet(), ResourceTableIsValid(), ResourceTableLogicalToDisplay(), ResourceTableLogicalToOdbc(), ResourceTableNormalize(), ResourceTableSet()
property Specification as %DynamicObject;
Property methods: SpecificationGet(), SpecificationGetObject(), SpecificationGetObjectId(), SpecificationGetSwizzled(), SpecificationIsValid(), SpecificationNewObject(), SpecificationSet(), SpecificationSetObject(), SpecificationSetObjectId(), SpecificationUnSwizzle()
property Structure as %DynamicObject;
Current XDATA Structure object (retrieved from package.Base) during building of Base
Property methods: StructureGet(), StructureGetObject(), StructureGetObjectId(), StructureGetSwizzled(), StructureIsValid(), StructureNewObject(), StructureSet(), StructureSetObject(), StructureSetObjectId(), StructureUnSwizzle()
property StructureArray as %String [ MultiDimensional ];
Property methods: StructureArrayDisplayToLogical(), StructureArrayGet(), StructureArrayIsValid(), StructureArrayLogicalToDisplay(), StructureArrayLogicalToOdbc(), StructureArrayNormalize(), StructureArraySet()
Methods
method AddBitNext(pClassDefinition As %Dictionary.ClassDefinition)
Build logic to get the next id from the BitMap so that for each resource you can say Set id = ##class(schema.resourceType).BitNext(resourceType,lastID)
The resourceType might seem redundant but it's due to the logic being in schema.Base versus the actual resource class
The resourceType might seem redundant but it's due to the logic being in schema.Base versus the actual resource class
method AddIndex(pClass As %Dictionary.ClassDefinition, pPropertyName, pIndexType As %String, pIsSubTable As %Boolean = 0)
Adding a field index to the class (separate from the data Index)
classmethod BuildProjections(pRequest As %DynamicObject, pVerbose As %Boolean = 0, pRebuild As %Boolean = 0)
@API
Back-end api for processing the projection request.
@argument pRequest holds the projection request which could look like this
@argument pVerbose is only used for debugging the interface
@argument pRebuild boolean, forces a rebuild of the classes (used for upgrade call)
@argument pRequest holds the projection request which could look like this
{"fhirRepositoryId":1,"specificationId":2,"packageName":"A1","version":2,"status":"Active","id":1,"lastModified":"2024-03-07T18:50:45.31Z","specification":{"name":"DEMO-withindex","scanId":1,"description":"","resources":[{"resourceType":"Patient","columns":[{"name":"PatientIdentifierValue","type":"String","path":"Patient.identifier.value","index":false},{"name":"PatientPatientBirthPlaceValueAddressCity","type":"String","path":"Patient.extension.where(url = 'http://hl7.org/fhir/StructureDefinition/patient-birthPlace').valueAddress.city","index":false},{"name":"PatientPatientMothersMaidenNameValueString","type":"String","path":"Patient.extension.where(url = 'http://hl7.org/fhir/StructureDefinition/patient-mothersMaidenName').valueString","index":false},{"name":"PatientQualityAdjustedLifeYearsValueDecimal","type":"Number","path":"Patient.extension.where(url = 'http://synthetichealth.github.io/synthea/quality-adjusted-life-years').valueDecimal","index":false},{"name":"PatientTelecomValue","type":"String","path":"Patient.telecom.where(use = 'home').value","index":false},{"name":"PatientGender","type":"String","path":"Patient.gender","index":false}],"dataIndex":["PatientIdentifierValue","PatientTelecomValue","PatientPatientBirthPlaceValueAddressCity"]},{"resourceType":"ExplanationOfBenefit","columns":[{"name":"ExplanationOfBenefitStatus","type":"String","path":"ExplanationOfBenefit.status","index":false}]},{"resourceType":"Observation","columns":[{"name":"ObservationCategoryCodingCode","type":"String","path":"Observation.category.coding.code","index":false},{"name":"ObservationCategoryCodingDisplay","type":"String","path":"Observation.category.coding.display","index":false},{"name":"ObservationValueCodeableConceptCodingCode","type":"String","path":"Observation.valueCodeableConcept.coding.code","index":false},{"name":"ObservationValueCodeableConceptCodingDisplay","type":"String","path":"Observation.valueCodeableConcept.coding.display","index":false},{"name":"ObservationStatus","type":"String","path":"Observation.status","index":false}]}],"version":1,"scanStartDateTime":"2024-03-06T15:52:15Z","scanFHIRRepositoryName":"demo","id":2,"lastModified":"2024-03-07T21:17:43.99Z","packageName":"A1"},"system":"E4E1C944-DAF6-11EE-A181-BCD07467ABB4:usmbp16bourette:DEV","namespace":"HSSYS","repositoryURL":"/csp/healthshare/demo/fhir/r4"}
@argument pRebuild boolean, forces a rebuild of the classes (used for upgrade call)
method ProjectionIsValid(pRequest As %DynamicObject, pReply)
Before updating the classes ensure that the request is coming from the same system. Validate the structure, this should have happened
when saving the transform specification, but let's verify anyway.
Inherited Members
Inherited Methods
- %AddToSaveSet()
- %ClassIsLatestVersion()
- %ClassName()
- %ConstructClone()
- %DispatchClassMethod()
- %DispatchGetModified()
- %DispatchGetProperty()
- %DispatchMethod()
- %DispatchSetModified()
- %DispatchSetMultidimProperty()
- %DispatchSetProperty()
- %Extends()
- %GetParameter()
- %IsA()
- %IsModified()
- %New()
- %NormalizeObject()
- %ObjectModified()
- %OriginalNamespace()
- %PackageName()
- %RemoveFromSaveSet()
- %SerializeObject()
- %SetModified()
- %ValidateObject()
- FindInDynamicArray()
- GetLock()