Navigation
The tree navigation module contains the object representations of the tree-navigation category FHIRPath functions.
Children
Bases: FHIRPathFunction
Representation of the FHIRPath children()
function.
Source code in fhircraft/fhir/path/engine/navigation.py
evaluate(collection, create=False)
Returns a collection with all immediate child nodes of all items in the input collection.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
collection |
List[FHIRPathCollectionItem]
|
The input collection. |
required |
Returns:
Type | Description |
---|---|
List[FHIRPathCollectionItem]
|
List[FHIRPathCollectionItem]): The collection of child items. |
Source code in fhircraft/fhir/path/engine/navigation.py
Descendants
Bases: FHIRPathFunction
Representation of the FHIRPath descendants()
function.
Source code in fhircraft/fhir/path/engine/navigation.py
evaluate(collection, create=False)
Returns a collection with all descendant nodes of all items in the input collection. The result does not include the nodes in the input collection themselves.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
collection |
List[FHIRPathCollectionItem]
|
The input collection. |
required |
Returns:
Type | Description |
---|---|
List[FHIRPathCollectionItem]
|
List[FHIRPathCollectionItem]): The collection of descendant items. |
Note
This function is a shorthand for repeat(children())
.