HS.FHIR.DTL.Utils
class HS.FHIR.DTL.Utils extends Ens.Util.FunctionSet
Method Inventory
- CPIsDefined()
- CTIsDefined()
- CreateUUID()
- FHIRDate()
- FHIRDateTime()
- FHIRInstant()
- FromSDAReferenceRange()
- GetCodeForURI()
- GetDiagnosticOrderId()
- GetEncounterResourceId()
- GetFHIRCodeOrDesc()
- GetFHIRDescOrCode()
- GetFrequency()
- GetMedicationAdministrationPosition()
- GetMedicationOrderResourceId()
- GetPatientResourceId()
- GetResourceId()
- GetResultId()
- GetResultItemId()
- GetSDACodeOrDesc()
- GetSDADescOrCode()
- GetSDAEncounterNumber()
- GetTimingCodeSystem()
- GetTimingCodes()
- GetURIForCode()
- GetURLForCode()
- GetUnitCodesAndDescs()
- GetWhenCodes()
- HCFIsDefined()
- IsNumeric()
- LookupFHIR()
- NormalizeTimeStamp()
- OrgIsDefined()
- RDIsDefined()
- SplitSDATimestamp()
- StripLtGtEq()
Methods
CPIsDefined uses the IsDefined() method and other means
to check for the presence of data for the specified SDA
CareProvider property. IsDefined() allows an initial
check for data without swizzling (instantiating) a
property object that hasn't yet been swizzled.
CTIsDefined uses the IsDefined() method and other means
to check for the presence of data for the specified SDA
CodeTableTranslated property. IsDefined() allows an
initial check for data without swizzling (instantiating)
a property object that hasn't yet been swizzled.
classmethod CreateUUID() as %String
FHIRDate takes an SDA time stamp value and returns the
FHIR date format for that value. If the SDA time stamp
is invalid then blank value is returned. The time
portion of the SDA time stamp is not used.
FHIRDateTime takes an SDA time stamp value and returns the
FHIR dateTime format of that value. If the SDA time stamp
is invalid then blank value is returned. SDA time stamp
will not have a time zone on it and the value is assumed
to be in the local time zone. If the value comes in
suffixed with "Z" then that character is stripped.
FHIRInstant takes an SDA time stamp value and returns the
FHIR instant format of that value. If the SDA time stamp
is invalid then blank value is returned. SDA time stamp
will not have a time zone on it and the value is assumed
to be in the local time zone. If the value comes in
suffixed with "Z" then that character is stripped.
classmethod FromSDAReferenceRange(pNormalRange As %String, pUnit As %String) as HS.FHIR.vDSTU2.Model.Resource.Observation.ReferenceRange
FromSDAReferenceRange interprets the SDA ResultNormalRange string into
discrete "low" and "high" values and populates and returns a FHIR
ReferenceRange object. This method takes into account negative numbers
on both sides of the range, and takes into account the possibility of
dash, colon, or slash for delimiter.
GetCodeForURI looks up the table HS_Data.OIDMap to get
the IdentityCode for the specified URI.
classmethod GetDiagnosticOrderId(pSDAObj) as %String
GetDiagnosticOrderId returns the FHIR DiagnosticOrder
resource id that should be used for the specified SDA
LabOrder, RadOrder, or OtherOrder.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetEncounterResourceId(pSDAObj) as %String
GetEncounterResourceId returns the FHIR Encounter resource id
that was assigned to the specified SDA object.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetFHIRCodeOrDesc(pCodeableConcept As HS.FHIR.vDSTU2.Model.Base.CodeableConcept, pDefault As %String = "") as %String
GetFHIRCodeOrDesc is used to help with transforming a
FHIR CodeableConcept type property into an SDA String
type property.
For a given FHIR CodeableConcept object, return the first found of:
- First coding code
- First coding display
- text
- The specified default pDefault.
For a given FHIR CodeableConcept object, return the first found of:
- First coding code
- First coding display
- text
- The specified default pDefault.
classmethod GetFHIRDescOrCode(pCodeableConcept As HS.FHIR.vDSTU2.Model.Base.CodeableConcept, pDefault As %String = "") as %String
GetFHIRDescOrCode is used to help with transforming a
FHIR CodeableConcept type property into an SDA String
type property.
For a given FHIR CodeableConcept object, return the first found of:
- First coding display
- text
- First coding code
- The specified default pDefault.
For a given FHIR CodeableConcept object, return the first found of:
- First coding display
- text
- First coding code
- The specified default pDefault.
classmethod GetFrequency(pCode, pDesc) as %String
GetFrequency returns a delimited string containing the
following possible FHIR frequency-related values:
Piece 1 : code code value
Piece 2 : code display value
Piece 3 : code system (if standard code, then the coding system or value set URL)
Piece 4 : frequency value
Piece 5 : period value
Piece 6 : periodUnits value
Piece 7 : when value (a "when code", e.g., "AC" for "before food or meals")
classmethod GetMedicationAdministrationPosition(pSDAObj As HS.SDA3.Administration) as %String
GetMedicationAdministrationPosition returns the relative position
of the specified SDA MedicationAdministration object in the list
Administrations from a given SDA Medication.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetMedicationOrderResourceId(pSDAObj) as %String
GetMedicationOrderResourceId returns the FHIR MedicationOrder
resource id that was assigned to the specified SDA object.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetPatientResourceId(pSDAObj As HS.SDA3.Patient) as %String
GetPatientResourceId returns the FHIR Patient resource id
that was assigned to the specified SDA object.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetResourceId(pSDAObj As HS.SDA3.Patient) as %String
GetResourceId returns the FHIR resource id
that was assigned to the specified SDA object.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetResultId(pSDAObj As HS.SDA3.Result) as %String
GetResultId returns the FHIR Observation resource id that
should be used for the specified SDA Result.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetResultItemId(pSDAObj As HS.SDA3.Result, pIndex As %Integer) as %String
GetResultItemId returns the FHIR Observation resource id that
should be used for the specified SDA ResultItem. This method
expects the entire HS.SDA3.Result object to be passed in
because DTL does not allow something like
..GetResultItemId(source.Result.ResultItems.(k2)).
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetSDACodeOrDesc(pCodeTableTranslated As HS.SDA3.CodeTableTranslated, pDefault As %String = "") as %String
GetSDACodeOrDesc is used to help with transforming an
SDA CodeTableTranslated property into a FHIR string
or code type property.
For a given SDA CodeTableTranslated object, return the first found of:
- SDA Code
- SDA Description
- SDA OriginalText
- The specified default pDefault.
For a given SDA CodeTableTranslated object, return the first found of:
- SDA Code
- SDA Description
- SDA OriginalText
- The specified default pDefault.
classmethod GetSDADescOrCode(pCodeTableTranslated As HS.SDA3.CodeTableTranslated, pDefault As %String = "") as %String
GetSDADescOrCode is used to help with transforming an
SDA CodeTableTranslated property into a FHIR string
or code type property.
For a given SDA CodeTableTranslated object, return the first found of:
- SDA Description
- SDA OriginalText
- SDA Code
- The specified default pDefault.
For a given SDA CodeTableTranslated object, return the first found of:
- SDA Description
- SDA OriginalText
- SDA Code
- The specified default pDefault.
classmethod GetSDAEncounterNumber(pFHIRObj, pResourceId) as %String
GetDiagnosticOrderId returns the FHIR DiagnosticOrder
resource id that should be used for the specified SDA
LabOrder, RadOrder, or OtherOrder.
DEPRECATED: This method is deprecated as of HealthShare Core 15.03. FHIR DTLs should use the aux array instead.
classmethod GetTimingCodeSystem() as %String
classmethod GetTimingCodes(ByRef pCodes As %String)
Return an array of timing codes and the frequency data derived from them.
GetURIForCode looks up the table HS_Data.OIDMap to get the
URI (first found of URL or OID) for the specified IdentityCode.
GetURLForCode looks up the table HS_Data.OIDMap to get
the URL for the specified IdentityCode.
Return an array of possible unit codes that might be received in
the SDA data, each item pointing at the corresponding standard
unit code. Also return a long description of each of the standard
unit codes (e.g. s = second).
classmethod GetWhenCodes(ByRef pCodes As %String)
HCFIsDefined uses the IsDefined() method and other means
to check for the presence of data for the specified SDA
HealthCareFacility property. IsDefined() allows an initial
check for data without swizzling (instantiating) a
property object that hasn't yet been swizzled.
classmethod IsNumeric(pText, pStripLtGtEq) as %Boolean
IsNumeric checks pText to determine whether it is numeric
or not. "numeric" means it is an integer or decimal
number. If the pStripLtGtEq parameter is passed in with
a value of 1, then any leading less than, greater than
and/or equals sign is stripped from pText that is being
evaluated as numeric.
classmethod LookupFHIR(table As %String = "", value As %String = "", default As %String = "", defaultOnEmptyInput As %Integer = 0) as %String
LookupFHIR checks to see if there is a customized version
of the specified data lookup table. A customized version
is indicated by the presence a table with a name of the
specified name prefixed by "Local.". If a customized
version is found then it is used to do the lookup.
Otherwise the specified table is used to do the lookup.
NormalizeTimeStamp takes a FHIR date, dateTime or instant as input.
If the input is valid, it returns the value as an SDA3 time stamp,
with the date, time (if any) and time zone (if any) preserved as is.
If the input is invalid, then this method Throws an error.
Input:
pFHIRTime = FHIR date, dateTime or instant value.
pPrecision = Follows the stated behavior of HS.Types.TimeStamp #PRECISION parameter.
Input:
pFHIRTime = FHIR date, dateTime or instant value.
pPrecision = Follows the stated behavior of HS.Types.TimeStamp #PRECISION parameter.
OrgIsDefined uses the IsDefined() method and other means
to check for the presence of data for the specified SDA
Organization property. IsDefined() allows an initial
check for data without swizzling (instantiating) a
property object that hasn't yet been swizzled.
RDIsDefined uses the IsDefined() method and other means
to check for the presence of data for the specified SDA
ReferralDoctor property. IsDefined() allows an initial
check for data without swizzling (instantiating) a
property object that hasn't yet been swizzled.
classmethod SplitSDATimestamp(pSDATime As %String, ByRef pDT As %String = "", ByRef pTZ As %String = "") as %Status
Split an SDA timestamp that may include time zone offset into dt and tz components
classmethod StripLtGtEq(pText) as %String
StripLtGtEq strips leading less than, greater than
and/or equals sign from pText.
Inherited Members
Inherited Methods
- Contains()
- ConvertDateTime()
- CurrentDateTime()
- DoesNotContain()
- DoesNotIntersectList()
- DoesNotMatch()
- DoesNotStartWith()
- Exists()
- If()
- In()
- InFile()
- InFileColumn()
- IntersectsList()
- Length()
- Like()
- Lookup()
- Matches()
- Max()
- Min()
- Not()
- NotIn()
- NotInFile()
- NotLike()
- Pad()
- Piece()
- RegexMatch()
- ReplaceStr()
- Round()
- Rule()
- Schedule()
- StartsWith()
- Strip()
- SubString()
- ToLower()
- ToUpper()
- Translate()
- replace()