Class: PreparationsEntry
- Inherits:
-
Object
- Object
- PreparationsEntry
- Includes:
- SAXMachine
- Defined in:
- lib/oddb2xml/fhir_support.rb,
lib/oddb2xml/xml_definitions.rb
Overview
Extend PreparationsEntry to handle both XML and FHIR
Class Method Summary collapse
Class Method Details
.original_parse ⇒ Object
891 |
# File 'lib/oddb2xml/fhir_support.rb', line 891 alias_method :original_parse, :parse |
.parse(input, **kwargs) ⇒ Object
893 894 895 896 897 898 899 900 901 902 |
# File 'lib/oddb2xml/fhir_support.rb', line 893 def parse(input, **kwargs) # Check if input is a file path ending in .ndjson if input.is_a?(String) && File.exist?(input) && input.end_with?(".ndjson") # Parse as FHIR FhirPreparationsEntry.parse(input) else # Parse as XML (original behavior) original_parse(input, **kwargs) end end |