Skip to main content

HS.FHIRPath.Node

class HS.FHIRPath.Node extends %Library.RegisteredObject

This object is used during parsing and in the representation of the final parse tree. The property desriptions detail the internal usage. In the final parse tree, the valid types and values are:

Property Inventory

Method Inventory

Properties

property children as list of Node;
Terms for operator or function call arguments
Property methods: childrenBuildValueArray(), childrenCollectionToDisplay(), childrenCollectionToOdbc(), childrenDisplayToCollection(), childrenGet(), childrenGetObject(), childrenGetObjectId(), childrenGetSwizzled(), childrenIsValid(), childrenOdbcToCollection(), childrenSet(), childrenSetObject(), childrenSetObjectId()
property context as Node;
The input context for the node (empty = global)
Property methods: contextGet(), contextGetSwizzled(), contextIsValid(), contextNewObject(), contextSet()
property isUnary as %Boolean;
Indicates a Unary Operation
Property methods: isUnaryDisplayToLogical(), isUnaryGet(), isUnaryIsValid(), isUnaryLogicalToDisplay(), isUnaryNormalize(), isUnarySet()
property literalType as %String;
Indicates the type of literal (if type="LIT")
  • type="b" A boolean literal with a value of true or false
  • type="s" A string literal.
  • type="n" A numeric literal.
  • type="o" A null-object literal.
Property methods: literalTypeDisplayToLogical(), literalTypeGet(), literalTypeIsValid(), literalTypeLogicalToDisplay(), literalTypeLogicalToOdbc(), literalTypeNormalize(), literalTypeSet()
property name as %String;
The name of an identifier, operator, or function. Or the value of a literal.
Property methods: nameDisplayToLogical(), nameGet(), nameIsValid(), nameLogicalToDisplay(), nameLogicalToOdbc(), nameNormalize(), nameSet()
property type as %String;
The type of node
  • type="ID": An identifier. value = The name of a variable or FHIR type
  • type="OP": An identifier. value = The name of a variable or FHIR type
  • type="FN": An identifier. The 'name' property holds the function name. The 'context' property is a Node describing the input context for the function. The 'children' property is a list of Node's providing the arguments for the function
  • type="LIT": An identifier. Literal nodes hold the literal value in the 'name' property, and the literal type (boolean, string, number, object) in the 'literalType' property
  • type="Expr": An operator. value = the actual operator (e.g. '+').
Property methods: typeDisplayToLogical(), typeGet(), typeIsValid(), typeLogicalToDisplay(), typeLogicalToOdbc(), typeNormalize(), typeSet()

Methods

method %OnNew(type As %String, name As %String) as %Status
Inherited description: This callback method is invoked by the %New() method to provide notification that a new instance of an object is being created.

If this method returns an error then the object will not be created.

It is passed the arguments provided in the %New call. When customizing this method, override the arguments with whatever variables and types you expect to receive from %New(). For example, if you're going to call %New, passing 2 arguments, %OnNew's signature could be:

Method %OnNew(dob as %Date = "", name as %Name = "") as %Status If instead of returning a %Status code this returns an oref and this oref is a subclass of the current class then this oref will be the one returned to the caller of %New method.

classmethod Test(text As %String, debug=0)
method asString()
classmethod fromSerial(ser) as Node
method showNode(prefix As %String = "", recurse As %Boolean = 0)
method showTree()
method toSerial() as %List
Serialized Node tree. All elements in this chain are OR'd together in a query

Inherited Members

Inherited Methods

FeedbackOpens in a new tab