Skip to content

Commit

Permalink
First Generation of R4B
Browse files Browse the repository at this point in the history
  • Loading branch information
360dgries committed Jul 3, 2024
1 parent d41c6e7 commit 3d5eaed
Show file tree
Hide file tree
Showing 192 changed files with 1,944,723 additions and 0 deletions.
30 changes: 30 additions & 0 deletions lib/fhir_models/generated/4.3.0/metadata.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
module FHIR
module R4B

PRIMITIVES = {
'unsignedInt' => {'type'=>'string', 'regex'=>'[0]|([1-9][0-9]*)'},
'xhtml' => {'type'=>'string'},
'boolean' => {'type'=>'boolean', 'regex'=>'true|false'},
'uri' => {'type'=>'string', 'regex'=>'\\S*'},
'url' => {'type'=>'string', 'regex'=>'\\S*'},
'string' => {'type'=>'string', 'regex'=>'[ \\r\\n\\t\\S]+'},
'base64Binary' => {'type'=>'string', 'regex'=>'(\\s*([0-9a-zA-Z\\+/=]){4}\\s*)+'},
'date' => {'type'=>'date', 'regex'=>'([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1]))?)?'},
'uuid' => {'type'=>'string', 'regex'=>'urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}'},
'decimal' => {'type'=>'decimal', 'regex'=>'-?(0|[1-9][0-9]*)(\\.[0-9]+)?([eE][+-]?[0-9]+)?'},
'dateTime' => {'type'=>'datetime', 'regex'=>'([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?'},
'positiveInt' => {'type'=>'string', 'regex'=>'[1-9][0-9]*'},
'time' => {'type'=>'time', 'regex'=>'([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?'},
'code' => {'type'=>'string', 'regex'=>'[^\\s]+(\\s[^\\s]+)*'},
'oid' => {'type'=>'string', 'regex'=>'urn:oid:[0-2](\\.(0|[1-9][0-9]*))+'},
'instant' => {'type'=>'datetime', 'regex'=>'([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))'},
'integer' => {'type'=>'integer', 'regex'=>'-?([0]|([1-9][0-9]*))'},
'markdown' => {'type'=>'string', 'regex'=>'[ \\r\\n\\t\\S]+'},
'canonical' => {'type'=>'string', 'regex'=>'\\S*'},
'id' => {'type'=>'string', 'regex'=>'[A-Za-z0-9\\-\\.]{1,64}'}
}
TYPES = ['Timing', 'Population', 'DataType', 'Period', 'ProductShelfLife', 'ContactPoint', 'Element', 'BackboneElement', 'CodeableConcept', 'Meta', 'DataRequirement', 'Distance', 'Range', 'Ratio', 'Money', 'ProdCharacteristic', 'Quantity', 'Count', 'Annotation', 'Reference', 'ContactDetail', 'Expression', 'Coding', 'Narrative', 'MarketingStatus', 'Attachment', 'Dosage', 'UsageContext', 'CodeableReference', 'Address', 'RatioRange', 'Signature', 'Age', 'ElementDefinition', 'TriggerDefinition', 'Identifier', 'RelatedArtifact', 'Contributor', 'Duration', 'HumanName', 'ParameterDefinition', 'SampledData', 'Extension']
RESOURCES = ['Appointment', 'Task', 'Specimen', 'RequestGroup', 'Composition', 'Measure', 'Ingredient', 'Basic', 'SupplyDelivery', 'Library', 'Substance', 'ValueSet', 'DeviceDefinition', 'PlanDefinition', 'AdverseEvent', 'CodeSystem', 'DeviceUseStatement', 'AuditEvent', 'ServiceRequest', 'Resource', 'Provenance', 'List', 'MedicinalProductDefinition', 'OperationOutcome', 'TerminologyCapabilities', 'PaymentNotice', 'CarePlan', 'TestScript', 'RegulatedAuthorization', 'EnrollmentRequest', 'BiologicallyDerivedProduct', 'Immunization', 'DocumentManifest', 'CompartmentDefinition', 'Bundle', 'Subscription', 'TestReport', 'OperationDefinition', 'MedicationRequest', 'ResearchElementDefinition', 'StructureDefinition', 'CatalogEntry', 'Location', 'ManufacturedItemDefinition', 'Procedure', 'ResearchStudy', 'ConceptMap', 'NutritionOrder', 'AppointmentResponse', 'ChargeItemDefinition', 'SubstanceDefinition', 'Account', 'DetectedIssue', 'Flag', 'BodyStructure', 'SubscriptionTopic', 'Questionnaire', 'Slot', 'ExplanationOfBenefit', 'NamingSystem', 'ImmunizationRecommendation', 'ResearchDefinition', 'Linkage', 'Observation', 'EventDefinition', 'CoverageEligibilityRequest', 'EpisodeOfCare', 'Binary', 'Media', 'Goal', 'RiskAssessment', 'ImagingStudy', 'Claim', 'VerificationResult', 'CapabilityStatement', 'OrganizationAffiliation', 'ObservationDefinition', 'Communication', 'Schedule', 'PractitionerRole', 'InsurancePlan', 'ResearchSubject', 'EnrollmentResponse', 'MeasureReport', 'EvidenceVariable', 'Device', 'MedicationKnowledge', 'MolecularSequence', 'ImplementationGuide', 'RelatedPerson', 'ClaimResponse', 'Coverage', 'HealthcareService', 'SpecimenDefinition', 'Evidence', 'DomainResource', 'Practitioner', 'DeviceMetric', 'DocumentReference', 'ImmunizationEvaluation', 'MedicationStatement', 'ChargeItem', 'Medication', 'ClinicalUseDefinition', 'Parameters', 'SupplyRequest', 'CareTeam', 'Contract', 'PaymentReconciliation', 'FamilyMemberHistory', 'Citation', 'VisionPrescription', 'GuidanceResponse', 'AdministrableProductDefinition', 'PackagedProductDefinition', 'Consent', 'StructureMap', 'SearchParameter', 'AllergyIntolerance', 'ClinicalImpression', 'ActivityDefinition', 'Patient', 'NutritionProduct', 'MessageHeader', 'QuestionnaireResponse', 'CommunicationRequest', 'MessageDefinition', 'DeviceRequest', 'Invoice', 'Endpoint', 'Person', 'MedicationDispense', 'CoverageEligibilityResponse', 'Organization', 'EvidenceReport', 'GraphDefinition', 'SubscriptionStatus', 'Group', 'ExampleScenario', 'Condition', 'DiagnosticReport', 'MedicationAdministration', 'Encounter']

