Class Program
FHIR CodeGen CLI.
Inheritance
Namespace: FhirCodegenCli
Assembly: fhir-codegen-cli.dll
Syntax
public static class Program : object
Methods
| Improve this Doc View SourceFindRelativeDir(String, String, String, Boolean)
Searches for the FHIR specification directory.
Declaration
public static string FindRelativeDir(string startingDir, string dirName, string directoryType, bool thowIfNotFound = true)
Parameters
Type | Name | Description |
---|---|---|
System. |
startingDir | The starting dir. |
System. |
dirName | The name of the directory we are searching for. |
System. |
directoryType | The directory type (error hint). |
System. |
thowIfNotFound | (Optional) True to thow if not found. |
Returns
Type | Description |
---|---|
System. |
The found FHIR directory. |
Main(String[])
Main entry-point for this application.
Declaration
public static async Task<int> Main(string[] args)
Parameters
Type | Name | Description |
---|---|---|
System. |
args | An array of command-line argument strings. |
Returns
Type | Description |
---|---|
Task<System. |
An asynchronous result that yields exit-code for the process - 0 for success, else an error code. |
ParseHttpHeaders(String)
Parse HTTP headers.
Declaration
public static Dictionary<string, IEnumerable<string>> ParseHttpHeaders(string headersArg)
Parameters
Type | Name | Description |
---|---|---|
System. |
headersArg | The headers argument. |
Returns
Type | Description |
---|---|
Dictionary<System. |
A Dictionary<string,IEnumerable<string>>. |
Process(String, Boolean, Boolean, String, String, String, String, String, String, String, String, Boolean, String, String, Boolean, Boolean, String, String, Boolean, String, String, String, String, Boolean)
Command-line utility for processing the FHIR specification into other computer languages.
Declaration
public static int Process(string outputPath = "", bool verbose = false, bool offlineMode = false, string language = "", string exportKeys = "", string loadR2 = "", string loadR3 = "", string loadR4 = "", string loadR4B = "", string loadR5 = "", string languageOptions = "", bool officialExpansionsOnly = false, string fhirServerUrl = "", string fhirServerHeaders = "", bool resolveExternal = true, bool includeExperimental = false, string exportTypes = "", string extensionSupport = "", bool languageHelp = false, string packageDirectory = "", string packages = "", string ciBranch = "", string languageInputDir = "", bool showHelp = false)
Parameters
Type | Name | Description |
---|---|---|
System. |
outputPath | File or directory to write output. |
System. |
verbose | Show verbose output. |
System. |
offlineMode | Offline mode (will not download missing specs). |
System. |
language |
Info|TypeScript|CSharpBasic). |
System. |
exportKeys | '|' separated list of items to export (not present to export everything). |
System. |
loadR2 |
or latest). |
System. |
loadR3 |
or latest). |
System. |
loadR4 |
or latest). |
System. |
loadR4B |
or latest). |
System. |
loadR5 |
or latest). |
System. |
languageOptions | Language specific options, see documentation for more details. Example: Lang1|opt=a|opt2=b|Lang2|opt=tt|opt3=oo. |
System. |
officialExpansionsOnly | True to restrict value-sets exported to only official expansions (default: false). |
System. |
fhirServerUrl | FHIR Server URL to pull a CapabilityStatement (or Conformance) from. Requires application/fhir+json. |
System. |
fhirServerHeaders | Headers to include when calling a FHIR server, format is key=value|key=value|... |
System. |
resolveExternal | Whether or not to try to resolve unknown canonicals at the given fhir server url. |
System. |
includeExperimental | If the output should include structures marked experimental (false|true). |
System. |
exportTypes | Which FHIR classes types to export (primitive|complex|resource|interaction|enum), default is all. |
System. |
extensionSupport | The level of extensions to include (none|official|officialNonPrimitive|nonPrimitive|all), default is nonPrimitive. |
System. |
languageHelp | Display languages and their options. |
System. |
packageDirectory | The full path to a local directory for FHIR packages; e.g., profiles. (.../fhirPackages)). |
System. |
packages |
(e.g., hl7.fhir.r4.core#4.0.1, hl7.fhir.us.core#latest). |
System. |
ciBranch | If loading from the CI server, the name of the branch to use. |
System. |
languageInputDir | The full path to a local directory to pass additional content to languages. |
System. |
showHelp | Show command-line help. |
Returns
Type | Description |
---|---|
System. |
Exit-code for the process - 0 for success, else an error code. |