fhir_resource_type: Create fhir_resource_type object

View source: R/fhir_resource_type.R

fhir_resource_typeR Documentation

Create fhir_resource_type object

Description

This function creates an object of class fhir_resource_type. It checks the resource type against the list of resource types provided at https://hl7.org/FHIR/resourcelist.html, corrects wrong cases (which can be disabled with fix_capitalization = FALSE) and throws a warning if the resource cannot be found at hl7.org.

Usage

fhir_resource_type(string, fix_capitalization = TRUE)

Arguments

string

A length one character vector containing the resource type. Will usually be one of the official FHIR resource types listed at https://hl7.org/FHIR/resourcelist.html

fix_capitalization

Correct wrong capitalization for known resource types? E.g. patients -> Patients or medicationstatement -> MedicationStatement. Defaults to TRUE.

Value

An fhir_resource_type object

Examples

fhir_resource_type(string = "Patient")
fhir_resource_type(string = "medicationadministration")

POLAR-fhiR/fhircrackr documentation built on Dec. 24, 2024, 3:06 a.m.