diff --git a/_build.bat b/_build.bat new file mode 100644 index 0000000..903d207 --- /dev/null +++ b/_build.bat @@ -0,0 +1,387 @@ +@ECHO OFF +setlocal enabledelayedexpansion + +SET "dlurl=https://github.com/HL7/fhir-ig-publisher/releases/latest/download/publisher.jar" +SET "publisher_jar=publisher.jar" +SET "input_cache_path=%CD%\input-cache\" +SET "skipPrompts=false" +SET "upper_path=..\" +SET "scriptdlroot=https://raw.githubusercontent.com/HL7/ig-publisher-scripts/main" +SET "build_bat_url=%scriptdlroot%/_build.bat" +SET "build_sh_url=%scriptdlroot%/_build.sh" + + + +:: Debugging statements to check jar file location +ECHO Checking for publisher.jar in %input_cache_path% +IF EXIST "%input_cache_path%%publisher_jar%" ( + SET "jar_location=%input_cache_path%%publisher_jar%" + ECHO Found publisher.jar in input-cache +) ELSE ( + ECHO Checking for publisher.jar in %upper_path% + IF EXIST "%upper_path%%publisher_jar%" ( + SET "jar_location=%upper_path%%publisher_jar%" + ECHO Found publisher.jar in parent folder + ) ELSE ( + SET "jar_location=not_found" + SET "default_choice=1" + SET "default_reason=publisher not found" + ECHO publisher.jar not found in input-cache or parent folder + ) +) + + +:: Handle command-line argument to bypass the menu +:: Known first arguments select a menu option; anything else is passed through to the publisher +SET "extraArgs=" +IF "%~1"=="" GOTO showMenu +IF /I "%~1"=="update" SET "userChoice=1" & GOTO parseExtra +IF /I "%~1"=="build" SET "userChoice=2" & GOTO parseExtra +IF /I "%~1"=="nosushi" SET "userChoice=3" & GOTO parseExtra +IF /I "%~1"=="notx" SET "userChoice=4" & GOTO parseExtra +IF /I "%~1"=="jekyll" SET "userChoice=5" & GOTO parseExtra +IF /I "%~1"=="clean" SET "userChoice=6" & GOTO parseExtra +IF /I "%~1"=="exit" SET "userChoice=0" & GOTO parseExtra +:: Unknown first arg - default to build, pass all args through +SET "userChoice=2" +GOTO collectArgs +:parseExtra +SHIFT +:collectArgs +IF "%~1"=="" GOTO executeChoice +SET "extraArgs=!extraArgs! %1" +SHIFT +GOTO collectArgs +:showMenu + +echo --------------------------------------------------------------- +ECHO Checking internet connection... +powershell -Command "try { $r=[System.Net.WebRequest]::Create('https://tx.fhir.org/r4/metadata'); $r.Timeout=4000; $r.GetResponse().Close(); exit 0 } catch { exit 1 }" +IF %ERRORLEVEL% EQU 0 (SET "online_status=true") ELSE (SET "online_status=false") + +IF "%online_status%"=="true" ( + ECHO We are online and tx.fhir.org is available. + FOR /F "tokens=2 delims=:" %%a IN ('curl -s https://api.github.com/repos/HL7/fhir-ig-publisher/releases/latest ^| findstr "tag_name"') DO SET "latest_version=%%a" + SET "latest_version=!latest_version:"=!" + SET "latest_version=!latest_version: =!" + SET "latest_version=!latest_version:~0,-1!" +) ELSE ( + ECHO. + ECHO *** WARNING: Working offline - this is not the normal mode. + ECHO Some features including terminology rendering will not work. + ECHO. + SET "txoption=-tx n/a" + SET "latest_version=unknown" + SET "default_choice=4" + SET "default_reason=working offline" +) + +echo --------------------------------------------------------------- + + +IF NOT "%jar_location%"=="not_found" ( + FOR /F "tokens=*" %%i IN ('java "-Dfile.encoding=UTF-8" -jar "%jar_location%" -v 2^>^&1') DO SET "publisher_version=%%i" + SET "publisher_version=!publisher_version:"=!" + ECHO Detected publisher version: !publisher_version! +) ELSE ( + SET "publisher_version=unknown" + ECHO publisher.jar location is not found +) + +ECHO Publisher version: !publisher_version!; Latest is !latest_version! + +IF NOT "%online_status%"=="true" ( + ECHO We are offline. +) ELSE ( + IF NOT "!publisher_version!"=="!latest_version!" ( + ECHO An update is recommended. + SET "default_choice=1" + SET "default_reason=newer version available" + ) ELSE ( + ECHO Publisher is up to date. + SET "default_choice=2" + SET "default_reason=publisher is up to date" + ) +) + +echo --------------------------------------------------------------- +echo. + +echo Please select an option: +echo 1. Download or update publisher +echo 2. Build IG +echo 3. Build IG - no sushi +echo 4. Build IG - force no TX server +echo 5. Jekyll build +echo 6. Clean up temp directories +echo 0. Exit +echo. + +choice /C 12345670 /N /CS /D %default_choice% /T 5 /M "Choose an option number or wait 5 seconds for default (%default_choice% - %default_reason%):" +SET "userChoice=%ERRORLEVEL%" + + +:executeChoice +echo You selected: %userChoice% + +IF "%userChoice%"=="1" GOTO downloadpublisher +IF "%userChoice%"=="2" GOTO publish_once +IF "%userChoice%"=="3" GOTO publish_nosushi +IF "%userChoice%"=="4" GOTO publish_notx +IF "%userChoice%"=="5" GOTO debugjekyll +IF "%userChoice%"=="6" GOTO clean +IF "%userChoice%"=="0" EXIT /B +GOTO endscript + +:debugjekyll + echo Running Jekyll build... + jekyll build -s temp/pages -d output +GOTO endscript + + +:clean + echo Cleaning up directories... + if exist ".\input-cache\publisher.jar" ( + echo Preserving publisher.jar and removing other files in .\input-cache... + move ".\input-cache\publisher.jar" ".\" + rmdir /s /q ".\input-cache" + mkdir ".\input-cache" + move ".\publisher.jar" ".\input-cache" + ) else ( + if exist ".\input-cache\" ( + rmdir /s /q ".\input-cache" + ) + ) + if exist ".\temp\" ( + rmdir /s /q ".\temp" + echo Removed: .\temp + ) + if exist ".\output\" ( + rmdir /s /q ".\output" + echo Removed: .\output + ) + if exist ".\template\" ( + rmdir /s /q ".\template" + echo Removed: .\template + ) + +GOTO endscript + + +:downloadpublisher +ECHO Downloading Publisher... +:processflags +SET ARG=%1 +IF DEFINED ARG ( + IF "%ARG%"=="-f" SET FORCE=true + IF "%ARG%"=="--force" SET FORCE=true + SHIFT + GOTO processflags +) + +FOR %%x IN ("%CD%") DO SET upper_path=%%~dpx + +ECHO. +IF NOT EXIST "%input_cache_path%%publisher_jar%" ( + IF NOT EXIST "%upper_path%%publisher_jar%" ( + SET jarlocation="%input_cache_path%%publisher_jar%" + SET jarlocationname=Input Cache + ECHO IG Publisher is not yet in input-cache or parent folder. + REM we don't use jarlocation below because it will be empty because we're in a bracketed if statement + GOTO create + ) ELSE ( + ECHO IG Publisher FOUND in parent folder + SET jarlocation="%upper_path%%publisher_jar%" + SET jarlocationname=Parent folder + GOTO upgrade + ) +) ELSE ( + ECHO IG Publisher FOUND in input-cache + SET jarlocation="%input_cache_path%%publisher_jar%" + SET jarlocationname=Input Cache + GOTO upgrade +) + +:create +IF DEFINED FORCE ( + MKDIR "%input_cache_path%" 2> NUL + GOTO download +) + +IF "%skipPrompts%"=="true" ( + SET create=Y +) ELSE ( + SET /p create="Download? (Y/N) " +) +IF /I "%create%"=="Y" ( + ECHO Will place publisher jar here: %input_cache_path%%publisher_jar% + MKDIR "%input_cache_path%" 2> NUL + GOTO download +) +GOTO done + +:upgrade +IF "%skipPrompts%"=="true" ( + SET overwrite=Y +) ELSE ( + SET /p overwrite="Overwrite %jarlocation%? (Y/N) " +) + +IF /I "%overwrite%"=="Y" ( + GOTO download +) +GOTO done + +:download +ECHO Downloading most recent publisher to %jarlocationname% - it's ~200 MB, so this may take a bit + +FOR /f "tokens=4-5 delims=. " %%i IN ('ver') DO SET VERSION=%%i.%%j +IF "%version%" == "10.0" GOTO win10 +IF "%version%" == "6.3" GOTO win8.1 +IF "%version%" == "6.2" GOTO win8 +IF "%version%" == "6.1" GOTO win7 +IF "%version%" == "6.0" GOTO vista + +ECHO Unrecognized version: %version% +GOTO done + +:win10 +CALL POWERSHELL -command if ('System.Net.WebClient' -as [type]) {(new-object System.Net.WebClient).DownloadFile(\"%dlurl%\",\"%jarlocation%\") } else { Invoke-WebRequest -Uri "%dlurl%" -Outfile "%jarlocation%" } + +GOTO done + +:win7 +rem this may be triggering the antivirus - bitsadmin.exe is a known threat +rem CALL bitsadmin /transfer GetPublisher /download /priority normal "%dlurl%" "%jarlocation%" + +rem this didn't work in win 10 +rem CALL Start-BitsTransfer /priority normal "%dlurl%" "%jarlocation%" + +rem this should work - untested +call (New-Object Net.WebClient).DownloadFile('%dlurl%', '%jarlocation%') +GOTO done + +:win8.1 +:win8 +:vista +GOTO done + + + +:done + + + + +ECHO. +ECHO Updating scripts +IF "%skipPrompts%"=="true" ( + SET updateScripts=Y +) ELSE ( + SET /p updateScripts="Update scripts? (Y/N) " +) +IF /I "%updateScripts%"=="Y" ( + GOTO scripts +) +GOTO endscript + + +:scripts + +REM Download all batch files (and this one with a new name) + +SETLOCAL DisableDelayedExpansion + + + +:dl_script_1 +ECHO Updating _build.sh +call POWERSHELL -command if ('System.Net.WebClient' -as [type]) {(new-object System.Net.WebClient).DownloadFile(\"%build_sh_url%\",\"_build.new.sh\") } else { Invoke-WebRequest -Uri "%build_sh_url%" -Outfile "_build.new.sh" } +if %ERRORLEVEL% == 0 goto upd_script_1 +echo "Errors encountered during download: %errorlevel%" +goto dl_script_2 +:upd_script_1 +start copy /y "_build.new.sh" "_build.sh" ^&^& del "_build.new.sh" ^&^& exit + + +:dl_script_2 +ECHO Updating _build.bat +call POWERSHELL -command if ('System.Net.WebClient' -as [type]) {(new-object System.Net.WebClient).DownloadFile(\"%build_bat_url%\",\"_build.new.bat\") } else { Invoke-WebRequest -Uri "%build_bat_url%" -Outfile "_build.new.bat" } +if %ERRORLEVEL% == 0 goto upd_script_2 +echo "Errors encountered during download: %errorlevel%" +goto endscript +:upd_script_2 +start copy /y "_build.new.bat" "_build.bat" ^&^& del "_build.new.bat" ^&^& exit + + +GOTO endscript + + +:publish_once + +SET JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8 + +:: Debugging statements before running publisher +ECHO jar_location is: %jar_location% +IF NOT "%jar_location%"=="not_found" ( + ECHO IG Publisher FOUND, Publishing... + java %JAVA_OPTS% -jar "%jar_location%" -ig . %txoption% %extraArgs% +) ELSE ( + ECHO IG Publisher NOT FOUND in input-cache or parent folder. Please run the script and update the publisher. Aborting... +) + +GOTO endscript + + + +:publish_nosushi + +SET JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8 + +:: Debugging statements before running publisher +ECHO jar_location is: %jar_location% +IF NOT "%jar_location%"=="not_found" ( + java %JAVA_OPTS% -jar "%jar_location%" -ig . %txoption% -no-sushi %extraArgs% +) ELSE ( + ECHO IG Publisher NOT FOUND in input-cache or parent folder. Please run the script and update the publisher. Aborting... +) + +GOTO endscript + + +:publish_notx +SET txoption=-tx n/a + +SET JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8 + +:: Debugging statements before running publisher +ECHO jar_location is: %jar_location% +IF NOT "%jar_location%"=="not_found" ( + java %JAVA_OPTS% -jar "%jar_location%" -ig . %txoption% %extraArgs% +) ELSE ( + ECHO IG Publisher NOT FOUND in input-cache or parent folder. Please run the script and update the publisher. Aborting... +) + +GOTO endscript + + +:publish_continuous + +SET JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8 + +ECHO jar_location is: %jar_location% +IF NOT "%jar_location%"=="not_found" ( + java %JAVA_OPTS% -jar "%jar_location%" -ig . %txoption% -watch %extraArgs% +) ELSE ( + ECHO IG Publisher NOT FOUND in input-cache or parent folder. Please run the script and update the publisher. Aborting... +) + +GOTO endscript + + +:endscript + +:: Pausing at the end +IF NOT "%skipPrompts%"=="true" ( + PAUSE +) diff --git a/_build.sh b/_build.sh new file mode 100755 index 0000000..69ac585 --- /dev/null +++ b/_build.sh @@ -0,0 +1,220 @@ +#!/bin/bash + +set -e + +# Variables +dlurl="https://github.com/HL7/fhir-ig-publisher/releases/latest/download/publisher.jar" +publisher_jar="publisher.jar" +input_cache_path="$(pwd)/input-cache/" +skipPrompts=false +upper_path="../" +scriptdlroot="https://raw.githubusercontent.com/HL7/ig-publisher-scripts/main" +build_bat_url="${scriptdlroot}/_build.bat" +build_sh_url="${scriptdlroot}/_build.sh" + +function check_jar_location() { + if [ -f "${input_cache_path}${publisher_jar}" ]; then + jar_location="${input_cache_path}${publisher_jar}" + echo "Found publisher.jar in input-cache" + elif [ -f "${upper_path}${publisher_jar}" ]; then + jar_location="${upper_path}${publisher_jar}" + echo "Found publisher.jar in parent folder" + else + jar_location="not_found" + echo "publisher.jar not found in input-cache or parent folder" + fi +} + +function check_internet_connection() { + local target="tx.fhir.org" + local reachable=false + + if command -v ping > /dev/null 2>&1; then + if ping -c 1 -W 5 "$target" > /dev/null 2>&1 \ + || ping -c 1 -w 5 "$target" > /dev/null 2>&1; then + reachable=true + fi + elif command -v curl > /dev/null 2>&1; then + if curl --silent --max-time 5 --output /dev/null "https://$target"; then + reachable=true + fi + else + echo "WARNING: Neither ping nor curl available — assuming offline." + fi + + if [ "$reachable" = "true" ]; then + online=true + echo "We're online and $target is available." + latest_version=$(curl -s https://api.github.com/repos/HL7/fhir-ig-publisher/releases/latest | grep tag_name | cut -d'"' -f4) + else + online=false + echo "" + echo "⚠️ WARNING: Working offline — this is not the normal mode." + echo " Some features (e.g. terminology rendering) will not work." + echo "" + fi +} + + + +function update_publisher() { + echo "Publisher jar location: ${input_cache_path}${publisher_jar}" + if [ "$skipPrompts" = "true" ]; then + confirm="Y" + else + read -p "Download or update publisher.jar? (Y/N): " confirm + fi + if [[ "$confirm" =~ ^[Yy]$ ]]; then + echo "Downloading latest publisher.jar (~200 MB)..." + mkdir -p "$input_cache_path" + curl -L "$dlurl" -o "${input_cache_path}${publisher_jar}" + else + echo "Skipped downloading publisher.jar" + fi + + update_scripts_prompt +} + + +function update_scripts_prompt() { + if [ "$skipPrompts" = "true" ]; then + update_confirm="Y" + else + read -p "Update scripts (_build.bat and _build.sh)? (Y/N): " update_confirm + fi + if [[ "$update_confirm" =~ ^[Yy]$ ]]; then + echo "Updating scripts..." + curl -L "$build_bat_url" -o "_build.new.bat" && mv "_build.new.bat" "_build.bat" + curl -L "$build_sh_url" -o "_build.new.sh" && mv "_build.new.sh" "_build.sh" + chmod +x _build.sh + echo "Scripts updated." + else + echo "Skipped updating scripts." + fi +} + + +function run_publisher() { + local extra_flags=("$@") + if [ "$jar_location" != "not_found" ]; then + echo "jar_location is: $jar_location" + export JAVA_TOOL_OPTIONS="-Dfile.encoding=UTF-8" + java $JAVA_OPTS -jar "$jar_location" -ig . "${extra_flags[@]}" + else + echo "IG Publisher NOT FOUND in input-cache or parent folder. Please run update. Aborting..." + fi +} + +function build_ig() { + local args=() + if [ "$online" = "false" ]; then + args+=("-tx" "n/a") + fi + run_publisher "${args[@]}" "$@" +} + +function build_nosushi() { + run_publisher -no-sushi "$@" +} + +function build_notx() { + run_publisher -tx n/a "$@" +} + +function build_continuous() { + run_publisher -watch "$@" +} + +function jekyll_build() { + echo "Running Jekyll build..." + jekyll build -s temp/pages -d output +} + +function cleanup() { + echo "Cleaning up temp directories..." + if [ -f "${input_cache_path}${publisher_jar}" ]; then + mv "${input_cache_path}${publisher_jar}" ./ + rm -rf "${input_cache_path}"* + mkdir -p "$input_cache_path" + mv "$publisher_jar" "$input_cache_path" + fi + rm -rf ./output ./template ./temp + echo "Cleanup complete." +} + +check_jar_location + +# Handle command-line arguments +# Known first arguments select a menu option; anything else is passed through to the publisher +extraArgs=() +if [ $# -gt 0 ]; then + case "$1" in + update) shift; extraArgs=("$@"); update_publisher; exit 0 ;; + build) shift; extraArgs=("$@"); check_internet_connection; build_ig "${extraArgs[@]}"; exit 0 ;; + nosushi) shift; extraArgs=("$@"); check_internet_connection; build_nosushi "${extraArgs[@]}"; exit 0 ;; + notx) shift; extraArgs=("$@"); build_notx "${extraArgs[@]}"; exit 0 ;; + jekyll) jekyll_build; exit 0 ;; + clean) cleanup; exit 0 ;; + exit) exit 0 ;; + *) + # Unknown first arg - default to build, pass all args through + extraArgs=("$@") + run_publisher "${extraArgs[@]}" + exit 0 + ;; + esac +fi + +# Interactive menu +check_internet_connection + +# Compute default choice and reason +default_choice=2 +default_reason="publisher is up to date" + +if [ "$jar_location" = "not_found" ]; then + default_choice=1 + default_reason="publisher not found" +elif [ "$online" = "false" ]; then + default_choice=4 + default_reason="working offline" +elif [ -n "$latest_version" ]; then + current_version=$(java -jar "$jar_location" -v 2>/dev/null | tr -d '\r') + if [ "$current_version" != "$latest_version" ]; then + default_choice=1 + default_reason="newer version available" + fi +fi + +echo "---------------------------------------------" +echo "Publisher: ${current_version:-unknown}; Latest: ${latest_version:-unknown}" +echo "Publisher location: $jar_location" +echo "Online: $online" +echo "---------------------------------------------" +echo +echo "Please select an option:" +echo "1) Download or update publisher" +echo "2) Build IG" +echo "3) Build IG without Sushi" +echo "4) Build IG without TX server" +echo "5) Jekyll build" +echo "6) Cleanup temp directories" +echo "0) Exit" +echo + +# Read with timeout, but default if nothing entered +echo -n "Choose an option [default: $default_choice - $default_reason]: " +read -t 5 choice || choice="$default_choice" +choice="${choice:-$default_choice}" +echo "You selected: $choice" + +case "$choice" in + 1) update_publisher ;; + 2) build_ig ;; + 3) build_nosushi ;; + 4) build_notx ;; + 5) jekyll_build ;; + 6) cleanup ;; + 0) exit 0 ;; + *) echo "Invalid option." ;; +esac diff --git a/_updatePublisher.bat b/_updatePublisher.bat index 10fee38..d4e1b7d 100644 --- a/_updatePublisher.bat +++ b/_updatePublisher.bat @@ -22,7 +22,8 @@ IF "%~1"=="/f" SET skipPrompts=y ECHO. ECHO Checking internet connection... -PING tx.fhir.org -4 -n 1 -w 4000 | FINDSTR TTL && GOTO isonline +powershell -Command "try { $r=[System.Net.WebRequest]::Create('https://tx.fhir.org/r4/metadata'); $r.Timeout=4000; $r.GetResponse().Close(); exit 0 } catch { exit 1 }" +IF %ERRORLEVEL% EQU 0 GOTO isonline ECHO We're offline, nothing to do... GOTO end diff --git a/_updatePublisher.sh b/_updatePublisher.sh old mode 100644 new mode 100755 diff --git a/input/ignoreWarnings.txt b/input/ignoreWarnings.txt index 972eb79..3538348 100644 --- a/input/ignoreWarnings.txt +++ b/input/ignoreWarnings.txt @@ -1,7 +1,6 @@ == Suppressed Messages == -# The valueset import the XDS-I FormatCode from dicom the SOP id for KOS. But I get a warning from the IG build tool because DICOM does not have this code in their DCM, eventhough XDS-I indicates this is in that code system. -WARNING: ValueSet/formatcode: ValueSet.compose.include[2].system: URL value 'http://dicom.nema.org/resources/ontology/DCMUID' does not resolve -WARNING: ValueSet/formatcode: ValueSet.compose.include[2]: Unknown System 'http://dicom.nema.org/resources/ontology/DCMUID' specified, so Concepts and Filters can't be checked (Details: A definition for CodeSystem 'http://dicom.nema.org/resources/ontology/DCMUID' could not be found, so the code cannot be validated) -WARNING: ValueSet.where(id = 'formatcode'): Error from http://tx.fhir.org/r4: Unable to provide support for code system http://dicom.nema.org/resources/ontology/DCMUID -Error from https://tx.fhir.org/r4: Error: A definition for CodeSystem 'http://dicom.nema.org/resources/ontology/DCMUID' could not be found, so the value set cannot be expanded +# The XDS-I KOS FormatCode (DICOM SOP UID 1.2.840.10008.5.1.4.1.1.88.59) is now sourced from the locally +# defined, computable CodeSystem http://ihe.net/fhir/ihe.formatcode.fhir/CodeSystem/dicom-uid (see issue #41), +# replacing the former non-expandable reference to http://dicom.nema.org/resources/ontology/DCMUID. No +# warning suppression is needed for that concept anymore. diff --git a/input/implementationguide-IHE.FormatCode.xml b/input/implementationguide-IHE.FormatCode.xml index c05d978..f55623f 100644 --- a/input/implementationguide-IHE.FormatCode.xml +++ b/input/implementationguide-IHE.FormatCode.xml @@ -52,6 +52,14 @@ ImplementationGuide for IHE Format Code vocabulary. + + + + + + + + @@ -124,6 +132,10 @@ ImplementationGuide for IHE Format Code vocabulary. + + + + diff --git a/input/resources/codesystem-dicom-uid.xml b/input/resources/codesystem-dicom-uid.xml new file mode 100644 index 0000000..df4ee60 --- /dev/null +++ b/input/resources/codesystem-dicom-uid.xml @@ -0,0 +1,58 @@ + + + + + + + + + + + + <status value="active"/> + <experimental value="false"/> + <date value="2026-06-09" /> + <publisher value="IHE"/> + <contact> + <name value="IHE"/> + <telecom> + <system value="url"/> + <value value="http://ihe.net"/> + </telecom> + </contact> + <contact> + <name value="IHE Secretary" /> + <telecom> + <system value="email" /> + <value value="secretary@ihe.net" /> + </telecom> + </contact> + <description value="A computable subset of [DICOM](https://dicom.nema.org) Unique Identifiers (UIDs), as registered in [DICOM PS3.6 Table A-1](https://dicom.nema.org/medical/dicom/current/output/chtml/part06/chapter_A.html). This CodeSystem enumerates only the DICOM UIDs that are referenced by the IHE FormatCode ValueSet, so that the ValueSet can be expanded and validated. It replaces the former, non-expandable reference to the DICOM RDF/OWL ontology namespace `http://dicom.nema.org/resources/ontology/DCMUID`. The code values, keywords and types are aligned with the `dicom-uids` CodeSystem (canonical `http://hl7.org/fhir/uv/dicom-terminology/CodeSystem/dicom-uids`) so that consumers may switch to the full DICOM terminology once it is formally published."/> + <copyright value="DICOM® is the registered trademark of the National Electrical Manufacturers Association (NEMA). DICOM Unique Identifiers are defined in DICOM PS3.6."/> + <caseSensitive value="true"/> + <!-- fragment: this CodeSystem deliberately enumerates only the DICOM UIDs used by the IHE FormatCode ValueSet, not the whole DICOM UID registry. --> + <content value="fragment"/> + <property> + <code value="keyword" /> + <type value="string" /> + <description value="The DICOM keyword for the UID, as given in DICOM PS3.6 Table A-1." /> + </property> + <property> + <code value="type" /> + <type value="string" /> + <description value="The DICOM UID Type (e.g. SOP Class, Transfer Syntax), as given in DICOM PS3.6 Table A-1." /> + </property> + <concept> + <code value="1.2.840.10008.5.1.4.1.1.88.59" /> + <display value="Key Object Selection Document Storage" /> + <definition value="Key Object Selection Document Storage SOP Class. Used as the FormatCode for the XDS-I Key Object Selection (KOS) document." /> + <property> + <code value="keyword" /> + <valueString value="KeyObjectSelectionDocumentStorage" /> + </property> + <property> + <code value="type" /> + <valueString value="SOP Class" /> + </property> + </concept> +</CodeSystem> diff --git a/input/resources/valueset-formatcode.xml b/input/resources/valueset-formatcode.xml index 74c2c97..1300d39 100644 --- a/input/resources/valueset-formatcode.xml +++ b/input/resources/valueset-formatcode.xml @@ -52,9 +52,12 @@ <system value="http://terminology.hl7.org/CodeSystem/v3-HL7DocumentFormatCodes"/> </include> -<!-- This one concept is used as the FormatCode for XDS-I. It is the KOS document definition SOP. --> +<!-- This one concept is used as the FormatCode for XDS-I. It is the KOS document definition SOP. + Formerly referenced http://dicom.nema.org/resources/ontology/DCMUID, which is the DICOM RDF/OWL + ontology namespace and not an expandable FHIR CodeSystem. It is now sourced from the locally + defined, computable DICOM UID CodeSystem (see codesystem-dicom-uid.xml) so this ValueSet can expand. --> <include> - <system value="http://dicom.nema.org/resources/ontology/DCMUID" /> + <system value="http://ihe.net/fhir/ihe.formatcode.fhir/CodeSystem/dicom-uid" /> <concept> <code value="1.2.840.10008.5.1.4.1.1.88.59" /> <display value="Key Object Selection Document" />