fhir_models 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (152) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/.travis.yml +0 -1
  4. data/Gemfile.lock +1 -1
  5. data/Rakefile +0 -1
  6. data/fhir_models.gemspec +1 -1
  7. data/lib/fhir/metadata.rb +25 -0
  8. data/lib/fhir/resources/Account.rb +54 -0
  9. data/lib/fhir/resources/AllergyIntolerance.rb +92 -0
  10. data/lib/fhir/resources/Appointment.rb +88 -0
  11. data/lib/fhir/resources/AppointmentResponse.rb +48 -0
  12. data/lib/fhir/resources/AuditEvent.rb +188 -0
  13. data/lib/fhir/resources/Basic.rb +42 -0
  14. data/lib/fhir/resources/Binary.rb +28 -0
  15. data/lib/fhir/resources/BodySite.rb +44 -0
  16. data/lib/fhir/resources/Bundle.rb +154 -0
  17. data/lib/fhir/resources/CarePlan.rb +184 -0
  18. data/lib/fhir/resources/CareTeam.rb +70 -0
  19. data/lib/fhir/resources/Claim.rb +490 -0
  20. data/lib/fhir/resources/ClaimResponse.rb +421 -0
  21. data/lib/fhir/resources/ClinicalImpression.rb +131 -0
  22. data/lib/fhir/resources/CodeSystem.rb +225 -0
  23. data/lib/fhir/resources/Communication.rb +83 -0
  24. data/lib/fhir/resources/CommunicationRequest.rb +90 -0
  25. data/lib/fhir/resources/CompartmentDefinition.rb +98 -0
  26. data/lib/fhir/resources/Composition.rb +136 -0
  27. data/lib/fhir/resources/ConceptMap.rb +168 -0
  28. data/lib/fhir/resources/Condition.rb +126 -0
  29. data/lib/fhir/resources/Conformance.rb +442 -0
  30. data/lib/fhir/resources/Contract.rb +320 -0
  31. data/lib/fhir/resources/Coverage.rb +77 -0
  32. data/lib/fhir/resources/DataElement.rb +104 -0
  33. data/lib/fhir/resources/DecisionSupportRule.rb +42 -0
  34. data/lib/fhir/resources/DecisionSupportServiceModule.rb +40 -0
  35. data/lib/fhir/resources/DetectedIssue.rb +74 -0
  36. data/lib/fhir/resources/Device.rb +64 -0
  37. data/lib/fhir/resources/DeviceComponent.rb +74 -0
  38. data/lib/fhir/resources/DeviceMetric.rb +74 -0
  39. data/lib/fhir/resources/DeviceUseRequest.rb +68 -0
  40. data/lib/fhir/resources/DeviceUseStatement.rb +60 -0
  41. data/lib/fhir/resources/DiagnosticOrder.rb +106 -0
  42. data/lib/fhir/resources/DiagnosticReport.rb +91 -0
  43. data/lib/fhir/resources/DocumentManifest.rb +99 -0
  44. data/lib/fhir/resources/DocumentReference.rb +156 -0
  45. data/lib/fhir/resources/DomainResource.rb +32 -0
  46. data/lib/fhir/resources/EligibilityRequest.rb +90 -0
  47. data/lib/fhir/resources/EligibilityResponse.rb +152 -0
  48. data/lib/fhir/resources/Encounter.rb +172 -0
  49. data/lib/fhir/resources/EnrollmentRequest.rb +52 -0
  50. data/lib/fhir/resources/EnrollmentResponse.rb +52 -0
  51. data/lib/fhir/resources/EpisodeOfCare.rb +74 -0
  52. data/lib/fhir/resources/ExpansionProfile.rb +284 -0
  53. data/lib/fhir/resources/ExplanationOfBenefit.rb +764 -0
  54. data/lib/fhir/resources/FamilyMemberHistory.rb +110 -0
  55. data/lib/fhir/resources/Flag.rb +48 -0
  56. data/lib/fhir/resources/Goal.rb +91 -0
  57. data/lib/fhir/resources/Group.rb +105 -0
  58. data/lib/fhir/resources/GuidanceResponse.rb +139 -0
  59. data/lib/fhir/resources/HealthcareService.rb +122 -0
  60. data/lib/fhir/resources/ImagingExcerpt.rb +210 -0
  61. data/lib/fhir/resources/ImagingObjectSelection.rb +136 -0
  62. data/lib/fhir/resources/ImagingStudy.rb +130 -0
  63. data/lib/fhir/resources/Immunization.rb +148 -0
  64. data/lib/fhir/resources/ImmunizationRecommendation.rb +114 -0
  65. data/lib/fhir/resources/ImplementationGuide.rb +211 -0
  66. data/lib/fhir/resources/Library.rb +145 -0
  67. data/lib/fhir/resources/Linkage.rb +56 -0
  68. data/lib/fhir/resources/List.rb +82 -0
  69. data/lib/fhir/resources/Location.rb +78 -0
  70. data/lib/fhir/resources/Measure.rb +160 -0
  71. data/lib/fhir/resources/MeasureReport.rb +204 -0
  72. data/lib/fhir/resources/Media.rb +56 -0
  73. data/lib/fhir/resources/Medication.rb +154 -0
  74. data/lib/fhir/resources/MedicationAdministration.rb +104 -0
  75. data/lib/fhir/resources/MedicationDispense.rb +141 -0
  76. data/lib/fhir/resources/MedicationOrder.rb +172 -0
  77. data/lib/fhir/resources/MedicationStatement.rb +117 -0
  78. data/lib/fhir/resources/MessageHeader.rb +124 -0
  79. data/lib/fhir/resources/ModuleDefinition.rb +249 -0
  80. data/lib/fhir/resources/NamingSystem.rb +102 -0
  81. data/lib/fhir/resources/NutritionOrder.rb +211 -0
  82. data/lib/fhir/resources/Observation.rb +187 -0
  83. data/lib/fhir/resources/OperationDefinition.rb +153 -0
  84. data/lib/fhir/resources/OperationOutcome.rb +62 -0
  85. data/lib/fhir/resources/Order.rb +73 -0
  86. data/lib/fhir/resources/OrderResponse.rb +46 -0
  87. data/lib/fhir/resources/OrderSet.rb +38 -0
  88. data/lib/fhir/resources/Organization.rb +72 -0
  89. data/lib/fhir/resources/Parameters.rb +117 -0
  90. data/lib/fhir/resources/Patient.rb +166 -0
  91. data/lib/fhir/resources/PaymentNotice.rb +71 -0
  92. data/lib/fhir/resources/PaymentReconciliation.rb +140 -0
  93. data/lib/fhir/resources/Person.rb +72 -0
  94. data/lib/fhir/resources/Practitioner.rb +110 -0
  95. data/lib/fhir/resources/PractitionerRole.rb +102 -0
  96. data/lib/fhir/resources/Procedure.rb +122 -0
  97. data/lib/fhir/resources/ProcedureRequest.rb +73 -0
  98. data/lib/fhir/resources/ProcessRequest.rb +99 -0
  99. data/lib/fhir/resources/ProcessResponse.rb +92 -0
  100. data/lib/fhir/resources/Protocol.rb +242 -0
  101. data/lib/fhir/resources/Provenance.rb +122 -0
  102. data/lib/fhir/resources/Questionnaire.rb +205 -0
  103. data/lib/fhir/resources/QuestionnaireResponse.rb +123 -0
  104. data/lib/fhir/resources/ReferralRequest.rb +68 -0
  105. data/lib/fhir/resources/RelatedPerson.rb +52 -0
  106. data/lib/fhir/resources/Resource.rb +24 -0
  107. data/lib/fhir/resources/RiskAssessment.rb +88 -0
  108. data/lib/fhir/resources/Schedule.rb +46 -0
  109. data/lib/fhir/resources/SearchParameter.rb +86 -0
  110. data/lib/fhir/resources/Sequence.rb +238 -0
  111. data/lib/fhir/resources/Slot.rb +54 -0
  112. data/lib/fhir/resources/Specimen.rb +140 -0
  113. data/lib/fhir/resources/StructureDefinition.rb +164 -0
  114. data/lib/fhir/resources/StructureMap.rb +297 -0
  115. data/lib/fhir/resources/Subscription.rb +72 -0
  116. data/lib/fhir/resources/Substance.rb +86 -0
  117. data/lib/fhir/resources/SupplyDelivery.rb +54 -0
  118. data/lib/fhir/resources/SupplyRequest.rb +77 -0
  119. data/lib/fhir/resources/Task.rb +240 -0
  120. data/lib/fhir/resources/TestScript.rb +692 -0
  121. data/lib/fhir/resources/ValueSet.rb +289 -0
  122. data/lib/fhir/resources/VisionPrescription.rb +97 -0
  123. data/lib/fhir/types/ActionDefinition.rb +109 -0
  124. data/lib/fhir/types/Address.rb +36 -0
  125. data/lib/fhir/types/Annotation.rb +27 -0
  126. data/lib/fhir/types/Attachment.rb +32 -0
  127. data/lib/fhir/types/BackboneElement.rb +18 -0
  128. data/lib/fhir/types/CodeableConcept.rb +20 -0
  129. data/lib/fhir/types/Coding.rb +26 -0
  130. data/lib/fhir/types/ContactPoint.rb +26 -0
  131. data/lib/fhir/types/DataRequirement.rb +78 -0
  132. data/lib/fhir/types/Element.rb +16 -0
  133. data/lib/fhir/types/ElementDefinition.rb +605 -0
  134. data/lib/fhir/types/Extension.rb +87 -0
  135. data/lib/fhir/types/HumanName.rb +30 -0
  136. data/lib/fhir/types/Identifier.rb +28 -0
  137. data/lib/fhir/types/Meta.rb +26 -0
  138. data/lib/fhir/types/ModuleMetadata.rb +152 -0
  139. data/lib/fhir/types/Narrative.rb +20 -0
  140. data/lib/fhir/types/ParameterDefinition.rb +30 -0
  141. data/lib/fhir/types/Period.rb +20 -0
  142. data/lib/fhir/types/Quantity.rb +26 -0
  143. data/lib/fhir/types/Range.rb +20 -0
  144. data/lib/fhir/types/Ratio.rb +20 -0
  145. data/lib/fhir/types/Reference.rb +20 -0
  146. data/lib/fhir/types/SampledData.rb +30 -0
  147. data/lib/fhir/types/Signature.rb +31 -0
  148. data/lib/fhir/types/Timing.rb +69 -0
  149. data/lib/fhir/types/TriggerDefinition.rb +33 -0
  150. data/lib/fhir_models.rb +2 -2
  151. data/lib/tasks/tasks.rake +29 -0
  152. metadata +145 -2