end
end
98 changes: 98 additions & 0 deletions lib/fhir_models/generated/4.3.0/resources/Account.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
module FHIR
module R4B
class Account < FHIR::Model
include FHIR::Hashable
include FHIR::Json
include FHIR::Xml

SEARCH_PARAMS = ['identifier', 'name', 'owner', 'patient', 'period', 'status', 'subject', 'type']
METADATA = {
'id' => {'type'=>'id', 'path'=>'Account.id', 'min'=>0, 'max'=>1},
'meta' => {'type'=>'Meta', 'path'=>'Account.meta', 'min'=>0, 'max'=>1},
'implicitRules' => {'type'=>'uri', 'path'=>'Account.implicitRules', 'min'=>0, 'max'=>1},
'language' => {'valid_codes'=>{'urn:ietf:bcp:47'=>['ar', 'bn', 'cs', 'da', 'de', 'de-AT', 'de-CH', 'de-DE', 'el', 'en', 'en-AU', 'en-CA', 'en-GB', 'en-IN', 'en-NZ', 'en-SG', 'en-US', 'es', 'es-AR', 'es-ES', 'es-UY', 'fi', 'fr', 'fr-BE', 'fr-CH', 'fr-FR', 'fy', 'fy-NL', 'hi', 'hr', 'it', 'it-CH', 'it-IT', 'ja', 'ko', 'nl', 'nl-BE', 'nl-NL', 'no', 'no-NO', 'pa', 'pl', 'pt', 'pt-BR', 'ru', 'ru-RU', 'sr', 'sr-RS', 'sv', 'sv-SE', 'te', 'zh', 'zh-CN', 'zh-HK', 'zh-SG', 'zh-TW']}, 'type'=>'code', 'path'=>'Account.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'preferred', 'uri'=>'http://hl7.org/fhir/ValueSet/languages'}},
'text' => {'type'=>'Narrative', 'path'=>'Account.text', 'min'=>0, 'max'=>1},
'contained' => {'type'=>'Resource', 'path'=>'Account.contained', 'min'=>0, 'max'=>Float::INFINITY},
'extension' => {'type'=>'Extension', 'path'=>'Account.extension', 'min'=>0, 'max'=>Float::INFINITY},
'modifierExtension' => {'type'=>'Extension', 'path'=>'Account.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
'identifier' => {'type'=>'Identifier', 'path'=>'Account.identifier', 'min'=>0, 'max'=>Float::INFINITY},
'status' => {'valid_codes'=>{'http://hl7.org/fhir/account-status'=>['active', 'inactive', 'entered-in-error', 'on-hold', 'unknown']}, 'type'=>'code', 'path'=>'Account.status', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/account-status'}},
'type' => {'valid_codes'=>{'http://terminology.hl7.org/CodeSystem/v3-ActCode'=>['_ActAccountCode', 'ACCTRECEIVABLE', 'CASH', 'CC', 'AE', 'DN', 'DV', 'MC', 'V', 'PBILLACCT', '_CreditCard']}, 'type'=>'CodeableConcept', 'path'=>'Account.type', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/account-type'}},
'name' => {'type'=>'string', 'path'=>'Account.name', 'min'=>0, 'max'=>1},
'subject' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/PractitionerRole', 'http://hl7.org/fhir/StructureDefinition/Location', 'http://hl7.org/fhir/StructureDefinition/HealthcareService', 'http://hl7.org/fhir/StructureDefinition/Organization'], 'type'=>'Reference', 'path'=>'Account.subject', 'min'=>0, 'max'=>Float::INFINITY},
'servicePeriod' => {'type'=>'Period', 'path'=>'Account.servicePeriod', 'min'=>0, 'max'=>1},
'coverage' => {'type'=>'Account::Coverage', 'path'=>'Account.coverage', 'min'=>0, 'max'=>Float::INFINITY},
'owner' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Organization'], 'type'=>'Reference', 'path'=>'Account.owner', 'min'=>0, 'max'=>1},
'description' => {'type'=>'string', 'path'=>'Account.description', 'min'=>0, 'max'=>1},
'guarantor' => {'type'=>'Account::Guarantor', 'path'=>'Account.guarantor', 'min'=>0, 'max'=>Float::INFINITY},
'partOf' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Account'], 'type'=>'Reference', 'path'=>'Account.partOf', 'min'=>0, 'max'=>1}
}

class Coverage < FHIR::Model
include FHIR::Hashable
include FHIR::Json
include FHIR::Xml

METADATA = {
'id' => {'type'=>'string', 'path'=>'Coverage.id', 'min'=>0, 'max'=>1},
'extension' => {'type'=>'Extension', 'path'=>'Coverage.extension', 'min'=>0, 'max'=>Float::INFINITY},
'modifierExtension' => {'type'=>'Extension', 'path'=>'Coverage.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
'coverage' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Coverage'], 'type'=>'Reference', 'path'=>'Coverage.coverage', 'min'=>1, 'max'=>1},
'priority' => {'type'=>'positiveInt', 'path'=>'Coverage.priority', 'min'=>0, 'max'=>1}
}

attr_accessor :id # 0-1 string
attr_accessor :extension # 0-* [ Extension ]
attr_accessor :modifierExtension # 0-* [ Extension ]
attr_accessor :coverage # 1-1 Reference(Coverage)
attr_accessor :priority # 0-1 positiveInt
end

class Guarantor < FHIR::Model
include FHIR::Hashable
include FHIR::Json
include FHIR::Xml

METADATA = {
'id' => {'type'=>'string', 'path'=>'Guarantor.id', 'min'=>0, 'max'=>1},
'extension' => {'type'=>'Extension', 'path'=>'Guarantor.extension', 'min'=>0, 'max'=>Float::INFINITY},
'modifierExtension' => {'type'=>'Extension', 'path'=>'Guarantor.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
'party' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson', 'http://hl7.org/fhir/StructureDefinition/Organization'], 'type'=>'Reference', 'path'=>'Guarantor.party', 'min'=>1, 'max'=>1},
'onHold' => {'type'=>'boolean', 'path'=>'Guarantor.onHold', 'min'=>0, 'max'=>1},
'period' => {'type'=>'Period', 'path'=>'Guarantor.period', 'min'=>0, 'max'=>1}
}

attr_accessor :id # 0-1 string
attr_accessor :extension # 0-* [ Extension ]
attr_accessor :modifierExtension # 0-* [ Extension ]
attr_accessor :party # 1-1 Reference(Patient|RelatedPerson|Organization)
attr_accessor :onHold # 0-1 boolean
attr_accessor :period # 0-1 Period
end

attr_accessor :id # 0-1 id
attr_accessor :meta # 0-1 Meta
attr_accessor :implicitRules # 0-1 uri
attr_accessor :language # 0-1 code
attr_accessor :text # 0-1 Narrative
attr_accessor :contained # 0-* [ Resource ]
attr_accessor :extension # 0-* [ Extension ]
attr_accessor :modifierExtension # 0-* [ Extension ]
attr_accessor :identifier # 0-* [ Identifier ]
attr_accessor :status # 1-1 code
attr_accessor :type # 0-1 CodeableConcept
attr_accessor :name # 0-1 string
attr_accessor :subject # 0-* [ Reference(Patient|Device|Practitioner|PractitionerRole|Location|HealthcareService|Organization) ]
attr_accessor :servicePeriod # 0-1 Period
attr_accessor :coverage # 0-* [ Account::Coverage ]
attr_accessor :owner # 0-1 Reference(Organization)
attr_accessor :description # 0-1 string
attr_accessor :guarantor # 0-* [ Account::Guarantor ]
attr_accessor :partOf # 0-1 Reference(Account)

def resourceType
'Account'
end
end
end
end
187 changes: 187 additions & 0 deletions lib/fhir_models/generated/4.3.0/resources/ActivityDefinition.rb

Large diffs are not rendered by default.

Loading

0 comments on commit 3d5eaed

Please sign in to comment.