@@ -0,0 +1,153 @@
1
+ module FHIR
2
+ class OperationDefinition < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = ["base", "code", "context", "date", "instance", "kind", "name", "paramprofile", "publisher", "status", "system", "type", "url", "version"]
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'OperationDefinition.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'OperationDefinition.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'OperationDefinition.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'OperationDefinition.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'text' => {'type'=>'Narrative', 'path'=>'OperationDefinition.text', 'min'=>0, 'max'=>1},
14
+ 'contained' => {'type'=>'Resource', 'path'=>'OperationDefinition.contained', 'min'=>0, 'max'=>Float::INFINITY},
15
+ 'extension' => {'type'=>'Extension', 'path'=>'OperationDefinition.extension', 'min'=>0, 'max'=>Float::INFINITY},
16
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'OperationDefinition.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
17
+ 'url' => {'type'=>'uri', 'path'=>'OperationDefinition.url', 'min'=>0, 'max'=>1},
18
+ 'version' => {'type'=>'string', 'path'=>'OperationDefinition.version', 'min'=>0, 'max'=>1},
19
+ 'name' => {'type'=>'string', 'path'=>'OperationDefinition.name', 'min'=>1, 'max'=>1},
20
+ 'status' => {'valid_codes'=>{'http://hl7.org/fhir/conformance-resource-status'=>['draft', 'active', 'retired']}, 'type'=>'code', 'path'=>'OperationDefinition.status', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/conformance-resource-status'}},
21
+ 'kind' => {'valid_codes'=>{'http://hl7.org/fhir/operation-kind'=>['operation', 'query']}, 'type'=>'code', 'path'=>'OperationDefinition.kind', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/operation-kind'}},
22
+ 'experimental' => {'type'=>'boolean', 'path'=>'OperationDefinition.experimental', 'min'=>0, 'max'=>1},
23
+ 'date' => {'type'=>'dateTime', 'path'=>'OperationDefinition.date', 'min'=>0, 'max'=>1},
24
+ 'publisher' => {'type'=>'string', 'path'=>'OperationDefinition.publisher', 'min'=>0, 'max'=>1},
25
+ 'contact' => {'type'=>'OperationDefinition::Contact', 'path'=>'OperationDefinition.contact', 'min'=>0, 'max'=>Float::INFINITY},
26
+ 'description' => {'type'=>'string', 'path'=>'OperationDefinition.description', 'min'=>0, 'max'=>1},
27
+ 'useContext' => {'type'=>'CodeableConcept', 'path'=>'OperationDefinition.useContext', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/use-context'}},
28
+ 'requirements' => {'type'=>'string', 'path'=>'OperationDefinition.requirements', 'min'=>0, 'max'=>1},
29
+ 'idempotent' => {'type'=>'boolean', 'path'=>'OperationDefinition.idempotent', 'min'=>0, 'max'=>1},
30
+ 'code' => {'type'=>'code', 'path'=>'OperationDefinition.code', 'min'=>1, 'max'=>1},
31
+ 'comment' => {'type'=>'string', 'path'=>'OperationDefinition.comment', 'min'=>0, 'max'=>1},
32
+ 'base' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/OperationDefinition'], 'type'=>'Reference', 'path'=>'OperationDefinition.base', 'min'=>0, 'max'=>1},
33
+ 'system' => {'type'=>'boolean', 'path'=>'OperationDefinition.system', 'min'=>1, 'max'=>1},
34
+ 'type' => {'valid_codes'=>{'http://hl7.org/fhir/resource-types'=>['Account', 'AllergyIntolerance', 'Appointment', 'AppointmentResponse', 'AuditEvent', 'Basic', 'Binary', 'BodySite', 'Bundle', 'CarePlan', 'CareTeam', 'Claim', 'ClaimResponse', 'ClinicalImpression', 'CodeSystem', 'Communication', 'CommunicationRequest', 'CompartmentDefinition', 'Composition', 'ConceptMap', 'Condition', 'Conformance', 'Contract', 'Coverage', 'DataElement', 'DecisionSupportRule', 'DecisionSupportServiceModule', 'DetectedIssue', 'Device', 'DeviceComponent', 'DeviceMetric', 'DeviceUseRequest', 'DeviceUseStatement', 'DiagnosticOrder', 'DiagnosticReport', 'DocumentManifest', 'DocumentReference', 'DomainResource', 'EligibilityRequest', 'EligibilityResponse', 'Encounter', 'EnrollmentRequest', 'EnrollmentResponse', 'EpisodeOfCare', 'ExpansionProfile', 'ExplanationOfBenefit', 'FamilyMemberHistory', 'Flag', 'Goal', 'Group', 'GuidanceResponse', 'HealthcareService', 'ImagingExcerpt', 'ImagingObjectSelection', 'ImagingStudy', 'Immunization', 'ImmunizationRecommendation', 'ImplementationGuide', 'Library', 'Linkage', 'List', 'Location', 'Measure', 'MeasureReport', 'Media', 'Medication', 'MedicationAdministration', 'MedicationDispense', 'MedicationOrder', 'MedicationStatement', 'MessageHeader', 'ModuleDefinition', 'NamingSystem', 'NutritionOrder', 'Observation', 'OperationDefinition', 'OperationOutcome', 'Order', 'OrderResponse', 'OrderSet', 'Organization', 'Parameters', 'Patient', 'PaymentNotice', 'PaymentReconciliation', 'Person', 'Practitioner', 'PractitionerRole', 'Procedure', 'ProcedureRequest', 'ProcessRequest', 'ProcessResponse', 'Protocol', 'Provenance', 'Questionnaire', 'QuestionnaireResponse', 'ReferralRequest', 'RelatedPerson', 'Resource', 'RiskAssessment', 'Schedule', 'SearchParameter', 'Sequence', 'Slot', 'Specimen', 'StructureDefinition', 'StructureMap', 'Subscription', 'Substance', 'SupplyDelivery', 'SupplyRequest', 'Task', 'TestScript', 'ValueSet', 'VisionPrescription']}, 'type'=>'code', 'path'=>'OperationDefinition.type', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/resource-types'}},
35
+ 'instance' => {'type'=>'boolean', 'path'=>'OperationDefinition.instance', 'min'=>1, 'max'=>1},
36
+ 'parameter' => {'type'=>'OperationDefinition::Parameter', 'path'=>'OperationDefinition.parameter', 'min'=>0, 'max'=>Float::INFINITY}
37
+ }
38
+
39
+ class Contact < FHIR::Model
40
+ include FHIR::Hashable
41
+ include FHIR::Json
42
+ include FHIR::Xml
43
+
44
+ METADATA = {
45
+ 'id' => {'type'=>'id', 'path'=>'Contact.id', 'min'=>0, 'max'=>1},
46
+ 'extension' => {'type'=>'Extension', 'path'=>'Contact.extension', 'min'=>0, 'max'=>Float::INFINITY},
47
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Contact.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
48
+ 'name' => {'type'=>'string', 'path'=>'Contact.name', 'min'=>0, 'max'=>1},
49
+ 'telecom' => {'type'=>'ContactPoint', 'path'=>'Contact.telecom', 'min'=>0, 'max'=>Float::INFINITY}
50
+ }
51
+
52
+ attr_accessor :id # 0-1 id
53
+ attr_accessor :extension # 0-* [ Extension ]
54
+ attr_accessor :modifierExtension # 0-* [ Extension ]
55
+ attr_accessor :name # 0-1 string
56
+ attr_accessor :telecom # 0-* [ ContactPoint ]
57
+ end
58
+
59
+ class Parameter < FHIR::Model
60
+ include FHIR::Hashable
61
+ include FHIR::Json
62
+ include FHIR::Xml
63
+
64
+ METADATA = {
65
+ 'id' => {'type'=>'id', 'path'=>'Parameter.id', 'min'=>0, 'max'=>1},
66
+ 'extension' => {'type'=>'Extension', 'path'=>'Parameter.extension', 'min'=>0, 'max'=>Float::INFINITY},
67
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Parameter.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
68
+ 'name' => {'type'=>'code', 'path'=>'Parameter.name', 'min'=>1, 'max'=>1},
69
+ 'use' => {'valid_codes'=>{'http://hl7.org/fhir/operation-parameter-use'=>['in', 'out']}, 'type'=>'code', 'path'=>'Parameter.use', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/operation-parameter-use'}},
70
+ 'min' => {'type'=>'integer', 'path'=>'Parameter.min', 'min'=>1, 'max'=>1},
71
+ 'max' => {'type'=>'string', 'path'=>'Parameter.max', 'min'=>1, 'max'=>1},
72
+ 'documentation' => {'type'=>'string', 'path'=>'Parameter.documentation', 'min'=>0, 'max'=>1},
73
+ 'type' => {'valid_codes'=>{'http://hl7.org/fhir/data-types'=>['ActionDefinition', 'Address', 'Age', 'Annotation', 'Attachment', 'BackboneElement', 'CodeableConcept', 'Coding', 'ContactPoint', 'Count', 'DataRequirement', 'Distance', 'Duration', 'Element', 'ElementDefinition', 'Extension', 'HumanName', 'Identifier', 'Meta', 'ModuleMetadata', 'Money', 'Narrative', 'ParameterDefinition', 'Period', 'Quantity', 'Range', 'Ratio', 'Reference', 'SampledData', 'Signature', 'SimpleQuantity', 'Timing', 'TriggerDefinition', 'base64Binary', 'boolean', 'code', 'date', 'dateTime', 'decimal', 'id', 'instant', 'integer', 'markdown', 'oid', 'positiveInt', 'string', 'time', 'unsignedInt', 'uri', 'uuid', 'xhtml'], 'http://hl7.org/fhir/resource-types'=>['Account', 'AllergyIntolerance', 'Appointment', 'AppointmentResponse', 'AuditEvent', 'Basic', 'Binary', 'BodySite', 'Bundle', 'CarePlan', 'CareTeam', 'Claim', 'ClaimResponse', 'ClinicalImpression', 'CodeSystem', 'Communication', 'CommunicationRequest', 'CompartmentDefinition', 'Composition', 'ConceptMap', 'Condition', 'Conformance', 'Contract', 'Coverage', 'DataElement', 'DecisionSupportRule', 'DecisionSupportServiceModule', 'DetectedIssue', 'Device', 'DeviceComponent', 'DeviceMetric', 'DeviceUseRequest', 'DeviceUseStatement', 'DiagnosticOrder', 'DiagnosticReport', 'DocumentManifest', 'DocumentReference', 'DomainResource', 'EligibilityRequest', 'EligibilityResponse', 'Encounter', 'EnrollmentRequest', 'EnrollmentResponse', 'EpisodeOfCare', 'ExpansionProfile', 'ExplanationOfBenefit', 'FamilyMemberHistory', 'Flag', 'Goal', 'Group', 'GuidanceResponse', 'HealthcareService', 'ImagingExcerpt', 'ImagingObjectSelection', 'ImagingStudy', 'Immunization', 'ImmunizationRecommendation', 'ImplementationGuide', 'Library', 'Linkage', 'List', 'Location', 'Measure', 'MeasureReport', 'Media', 'Medication', 'MedicationAdministration', 'MedicationDispense', 'MedicationOrder', 'MedicationStatement', 'MessageHeader', 'ModuleDefinition', 'NamingSystem', 'NutritionOrder', 'Observation', 'OperationDefinition', 'OperationOutcome', 'Order', 'OrderResponse', 'OrderSet', 'Organization', 'Parameters', 'Patient', 'PaymentNotice', 'PaymentReconciliation', 'Person', 'Practitioner', 'PractitionerRole', 'Procedure', 'ProcedureRequest', 'ProcessRequest', 'ProcessResponse', 'Protocol', 'Provenance', 'Questionnaire', 'QuestionnaireResponse', 'ReferralRequest', 'RelatedPerson', 'Resource', 'RiskAssessment', 'Schedule', 'SearchParameter', 'Sequence', 'Slot', 'Specimen', 'StructureDefinition', 'StructureMap', 'Subscription', 'Substance', 'SupplyDelivery', 'SupplyRequest', 'Task', 'TestScript', 'ValueSet', 'VisionPrescription'], 'http://hl7.org/fhir/abstract-types'=>['Type', 'Any']}, 'type'=>'code', 'path'=>'Parameter.type', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/all-types'}},
74
+ 'searchType' => {'valid_codes'=>{'http://hl7.org/fhir/search-param-type'=>['number', 'date', 'string', 'token', 'reference', 'composite', 'quantity', 'uri']}, 'type'=>'code', 'path'=>'Parameter.searchType', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/search-param-type'}},
75
+ 'profile' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/StructureDefinition'], 'type'=>'Reference', 'path'=>'Parameter.profile', 'min'=>0, 'max'=>1},
76
+ 'binding' => {'type'=>'OperationDefinition::Parameter::Binding', 'path'=>'Parameter.binding', 'min'=>0, 'max'=>1},
77
+ 'part' => {'type'=>'OperationDefinition::Parameter', 'path'=>'Parameter.part', 'min'=>0, 'max'=>Float::INFINITY}
78
+ }
79
+
80
+ class Binding < FHIR::Model
81
+ include FHIR::Hashable
82
+ include FHIR::Json
83
+ include FHIR::Xml
84
+
85
+ MULTIPLE_TYPES = {
86
+ 'valueSet' => ['uri', 'Reference']
87
+ }
88
+ METADATA = {
89
+ 'id' => {'type'=>'id', 'path'=>'Binding.id', 'min'=>0, 'max'=>1},
90
+ 'extension' => {'type'=>'Extension', 'path'=>'Binding.extension', 'min'=>0, 'max'=>Float::INFINITY},
91
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Binding.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
92
+ 'strength' => {'valid_codes'=>{'http://hl7.org/fhir/binding-strength'=>['required', 'extensible', 'preferred', 'example']}, 'type'=>'code', 'path'=>'Binding.strength', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/binding-strength'}},
93
+ 'valueSetUri' => {'type'=>'uri', 'path'=>'Binding.valueSet[x]', 'min'=>1, 'max'=>1},
94
+ 'valueSetReference' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/ValueSet'], 'type'=>'Reference', 'path'=>'Binding.valueSet[x]', 'min'=>1, 'max'=>1}
95
+ }
96
+
97
+ attr_accessor :id # 0-1 id
98
+ attr_accessor :extension # 0-* [ Extension ]
99
+ attr_accessor :modifierExtension # 0-* [ Extension ]
100
+ attr_accessor :strength # 1-1 code
101
+ attr_accessor :valueSetUri # 1-1 uri
102
+ attr_accessor :valueSetReference # 1-1 Reference(ValueSet)
103
+ end
104
+
105
+ attr_accessor :id # 0-1 id
106
+ attr_accessor :extension # 0-* [ Extension ]
107
+ attr_accessor :modifierExtension # 0-* [ Extension ]
108
+ attr_accessor :name # 1-1 code
109
+ attr_accessor :use # 1-1 code
110
+ attr_accessor :min # 1-1 integer
111
+ attr_accessor :max # 1-1 string
112
+ attr_accessor :documentation # 0-1 string
113
+ attr_accessor :type # 0-1 code
114
+ attr_accessor :searchType # 0-1 code
115
+ attr_accessor :profile # 0-1 Reference(StructureDefinition)
116
+ attr_accessor :binding # 0-1 OperationDefinition::Parameter::Binding
117
+ attr_accessor :part # 0-* [ OperationDefinition::Parameter ]
118
+ end
119
+
120
+ attr_accessor :id # 0-1 id
121
+ attr_accessor :meta # 0-1 Meta
122
+ attr_accessor :implicitRules # 0-1 uri
123
+ attr_accessor :language # 0-1 code
124
+ attr_accessor :text # 0-1 Narrative
125
+ attr_accessor :contained # 0-* [ Resource ]
126
+ attr_accessor :extension # 0-* [ Extension ]
127
+ attr_accessor :modifierExtension # 0-* [ Extension ]
128
+ attr_accessor :url # 0-1 uri
129
+ attr_accessor :version # 0-1 string
130
+ attr_accessor :name # 1-1 string
131
+ attr_accessor :status # 1-1 code
132
+ attr_accessor :kind # 1-1 code
133
+ attr_accessor :experimental # 0-1 boolean
134
+ attr_accessor :date # 0-1 dateTime
135
+ attr_accessor :publisher # 0-1 string
136
+ attr_accessor :contact # 0-* [ OperationDefinition::Contact ]
137
+ attr_accessor :description # 0-1 string
138
+ attr_accessor :useContext # 0-* [ CodeableConcept ]
139
+ attr_accessor :requirements # 0-1 string
140
+ attr_accessor :idempotent # 0-1 boolean
141
+ attr_accessor :code # 1-1 code
142
+ attr_accessor :comment # 0-1 string
143
+ attr_accessor :base # 0-1 Reference(OperationDefinition)
144
+ attr_accessor :system # 1-1 boolean
145
+ attr_accessor :type # 0-* [ code ]
146
+ attr_accessor :instance # 1-1 boolean
147
+ attr_accessor :parameter # 0-* [ OperationDefinition::Parameter ]
148
+
149
+ def resourceType
150
+ 'OperationDefinition'
151
+ end
152
+ end
153
+ end
@@ -0,0 +1,62 @@
1
+ module FHIR
2
+ class OperationOutcome < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = []
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'OperationOutcome.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'OperationOutcome.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'OperationOutcome.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'OperationOutcome.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'text' => {'type'=>'Narrative', 'path'=>'OperationOutcome.text', 'min'=>0, 'max'=>1},
14
+ 'contained' => {'type'=>'Resource', 'path'=>'OperationOutcome.contained', 'min'=>0, 'max'=>Float::INFINITY},
15
+ 'extension' => {'type'=>'Extension', 'path'=>'OperationOutcome.extension', 'min'=>0, 'max'=>Float::INFINITY},
16
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'OperationOutcome.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
17
+ 'issue' => {'type'=>'OperationOutcome::Issue', 'path'=>'OperationOutcome.issue', 'min'=>1, 'max'=>Float::INFINITY}
18
+ }
19
+
20
+ class Issue < FHIR::Model
21
+ include FHIR::Hashable
22
+ include FHIR::Json
23
+ include FHIR::Xml
24
+
25
+ METADATA = {
26
+ 'id' => {'type'=>'id', 'path'=>'Issue.id', 'min'=>0, 'max'=>1},
27
+ 'extension' => {'type'=>'Extension', 'path'=>'Issue.extension', 'min'=>0, 'max'=>Float::INFINITY},
28
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Issue.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
29
+ 'severity' => {'valid_codes'=>{'http://hl7.org/fhir/issue-severity'=>['fatal', 'error', 'warning', 'information']}, 'type'=>'code', 'path'=>'Issue.severity', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/issue-severity'}},
30
+ 'code' => {'valid_codes'=>{'http://hl7.org/fhir/issue-type'=>['invalid', 'structure', 'required', 'value', 'invariant', 'security', 'login', 'unknown', 'expired', 'forbidden', 'suppressed', 'processing', 'not-supported', 'duplicate', 'not-found', 'too-long', 'code-invalid', 'extension', 'too-costly', 'business-rule', 'conflict', 'incomplete', 'transient', 'lock-error', 'no-store', 'exception', 'timeout', 'throttled', 'informational']}, 'type'=>'code', 'path'=>'Issue.code', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/issue-type'}},
31
+ 'details' => {'valid_codes'=>{'http://hl7.org/fhir/operation-outcome'=>['MSG_AUTH_REQUIRED', 'MSG_BAD_FORMAT', 'MSG_BAD_SYNTAX', 'MSG_CANT_PARSE_CONTENT', 'MSG_CANT_PARSE_ROOT', 'MSG_CREATED', 'MSG_DATE_FORMAT', 'MSG_DELETED', 'MSG_DELETED_DONE', 'MSG_DELETED_ID', 'MSG_DUPLICATE_ID', 'MSG_ERROR_PARSING', 'MSG_ID_INVALID', 'MSG_ID_TOO_LONG', 'MSG_INVALID_ID', 'MSG_JSON_OBJECT', 'MSG_LOCAL_FAIL', 'MSG_NO_MATCH', 'MSG_NO_EXIST', 'MSG_NO_MODULE', 'MSG_NO_SUMMARY', 'MSG_OP_NOT_ALLOWED', 'MSG_PARAM_CHAINED', 'MSG_PARAM_NO_REPEAT', 'MSG_PARAM_UNKNOWN', 'MSG_PARAM_INVALID', 'MSG_PARAM_MODIFIER_INVALID', 'MSG_RESOURCE_EXAMPLE_PROTECTED', 'MSG_RESOURCE_ID_FAIL', 'MSG_RESOURCE_NOT_ALLOWED', 'MSG_RESOURCE_REQUIRED', 'MSG_RESOURCE_ID_MISMATCH', 'MSG_RESOURCE_ID_MISSING', 'MSG_RESOURCE_TYPE_MISMATCH', 'MSG_SORT_UNKNOWN', 'MSG_TRANSACTION_DUPLICATE_ID', 'MSG_TRANSACTION_MISSING_ID', 'MSG_UNHANDLED_NODE_TYPE', 'MSG_UNKNOWN_CONTENT', 'MSG_UNKNOWN_OPERATION', 'MSG_UNKNOWN_TYPE', 'MSG_UPDATED', 'MSG_VERSION_AWARE', 'MSG_VERSION_AWARE_CONFLICT', 'MSG_VERSION_AWARE_URL', 'MSG_WRONG_NS', 'SEARCH_MULTIPLE', 'UPDATE_MULTIPLE_MATCHES', 'SEARCH_NONE']}, 'type'=>'CodeableConcept', 'path'=>'Issue.details', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/operation-outcome'}},
32
+ 'diagnostics' => {'type'=>'string', 'path'=>'Issue.diagnostics', 'min'=>0, 'max'=>1},
33
+ 'location' => {'type'=>'string', 'path'=>'Issue.location', 'min'=>0, 'max'=>Float::INFINITY},
34
+ 'expression' => {'type'=>'string', 'path'=>'Issue.expression', 'min'=>0, 'max'=>Float::INFINITY}
35
+ }
36
+
37
+ attr_accessor :id # 0-1 id
38
+ attr_accessor :extension # 0-* [ Extension ]
39
+ attr_accessor :modifierExtension # 0-* [ Extension ]
40
+ attr_accessor :severity # 1-1 code
41
+ attr_accessor :code # 1-1 code
42
+ attr_accessor :details # 0-1 CodeableConcept
43
+ attr_accessor :diagnostics # 0-1 string
44
+ attr_accessor :location # 0-* [ string ]
45
+ attr_accessor :expression # 0-* [ string ]
46
+ end
47
+
48
+ attr_accessor :id # 0-1 id
49
+ attr_accessor :meta # 0-1 Meta
50
+ attr_accessor :implicitRules # 0-1 uri
51
+ attr_accessor :language # 0-1 code
52
+ attr_accessor :text # 0-1 Narrative
53
+ attr_accessor :contained # 0-* [ Resource ]
54
+ attr_accessor :extension # 0-* [ Extension ]
55
+ attr_accessor :modifierExtension # 0-* [ Extension ]
56
+ attr_accessor :issue # 1-* [ OperationOutcome::Issue ]
57
+
58
+ def resourceType
59
+ 'OperationOutcome'
60
+ end
61
+ end
62
+ end
@@ -0,0 +1,73 @@
1
+ module FHIR
2
+ class Order < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ MULTIPLE_TYPES = {
8
+ 'reason' => ['CodeableConcept', 'Reference']
9
+ }
10
+ SEARCH_PARAMS = ["date", "detail", "identifier", "patient", "source", "subject", "target", "when", "when_code"]
11
+ METADATA = {
12
+ 'id' => {'type'=>'id', 'path'=>'Order.id', 'min'=>0, 'max'=>1},
13
+ 'meta' => {'type'=>'Meta', 'path'=>'Order.meta', 'min'=>0, 'max'=>1},
14
+ 'implicitRules' => {'type'=>'uri', 'path'=>'Order.implicitRules', 'min'=>0, 'max'=>1},
15
+ 'language' => {'type'=>'code', 'path'=>'Order.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
16
+ 'text' => {'type'=>'Narrative', 'path'=>'Order.text', 'min'=>0, 'max'=>1},
17
+ 'contained' => {'type'=>'Resource', 'path'=>'Order.contained', 'min'=>0, 'max'=>Float::INFINITY},
18
+ 'extension' => {'type'=>'Extension', 'path'=>'Order.extension', 'min'=>0, 'max'=>Float::INFINITY},
19
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Order.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
20
+ 'identifier' => {'type'=>'Identifier', 'path'=>'Order.identifier', 'min'=>0, 'max'=>Float::INFINITY},
21
+ 'date' => {'type'=>'dateTime', 'path'=>'Order.date', 'min'=>0, 'max'=>1},
22
+ 'subject' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Group', 'http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Substance'], 'type'=>'Reference', 'path'=>'Order.subject', 'min'=>0, 'max'=>1},
23
+ 'source' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/Organization'], 'type'=>'Reference', 'path'=>'Order.source', 'min'=>0, 'max'=>1},
24
+ 'target' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Practitioner'], 'type'=>'Reference', 'path'=>'Order.target', 'min'=>0, 'max'=>1},
25
+ 'reasonCodeableConcept' => {'type'=>'CodeableConcept', 'path'=>'Order.reason[x]', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
26
+ 'reasonReference' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Resource'], 'type'=>'Reference', 'path'=>'Order.reason[x]', 'min'=>0, 'max'=>1},
27
+ 'when' => {'type'=>'Order::When', 'path'=>'Order.when', 'min'=>0, 'max'=>1},
28
+ 'detail' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Resource'], 'type'=>'Reference', 'path'=>'Order.detail', 'min'=>1, 'max'=>Float::INFINITY}
29
+ }
30
+
31
+ class When < FHIR::Model
32
+ include FHIR::Hashable
33
+ include FHIR::Json
34
+ include FHIR::Xml
35
+
36
+ METADATA = {
37
+ 'id' => {'type'=>'id', 'path'=>'When.id', 'min'=>0, 'max'=>1},
38
+ 'extension' => {'type'=>'Extension', 'path'=>'When.extension', 'min'=>0, 'max'=>Float::INFINITY},
39
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'When.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
40
+ 'code' => {'type'=>'CodeableConcept', 'path'=>'When.code', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
41
+ 'schedule' => {'type'=>'Timing', 'path'=>'When.schedule', 'min'=>0, 'max'=>1}
42
+ }
43
+
44
+ attr_accessor :id # 0-1 id
45
+ attr_accessor :extension # 0-* [ Extension ]
46
+ attr_accessor :modifierExtension # 0-* [ Extension ]
47
+ attr_accessor :code # 0-1 CodeableConcept
48
+ attr_accessor :schedule # 0-1 Timing
49
+ end
50
+
51
+ attr_accessor :id # 0-1 id
52
+ attr_accessor :meta # 0-1 Meta
53
+ attr_accessor :implicitRules # 0-1 uri
54
+ attr_accessor :language # 0-1 code
55
+ attr_accessor :text # 0-1 Narrative
56
+ attr_accessor :contained # 0-* [ Resource ]
57
+ attr_accessor :extension # 0-* [ Extension ]
58
+ attr_accessor :modifierExtension # 0-* [ Extension ]
59
+ attr_accessor :identifier # 0-* [ Identifier ]
60
+ attr_accessor :date # 0-1 dateTime
61
+ attr_accessor :subject # 0-1 Reference(Patient|Group|Device|Substance)
62
+ attr_accessor :source # 0-1 Reference(Practitioner|Organization)
63
+ attr_accessor :target # 0-1 Reference(Organization|Device|Practitioner)
64
+ attr_accessor :reasonCodeableConcept # 0-1 CodeableConcept
65
+ attr_accessor :reasonReference # 0-1 Reference(Resource)
66
+ attr_accessor :when # 0-1 Order::When
67
+ attr_accessor :detail # 1-* [ Reference(Resource) ]
68
+
69
+ def resourceType
70
+ 'Order'
71
+ end
72
+ end
73
+ end
@@ -0,0 +1,46 @@
1
+ module FHIR
2
+ class OrderResponse < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = ["code", "date", "fulfillment", "identifier", "request", "who"]
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'OrderResponse.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'OrderResponse.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'OrderResponse.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'OrderResponse.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'text' => {'type'=>'Narrative', 'path'=>'OrderResponse.text', 'min'=>0, 'max'=>1},
14
+ 'contained' => {'type'=>'Resource', 'path'=>'OrderResponse.contained', 'min'=>0, 'max'=>Float::INFINITY},
15
+ 'extension' => {'type'=>'Extension', 'path'=>'OrderResponse.extension', 'min'=>0, 'max'=>Float::INFINITY},
16
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'OrderResponse.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
17
+ 'identifier' => {'type'=>'Identifier', 'path'=>'OrderResponse.identifier', 'min'=>0, 'max'=>Float::INFINITY},
18
+ 'request' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Order'], 'type'=>'Reference', 'path'=>'OrderResponse.request', 'min'=>1, 'max'=>1},
19
+ 'date' => {'type'=>'dateTime', 'path'=>'OrderResponse.date', 'min'=>0, 'max'=>1},
20
+ 'who' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Device'], 'type'=>'Reference', 'path'=>'OrderResponse.who', 'min'=>0, 'max'=>1},
21
+ 'orderStatus' => {'valid_codes'=>{'http://hl7.org/fhir/order-status'=>['pending', 'review', 'rejected', 'error', 'accepted', 'cancelled', 'replaced', 'aborted', 'completed']}, 'type'=>'code', 'path'=>'OrderResponse.orderStatus', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/order-status'}},
22
+ 'description' => {'type'=>'string', 'path'=>'OrderResponse.description', 'min'=>0, 'max'=>1},
23
+ 'fulfillment' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Resource'], 'type'=>'Reference', 'path'=>'OrderResponse.fulfillment', 'min'=>0, 'max'=>Float::INFINITY}
24
+ }
25
+
26
+ attr_accessor :id # 0-1 id
27
+ attr_accessor :meta # 0-1 Meta
28
+ attr_accessor :implicitRules # 0-1 uri
29
+ attr_accessor :language # 0-1 code
30
+ attr_accessor :text # 0-1 Narrative
31
+ attr_accessor :contained # 0-* [ Resource ]
32
+ attr_accessor :extension # 0-* [ Extension ]
33
+ attr_accessor :modifierExtension # 0-* [ Extension ]
34
+ attr_accessor :identifier # 0-* [ Identifier ]
35
+ attr_accessor :request # 1-1 Reference(Order)
36
+ attr_accessor :date # 0-1 dateTime
37
+ attr_accessor :who # 0-1 Reference(Practitioner|Organization|Device)
38
+ attr_accessor :orderStatus # 1-1 code
39
+ attr_accessor :description # 0-1 string
40
+ attr_accessor :fulfillment # 0-* [ Reference(Resource) ]
41
+
42
+ def resourceType
43
+ 'OrderResponse'
44
+ end
45
+ end
46
+ end
@@ -0,0 +1,38 @@
1
+ module FHIR
2
+ class OrderSet < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = ["description", "identifier", "status", "title", "topic", "version"]
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'OrderSet.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'OrderSet.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'OrderSet.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'OrderSet.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'text' => {'type'=>'Narrative', 'path'=>'OrderSet.text', 'min'=>0, 'max'=>1},
14
+ 'contained' => {'type'=>'Resource', 'path'=>'OrderSet.contained', 'min'=>0, 'max'=>Float::INFINITY},
15
+ 'extension' => {'type'=>'Extension', 'path'=>'OrderSet.extension', 'min'=>0, 'max'=>Float::INFINITY},
16
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'OrderSet.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
17
+ 'moduleMetadata' => {'type'=>'ModuleMetadata', 'path'=>'OrderSet.moduleMetadata', 'min'=>0, 'max'=>1},
18
+ 'library' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Library'], 'type'=>'Reference', 'path'=>'OrderSet.library', 'min'=>0, 'max'=>Float::INFINITY},
19
+ 'action' => {'type'=>'ActionDefinition', 'path'=>'OrderSet.action', 'min'=>0, 'max'=>Float::INFINITY}
20
+ }
21
+
22
+ attr_accessor :id # 0-1 id
23
+ attr_accessor :meta # 0-1 Meta
24
+ attr_accessor :implicitRules # 0-1 uri
25
+ attr_accessor :language # 0-1 code
26
+ attr_accessor :text # 0-1 Narrative
27
+ attr_accessor :contained # 0-* [ Resource ]
28
+ attr_accessor :extension # 0-* [ Extension ]
29
+ attr_accessor :modifierExtension # 0-* [ Extension ]
30
+ attr_accessor :moduleMetadata # 0-1 ModuleMetadata
31
+ attr_accessor :library # 0-* [ Reference(Library) ]
32
+ attr_accessor :action # 0-* [ ActionDefinition ]
33
+
34
+ def resourceType
35
+ 'OrderSet'
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,72 @@
1
+ module FHIR
2
+ class Organization < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = ["active", "address", "address-city", "address-country", "address-postalcode", "address-state", "address-use", "identifier", "name", "partof", "phonetic", "type"]
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'Organization.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'Organization.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'Organization.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'Organization.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'text' => {'type'=>'Narrative', 'path'=>'Organization.text', 'min'=>0, 'max'=>1},
14
+ 'contained' => {'type'=>'Resource', 'path'=>'Organization.contained', 'min'=>0, 'max'=>Float::INFINITY},
15
+ 'extension' => {'type'=>'Extension', 'path'=>'Organization.extension', 'min'=>0, 'max'=>Float::INFINITY},
16
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Organization.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
17
+ 'identifier' => {'type'=>'Identifier', 'path'=>'Organization.identifier', 'min'=>0, 'max'=>Float::INFINITY},
18
+ 'active' => {'type'=>'boolean', 'path'=>'Organization.active', 'min'=>0, 'max'=>1},
19
+ 'type' => {'valid_codes'=>{'http://hl7.org/fhir/organization-type'=>['prov', 'dept', 'team', 'govt', 'ins', 'edu', 'reli', 'crs', 'cg', 'bus', 'other']}, 'type'=>'CodeableConcept', 'path'=>'Organization.type', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/organization-type'}},
20
+ 'name' => {'type'=>'string', 'path'=>'Organization.name', 'min'=>0, 'max'=>1},
21
+ 'telecom' => {'type'=>'ContactPoint', 'path'=>'Organization.telecom', 'min'=>0, 'max'=>Float::INFINITY},
22
+ 'address' => {'type'=>'Address', 'path'=>'Organization.address', 'min'=>0, 'max'=>Float::INFINITY},
23
+ 'partOf' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Organization'], 'type'=>'Reference', 'path'=>'Organization.partOf', 'min'=>0, 'max'=>1},
24
+ 'contact' => {'type'=>'Organization::Contact', 'path'=>'Organization.contact', 'min'=>0, 'max'=>Float::INFINITY}
25
+ }
26
+
27
+ class Contact < FHIR::Model
28
+ include FHIR::Hashable
29
+ include FHIR::Json
30
+ include FHIR::Xml
31
+
32
+ METADATA = {
33
+ 'id' => {'type'=>'id', 'path'=>'Contact.id', 'min'=>0, 'max'=>1},
34
+ 'extension' => {'type'=>'Extension', 'path'=>'Contact.extension', 'min'=>0, 'max'=>Float::INFINITY},
35
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Contact.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
36
+ 'purpose' => {'valid_codes'=>{'http://hl7.org/fhir/contactentity-type'=>['BILL', 'ADMIN', 'HR', 'PAYOR', 'PATINF', 'PRESS']}, 'type'=>'CodeableConcept', 'path'=>'Contact.purpose', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/contactentity-type'}},
37
+ 'name' => {'type'=>'HumanName', 'path'=>'Contact.name', 'min'=>0, 'max'=>1},
38
+ 'telecom' => {'type'=>'ContactPoint', 'path'=>'Contact.telecom', 'min'=>0, 'max'=>Float::INFINITY},
39
+ 'address' => {'type'=>'Address', 'path'=>'Contact.address', 'min'=>0, 'max'=>1}
40
+ }
41
+
42
+ attr_accessor :id # 0-1 id
43
+ attr_accessor :extension # 0-* [ Extension ]
44
+ attr_accessor :modifierExtension # 0-* [ Extension ]
45
+ attr_accessor :purpose # 0-1 CodeableConcept
46
+ attr_accessor :name # 0-1 HumanName
47
+ attr_accessor :telecom # 0-* [ ContactPoint ]
48
+ attr_accessor :address # 0-1 Address
49
+ end
50
+
51
+ attr_accessor :id # 0-1 id
52
+ attr_accessor :meta # 0-1 Meta
53
+ attr_accessor :implicitRules # 0-1 uri
54
+ attr_accessor :language # 0-1 code
55
+ attr_accessor :text # 0-1 Narrative
56
+ attr_accessor :contained # 0-* [ Resource ]
57
+ attr_accessor :extension # 0-* [ Extension ]
58
+ attr_accessor :modifierExtension # 0-* [ Extension ]
59
+ attr_accessor :identifier # 0-* [ Identifier ]
60
+ attr_accessor :active # 0-1 boolean
61
+ attr_accessor :type # 0-1 CodeableConcept
62
+ attr_accessor :name # 0-1 string
63
+ attr_accessor :telecom # 0-* [ ContactPoint ]
64
+ attr_accessor :address # 0-* [ Address ]
65
+ attr_accessor :partOf # 0-1 Reference(Organization)
66
+ attr_accessor :contact # 0-* [ Organization::Contact ]
67
+
68
+ def resourceType
69
+ 'Organization'
70
+ end
71
+ end
72
+ end
@@ -0,0 +1,117 @@
1
+ module FHIR
2
+ class Parameters < FHIR::Model
3
+ include FHIR::Hashable
4
+ include FHIR::Json
5
+ include FHIR::Xml
6
+
7
+ SEARCH_PARAMS = []
8
+ METADATA = {
9
+ 'id' => {'type'=>'id', 'path'=>'Parameters.id', 'min'=>0, 'max'=>1},
10
+ 'meta' => {'type'=>'Meta', 'path'=>'Parameters.meta', 'min'=>0, 'max'=>1},
11
+ 'implicitRules' => {'type'=>'uri', 'path'=>'Parameters.implicitRules', 'min'=>0, 'max'=>1},
12
+ 'language' => {'type'=>'code', 'path'=>'Parameters.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
13
+ 'parameter' => {'type'=>'Parameters::Parameter', 'path'=>'Parameters.parameter', 'min'=>0, 'max'=>Float::INFINITY}
14
+ }
15
+
16
+ class Parameter < FHIR::Model
17
+ include FHIR::Hashable
18
+ include FHIR::Json
19
+ include FHIR::Xml
20
+
21
+ MULTIPLE_TYPES = {
22
+ 'value' => ['boolean', 'integer', 'decimal', 'base64Binary', 'instant', 'string', 'uri', 'date', 'dateTime', 'time', 'code', 'oid', 'id', 'unsignedInt', 'positiveInt', 'markdown', 'Annotation', 'Attachment', 'Identifier', 'CodeableConcept', 'Coding', 'Quantity', 'Range', 'Period', 'Ratio', 'SampledData', 'Signature', 'HumanName', 'Address', 'ContactPoint', 'Timing', 'Reference', 'Meta']
23
+ }
24
+ METADATA = {
25
+ 'id' => {'type'=>'id', 'path'=>'Parameter.id', 'min'=>0, 'max'=>1},
26
+ 'extension' => {'type'=>'Extension', 'path'=>'Parameter.extension', 'min'=>0, 'max'=>Float::INFINITY},
27
+ 'modifierExtension' => {'type'=>'Extension', 'path'=>'Parameter.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
28
+ 'name' => {'type'=>'string', 'path'=>'Parameter.name', 'min'=>1, 'max'=>1},
29
+ 'valueBoolean' => {'type'=>'boolean', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
30
+ 'valueInteger' => {'type'=>'integer', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
31
+ 'valueDecimal' => {'type'=>'decimal', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
32
+ 'valueBase64Binary' => {'type'=>'base64Binary', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
33
+ 'valueInstant' => {'type'=>'instant', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
34
+ 'valueString' => {'type'=>'string', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
35
+ 'valueUri' => {'type'=>'uri', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
36
+ 'valueDate' => {'type'=>'date', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
37
+ 'valueDateTime' => {'type'=>'dateTime', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
38
+ 'valueTime' => {'type'=>'time', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
39
+ 'valueCode' => {'type'=>'code', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
40
+ 'valueOid' => {'type'=>'oid', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
41
+ 'valueId' => {'type'=>'id', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
42
+ 'valueUnsignedInt' => {'type'=>'unsignedInt', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
43
+ 'valuePositiveInt' => {'type'=>'positiveInt', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
44
+ 'valueMarkdown' => {'type'=>'markdown', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
45
+ 'valueAnnotation' => {'type'=>'Annotation', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
46
+ 'valueAttachment' => {'type'=>'Attachment', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
47
+ 'valueIdentifier' => {'type'=>'Identifier', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
48
+ 'valueCodeableConcept' => {'type'=>'CodeableConcept', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
49
+ 'valueCoding' => {'type'=>'Coding', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
50
+ 'valueQuantity' => {'type'=>'Quantity', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
51
+ 'valueRange' => {'type'=>'Range', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
52
+ 'valuePeriod' => {'type'=>'Period', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
53
+ 'valueRatio' => {'type'=>'Ratio', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
54
+ 'valueSampledData' => {'type'=>'SampledData', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
55
+ 'valueSignature' => {'type'=>'Signature', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
56
+ 'valueHumanName' => {'type'=>'HumanName', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
57
+ 'valueAddress' => {'type'=>'Address', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
58
+ 'valueContactPoint' => {'type'=>'ContactPoint', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
59
+ 'valueTiming' => {'type'=>'Timing', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
60
+ 'valueReference' => {'type'=>'Reference', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
61
+ 'valueMeta' => {'type'=>'Meta', 'path'=>'Parameter.value[x]', 'min'=>0, 'max'=>1},
62
+ 'resource' => {'type'=>'Resource', 'path'=>'Parameter.resource', 'min'=>0, 'max'=>1},
63
+ 'part' => {'type'=>'Parameters::Parameter', 'path'=>'Parameter.part', 'min'=>0, 'max'=>Float::INFINITY}
64
+ }
65
+
66
+ attr_accessor :id # 0-1 id
67
+ attr_accessor :extension # 0-* [ Extension ]
68
+ attr_accessor :modifierExtension # 0-* [ Extension ]
69
+ attr_accessor :name # 1-1 string
70
+ attr_accessor :valueBoolean # 0-1 boolean
71
+ attr_accessor :valueInteger # 0-1 integer
72
+ attr_accessor :valueDecimal # 0-1 decimal
73
+ attr_accessor :valueBase64Binary # 0-1 base64Binary
74
+ attr_accessor :valueInstant # 0-1 instant
75
+ attr_accessor :valueString # 0-1 string
76
+ attr_accessor :valueUri # 0-1 uri
77
+ attr_accessor :valueDate # 0-1 date
78
+ attr_accessor :valueDateTime # 0-1 dateTime
79
+ attr_accessor :valueTime # 0-1 time
80
+ attr_accessor :valueCode # 0-1 code
81
+ attr_accessor :valueOid # 0-1 oid
82
+ attr_accessor :valueId # 0-1 id
83
+ attr_accessor :valueUnsignedInt # 0-1 unsignedInt
84
+ attr_accessor :valuePositiveInt # 0-1 positiveInt
85
+ attr_accessor :valueMarkdown # 0-1 markdown
86
+ attr_accessor :valueAnnotation # 0-1 Annotation
87
+ attr_accessor :valueAttachment # 0-1 Attachment
88
+ attr_accessor :valueIdentifier # 0-1 Identifier
89
+ attr_accessor :valueCodeableConcept # 0-1 CodeableConcept
90
+ attr_accessor :valueCoding # 0-1 Coding
91
+ attr_accessor :valueQuantity # 0-1 Quantity
92
+ attr_accessor :valueRange # 0-1 Range
93
+ attr_accessor :valuePeriod # 0-1 Period
94
+ attr_accessor :valueRatio # 0-1 Ratio
95
+ attr_accessor :valueSampledData # 0-1 SampledData
96
+ attr_accessor :valueSignature # 0-1 Signature
97
+ attr_accessor :valueHumanName # 0-1 HumanName
98
+ attr_accessor :valueAddress # 0-1 Address
99
+ attr_accessor :valueContactPoint # 0-1 ContactPoint
100
+ attr_accessor :valueTiming # 0-1 Timing
101
+ attr_accessor :valueReference # 0-1 Reference()
102
+ attr_accessor :valueMeta # 0-1 Meta
103
+ attr_accessor :resource # 0-1 Resource
104
+ attr_accessor :part # 0-* [ Parameters::Parameter ]
105
+ end
106
+
107
+ attr_accessor :id # 0-1 id
108
+ attr_accessor :meta # 0-1 Meta
109
+ attr_accessor :implicitRules # 0-1 uri
110
+ attr_accessor :language # 0-1 code
111
+ attr_accessor :parameter # 0-* [ Parameters::Parameter ]
112
+
113
+ def resourceType
114
+ 'Parameters'
115
+ end
116
+ end
117
+ end