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.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.travis.yml +0 -1
- data/Gemfile.lock +1 -1
- data/Rakefile +0 -1
- data/fhir_models.gemspec +1 -1
- data/lib/fhir/metadata.rb +25 -0
- data/lib/fhir/resources/Account.rb +54 -0
- data/lib/fhir/resources/AllergyIntolerance.rb +92 -0
- data/lib/fhir/resources/Appointment.rb +88 -0
- data/lib/fhir/resources/AppointmentResponse.rb +48 -0
- data/lib/fhir/resources/AuditEvent.rb +188 -0
- data/lib/fhir/resources/Basic.rb +42 -0
- data/lib/fhir/resources/Binary.rb +28 -0
- data/lib/fhir/resources/BodySite.rb +44 -0
- data/lib/fhir/resources/Bundle.rb +154 -0
- data/lib/fhir/resources/CarePlan.rb +184 -0
- data/lib/fhir/resources/CareTeam.rb +70 -0
- data/lib/fhir/resources/Claim.rb +490 -0
- data/lib/fhir/resources/ClaimResponse.rb +421 -0
- data/lib/fhir/resources/ClinicalImpression.rb +131 -0
- data/lib/fhir/resources/CodeSystem.rb +225 -0
- data/lib/fhir/resources/Communication.rb +83 -0
- data/lib/fhir/resources/CommunicationRequest.rb +90 -0
- data/lib/fhir/resources/CompartmentDefinition.rb +98 -0
- data/lib/fhir/resources/Composition.rb +136 -0
- data/lib/fhir/resources/ConceptMap.rb +168 -0
- data/lib/fhir/resources/Condition.rb +126 -0
- data/lib/fhir/resources/Conformance.rb +442 -0
- data/lib/fhir/resources/Contract.rb +320 -0
- data/lib/fhir/resources/Coverage.rb +77 -0
- data/lib/fhir/resources/DataElement.rb +104 -0
- data/lib/fhir/resources/DecisionSupportRule.rb +42 -0
- data/lib/fhir/resources/DecisionSupportServiceModule.rb +40 -0
- data/lib/fhir/resources/DetectedIssue.rb +74 -0
- data/lib/fhir/resources/Device.rb +64 -0
- data/lib/fhir/resources/DeviceComponent.rb +74 -0
- data/lib/fhir/resources/DeviceMetric.rb +74 -0
- data/lib/fhir/resources/DeviceUseRequest.rb +68 -0
- data/lib/fhir/resources/DeviceUseStatement.rb +60 -0
- data/lib/fhir/resources/DiagnosticOrder.rb +106 -0
- data/lib/fhir/resources/DiagnosticReport.rb +91 -0
- data/lib/fhir/resources/DocumentManifest.rb +99 -0
- data/lib/fhir/resources/DocumentReference.rb +156 -0
- data/lib/fhir/resources/DomainResource.rb +32 -0
- data/lib/fhir/resources/EligibilityRequest.rb +90 -0
- data/lib/fhir/resources/EligibilityResponse.rb +152 -0
- data/lib/fhir/resources/Encounter.rb +172 -0
- data/lib/fhir/resources/EnrollmentRequest.rb +52 -0
- data/lib/fhir/resources/EnrollmentResponse.rb +52 -0
- data/lib/fhir/resources/EpisodeOfCare.rb +74 -0
- data/lib/fhir/resources/ExpansionProfile.rb +284 -0
- data/lib/fhir/resources/ExplanationOfBenefit.rb +764 -0
- data/lib/fhir/resources/FamilyMemberHistory.rb +110 -0
- data/lib/fhir/resources/Flag.rb +48 -0
- data/lib/fhir/resources/Goal.rb +91 -0
- data/lib/fhir/resources/Group.rb +105 -0
- data/lib/fhir/resources/GuidanceResponse.rb +139 -0
- data/lib/fhir/resources/HealthcareService.rb +122 -0
- data/lib/fhir/resources/ImagingExcerpt.rb +210 -0
- data/lib/fhir/resources/ImagingObjectSelection.rb +136 -0
- data/lib/fhir/resources/ImagingStudy.rb +130 -0
- data/lib/fhir/resources/Immunization.rb +148 -0
- data/lib/fhir/resources/ImmunizationRecommendation.rb +114 -0
- data/lib/fhir/resources/ImplementationGuide.rb +211 -0
- data/lib/fhir/resources/Library.rb +145 -0
- data/lib/fhir/resources/Linkage.rb +56 -0
- data/lib/fhir/resources/List.rb +82 -0
- data/lib/fhir/resources/Location.rb +78 -0
- data/lib/fhir/resources/Measure.rb +160 -0
- data/lib/fhir/resources/MeasureReport.rb +204 -0
- data/lib/fhir/resources/Media.rb +56 -0
- data/lib/fhir/resources/Medication.rb +154 -0
- data/lib/fhir/resources/MedicationAdministration.rb +104 -0
- data/lib/fhir/resources/MedicationDispense.rb +141 -0
- data/lib/fhir/resources/MedicationOrder.rb +172 -0
- data/lib/fhir/resources/MedicationStatement.rb +117 -0
- data/lib/fhir/resources/MessageHeader.rb +124 -0
- data/lib/fhir/resources/ModuleDefinition.rb +249 -0
- data/lib/fhir/resources/NamingSystem.rb +102 -0
- data/lib/fhir/resources/NutritionOrder.rb +211 -0
- data/lib/fhir/resources/Observation.rb +187 -0
- data/lib/fhir/resources/OperationDefinition.rb +153 -0
- data/lib/fhir/resources/OperationOutcome.rb +62 -0
- data/lib/fhir/resources/Order.rb +73 -0
- data/lib/fhir/resources/OrderResponse.rb +46 -0
- data/lib/fhir/resources/OrderSet.rb +38 -0
- data/lib/fhir/resources/Organization.rb +72 -0
- data/lib/fhir/resources/Parameters.rb +117 -0
- data/lib/fhir/resources/Patient.rb +166 -0
- data/lib/fhir/resources/PaymentNotice.rb +71 -0
- data/lib/fhir/resources/PaymentReconciliation.rb +140 -0
- data/lib/fhir/resources/Person.rb +72 -0
- data/lib/fhir/resources/Practitioner.rb +110 -0
- data/lib/fhir/resources/PractitionerRole.rb +102 -0
- data/lib/fhir/resources/Procedure.rb +122 -0
- data/lib/fhir/resources/ProcedureRequest.rb +73 -0
- data/lib/fhir/resources/ProcessRequest.rb +99 -0
- data/lib/fhir/resources/ProcessResponse.rb +92 -0
- data/lib/fhir/resources/Protocol.rb +242 -0
- data/lib/fhir/resources/Provenance.rb +122 -0
- data/lib/fhir/resources/Questionnaire.rb +205 -0
- data/lib/fhir/resources/QuestionnaireResponse.rb +123 -0
- data/lib/fhir/resources/ReferralRequest.rb +68 -0
- data/lib/fhir/resources/RelatedPerson.rb +52 -0
- data/lib/fhir/resources/Resource.rb +24 -0
- data/lib/fhir/resources/RiskAssessment.rb +88 -0
- data/lib/fhir/resources/Schedule.rb +46 -0
- data/lib/fhir/resources/SearchParameter.rb +86 -0
- data/lib/fhir/resources/Sequence.rb +238 -0
- data/lib/fhir/resources/Slot.rb +54 -0
- data/lib/fhir/resources/Specimen.rb +140 -0
- data/lib/fhir/resources/StructureDefinition.rb +164 -0
- data/lib/fhir/resources/StructureMap.rb +297 -0
- data/lib/fhir/resources/Subscription.rb +72 -0
- data/lib/fhir/resources/Substance.rb +86 -0
- data/lib/fhir/resources/SupplyDelivery.rb +54 -0
- data/lib/fhir/resources/SupplyRequest.rb +77 -0
- data/lib/fhir/resources/Task.rb +240 -0
- data/lib/fhir/resources/TestScript.rb +692 -0
- data/lib/fhir/resources/ValueSet.rb +289 -0
- data/lib/fhir/resources/VisionPrescription.rb +97 -0
- data/lib/fhir/types/ActionDefinition.rb +109 -0
- data/lib/fhir/types/Address.rb +36 -0
- data/lib/fhir/types/Annotation.rb +27 -0
- data/lib/fhir/types/Attachment.rb +32 -0
- data/lib/fhir/types/BackboneElement.rb +18 -0
- data/lib/fhir/types/CodeableConcept.rb +20 -0
- data/lib/fhir/types/Coding.rb +26 -0
- data/lib/fhir/types/ContactPoint.rb +26 -0
- data/lib/fhir/types/DataRequirement.rb +78 -0
- data/lib/fhir/types/Element.rb +16 -0
- data/lib/fhir/types/ElementDefinition.rb +605 -0
- data/lib/fhir/types/Extension.rb +87 -0
- data/lib/fhir/types/HumanName.rb +30 -0
- data/lib/fhir/types/Identifier.rb +28 -0
- data/lib/fhir/types/Meta.rb +26 -0
- data/lib/fhir/types/ModuleMetadata.rb +152 -0
- data/lib/fhir/types/Narrative.rb +20 -0
- data/lib/fhir/types/ParameterDefinition.rb +30 -0
- data/lib/fhir/types/Period.rb +20 -0
- data/lib/fhir/types/Quantity.rb +26 -0
- data/lib/fhir/types/Range.rb +20 -0
- data/lib/fhir/types/Ratio.rb +20 -0
- data/lib/fhir/types/Reference.rb +20 -0
- data/lib/fhir/types/SampledData.rb +30 -0
- data/lib/fhir/types/Signature.rb +31 -0
- data/lib/fhir/types/Timing.rb +69 -0
- data/lib/fhir/types/TriggerDefinition.rb +33 -0
- data/lib/fhir_models.rb +2 -2
- data/lib/tasks/tasks.rake +29 -0
- metadata +145 -2
@@ -0,0 +1,225 @@
|
|
1
|
+
module FHIR
|
2
|
+
class CodeSystem < FHIR::Model
|
3
|
+
include FHIR::Hashable
|
4
|
+
include FHIR::Json
|
5
|
+
include FHIR::Xml
|
6
|
+
|
7
|
+
SEARCH_PARAMS = ["code", "context", "date", "description", "identifier", "language", "name", "publisher", "status", "system", "url", "version"]
|
8
|
+
METADATA = {
|
9
|
+
'id' => {'type'=>'id', 'path'=>'CodeSystem.id', 'min'=>0, 'max'=>1},
|
10
|
+
'meta' => {'type'=>'Meta', 'path'=>'CodeSystem.meta', 'min'=>0, 'max'=>1},
|
11
|
+
'implicitRules' => {'type'=>'uri', 'path'=>'CodeSystem.implicitRules', 'min'=>0, 'max'=>1},
|
12
|
+
'language' => {'type'=>'code', 'path'=>'CodeSystem.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
|
13
|
+
'text' => {'type'=>'Narrative', 'path'=>'CodeSystem.text', 'min'=>0, 'max'=>1},
|
14
|
+
'contained' => {'type'=>'Resource', 'path'=>'CodeSystem.contained', 'min'=>0, 'max'=>Float::INFINITY},
|
15
|
+
'extension' => {'type'=>'Extension', 'path'=>'CodeSystem.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
16
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'CodeSystem.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
17
|
+
'url' => {'type'=>'uri', 'path'=>'CodeSystem.url', 'min'=>0, 'max'=>1},
|
18
|
+
'identifier' => {'type'=>'Identifier', 'path'=>'CodeSystem.identifier', 'min'=>0, 'max'=>1},
|
19
|
+
'version' => {'type'=>'string', 'path'=>'CodeSystem.version', 'min'=>0, 'max'=>1},
|
20
|
+
'name' => {'type'=>'string', 'path'=>'CodeSystem.name', 'min'=>0, 'max'=>1},
|
21
|
+
'status' => {'valid_codes'=>{'http://hl7.org/fhir/conformance-resource-status'=>['draft', 'active', 'retired']}, 'type'=>'code', 'path'=>'CodeSystem.status', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/conformance-resource-status'}},
|
22
|
+
'experimental' => {'type'=>'boolean', 'path'=>'CodeSystem.experimental', 'min'=>0, 'max'=>1},
|
23
|
+
'publisher' => {'type'=>'string', 'path'=>'CodeSystem.publisher', 'min'=>0, 'max'=>1},
|
24
|
+
'contact' => {'type'=>'CodeSystem::Contact', 'path'=>'CodeSystem.contact', 'min'=>0, 'max'=>Float::INFINITY},
|
25
|
+
'date' => {'type'=>'dateTime', 'path'=>'CodeSystem.date', 'min'=>0, 'max'=>1},
|
26
|
+
'description' => {'type'=>'string', 'path'=>'CodeSystem.description', 'min'=>0, 'max'=>1},
|
27
|
+
'useContext' => {'type'=>'CodeableConcept', 'path'=>'CodeSystem.useContext', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/use-context'}},
|
28
|
+
'requirements' => {'type'=>'string', 'path'=>'CodeSystem.requirements', 'min'=>0, 'max'=>1},
|
29
|
+
'copyright' => {'type'=>'string', 'path'=>'CodeSystem.copyright', 'min'=>0, 'max'=>1},
|
30
|
+
'caseSensitive' => {'type'=>'boolean', 'path'=>'CodeSystem.caseSensitive', 'min'=>0, 'max'=>1},
|
31
|
+
'valueSet' => {'type'=>'uri', 'path'=>'CodeSystem.valueSet', 'min'=>0, 'max'=>1},
|
32
|
+
'compositional' => {'type'=>'boolean', 'path'=>'CodeSystem.compositional', 'min'=>0, 'max'=>1},
|
33
|
+
'versionNeeded' => {'type'=>'boolean', 'path'=>'CodeSystem.versionNeeded', 'min'=>0, 'max'=>1},
|
34
|
+
'content' => {'valid_codes'=>{'http://hl7.org/fhir/codesystem-content-mode'=>['not-present', 'examplar', 'fragment', 'complete']}, 'type'=>'code', 'path'=>'CodeSystem.content', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/codesystem-content-mode'}},
|
35
|
+
'count' => {'type'=>'unsignedInt', 'path'=>'CodeSystem.count', 'min'=>0, 'max'=>1},
|
36
|
+
'filter' => {'type'=>'CodeSystem::Filter', 'path'=>'CodeSystem.filter', 'min'=>0, 'max'=>Float::INFINITY},
|
37
|
+
'property' => {'type'=>'CodeSystem::Property', 'path'=>'CodeSystem.property', 'min'=>0, 'max'=>Float::INFINITY},
|
38
|
+
'concept' => {'type'=>'CodeSystem::Concept', 'path'=>'CodeSystem.concept', 'min'=>0, 'max'=>Float::INFINITY}
|
39
|
+
}
|
40
|
+
|
41
|
+
class Contact < FHIR::Model
|
42
|
+
include FHIR::Hashable
|
43
|
+
include FHIR::Json
|
44
|
+
include FHIR::Xml
|
45
|
+
|
46
|
+
METADATA = {
|
47
|
+
'id' => {'type'=>'id', 'path'=>'Contact.id', 'min'=>0, 'max'=>1},
|
48
|
+
'extension' => {'type'=>'Extension', 'path'=>'Contact.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
49
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Contact.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
50
|
+
'name' => {'type'=>'string', 'path'=>'Contact.name', 'min'=>0, 'max'=>1},
|
51
|
+
'telecom' => {'type'=>'ContactPoint', 'path'=>'Contact.telecom', 'min'=>0, 'max'=>Float::INFINITY}
|
52
|
+
}
|
53
|
+
|
54
|
+
attr_accessor :id # 0-1 id
|
55
|
+
attr_accessor :extension # 0-* [ Extension ]
|
56
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
57
|
+
attr_accessor :name # 0-1 string
|
58
|
+
attr_accessor :telecom # 0-* [ ContactPoint ]
|
59
|
+
end
|
60
|
+
|
61
|
+
class Filter < FHIR::Model
|
62
|
+
include FHIR::Hashable
|
63
|
+
include FHIR::Json
|
64
|
+
include FHIR::Xml
|
65
|
+
|
66
|
+
METADATA = {
|
67
|
+
'id' => {'type'=>'id', 'path'=>'Filter.id', 'min'=>0, 'max'=>1},
|
68
|
+
'extension' => {'type'=>'Extension', 'path'=>'Filter.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
69
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Filter.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
70
|
+
'code' => {'type'=>'code', 'path'=>'Filter.code', 'min'=>1, 'max'=>1},
|
71
|
+
'description' => {'type'=>'string', 'path'=>'Filter.description', 'min'=>0, 'max'=>1},
|
72
|
+
'operator' => {'valid_codes'=>{'http://hl7.org/fhir/filter-operator'=>['=', 'is-a', 'is-not-a', 'regex', 'in', 'not-in']}, 'type'=>'code', 'path'=>'Filter.operator', 'min'=>1, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/filter-operator'}},
|
73
|
+
'value' => {'type'=>'string', 'path'=>'Filter.value', 'min'=>1, 'max'=>1}
|
74
|
+
}
|
75
|
+
|
76
|
+
attr_accessor :id # 0-1 id
|
77
|
+
attr_accessor :extension # 0-* [ Extension ]
|
78
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
79
|
+
attr_accessor :code # 1-1 code
|
80
|
+
attr_accessor :description # 0-1 string
|
81
|
+
attr_accessor :operator # 1-* [ code ]
|
82
|
+
attr_accessor :value # 1-1 string
|
83
|
+
end
|
84
|
+
|
85
|
+
class Property < FHIR::Model
|
86
|
+
include FHIR::Hashable
|
87
|
+
include FHIR::Json
|
88
|
+
include FHIR::Xml
|
89
|
+
|
90
|
+
METADATA = {
|
91
|
+
'id' => {'type'=>'id', 'path'=>'Property.id', 'min'=>0, 'max'=>1},
|
92
|
+
'extension' => {'type'=>'Extension', 'path'=>'Property.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
93
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Property.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
94
|
+
'code' => {'type'=>'code', 'path'=>'Property.code', 'min'=>1, 'max'=>1},
|
95
|
+
'description' => {'type'=>'string', 'path'=>'Property.description', 'min'=>0, 'max'=>1},
|
96
|
+
'type' => {'valid_codes'=>{'http://hl7.org/fhir/concept-property-type'=>['code', 'Coding', 'string', 'integer', 'boolean', 'dateTime']}, 'type'=>'code', 'path'=>'Property.type', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/concept-property-type'}}
|
97
|
+
}
|
98
|
+
|
99
|
+
attr_accessor :id # 0-1 id
|
100
|
+
attr_accessor :extension # 0-* [ Extension ]
|
101
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
102
|
+
attr_accessor :code # 1-1 code
|
103
|
+
attr_accessor :description # 0-1 string
|
104
|
+
attr_accessor :type # 1-1 code
|
105
|
+
end
|
106
|
+
|
107
|
+
class Concept < FHIR::Model
|
108
|
+
include FHIR::Hashable
|
109
|
+
include FHIR::Json
|
110
|
+
include FHIR::Xml
|
111
|
+
|
112
|
+
METADATA = {
|
113
|
+
'id' => {'type'=>'id', 'path'=>'Concept.id', 'min'=>0, 'max'=>1},
|
114
|
+
'extension' => {'type'=>'Extension', 'path'=>'Concept.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
115
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Concept.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
116
|
+
'code' => {'type'=>'code', 'path'=>'Concept.code', 'min'=>1, 'max'=>1},
|
117
|
+
'display' => {'type'=>'string', 'path'=>'Concept.display', 'min'=>0, 'max'=>1},
|
118
|
+
'definition' => {'type'=>'string', 'path'=>'Concept.definition', 'min'=>0, 'max'=>1},
|
119
|
+
'designation' => {'type'=>'CodeSystem::Concept::Designation', 'path'=>'Concept.designation', 'min'=>0, 'max'=>Float::INFINITY},
|
120
|
+
'property' => {'type'=>'CodeSystem::Concept::Property', 'path'=>'Concept.property', 'min'=>0, 'max'=>Float::INFINITY},
|
121
|
+
'concept' => {'type'=>'CodeSystem::Concept', 'path'=>'Concept.concept', 'min'=>0, 'max'=>Float::INFINITY}
|
122
|
+
}
|
123
|
+
|
124
|
+
class Designation < FHIR::Model
|
125
|
+
include FHIR::Hashable
|
126
|
+
include FHIR::Json
|
127
|
+
include FHIR::Xml
|
128
|
+
|
129
|
+
METADATA = {
|
130
|
+
'id' => {'type'=>'id', 'path'=>'Designation.id', 'min'=>0, 'max'=>1},
|
131
|
+
'extension' => {'type'=>'Extension', 'path'=>'Designation.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
132
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Designation.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
133
|
+
'language' => {'type'=>'code', 'path'=>'Designation.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
|
134
|
+
'use' => {'valid_codes'=>{'http://snomed.info/sct'=>['900000000000003001', '900000000000013009', '900000000000550004']}, 'type'=>'Coding', 'path'=>'Designation.use', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/designation-use'}},
|
135
|
+
'value' => {'type'=>'string', 'path'=>'Designation.value', 'min'=>1, 'max'=>1}
|
136
|
+
}
|
137
|
+
|
138
|
+
attr_accessor :id # 0-1 id
|
139
|
+
attr_accessor :extension # 0-* [ Extension ]
|
140
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
141
|
+
attr_accessor :language # 0-1 code
|
142
|
+
attr_accessor :use # 0-1 Coding
|
143
|
+
attr_accessor :value # 1-1 string
|
144
|
+
end
|
145
|
+
|
146
|
+
class Property < FHIR::Model
|
147
|
+
include FHIR::Hashable
|
148
|
+
include FHIR::Json
|
149
|
+
include FHIR::Xml
|
150
|
+
|
151
|
+
MULTIPLE_TYPES = {
|
152
|
+
'value' => ['code', 'Coding', 'string', 'integer', 'boolean', 'dateTime']
|
153
|
+
}
|
154
|
+
METADATA = {
|
155
|
+
'id' => {'type'=>'id', 'path'=>'Property.id', 'min'=>0, 'max'=>1},
|
156
|
+
'extension' => {'type'=>'Extension', 'path'=>'Property.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
157
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Property.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
158
|
+
'code' => {'type'=>'code', 'path'=>'Property.code', 'min'=>1, 'max'=>1},
|
159
|
+
'valueCode' => {'type'=>'code', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1},
|
160
|
+
'valueCoding' => {'type'=>'Coding', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1},
|
161
|
+
'valueString' => {'type'=>'string', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1},
|
162
|
+
'valueInteger' => {'type'=>'integer', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1},
|
163
|
+
'valueBoolean' => {'type'=>'boolean', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1},
|
164
|
+
'valueDateTime' => {'type'=>'dateTime', 'path'=>'Property.value[x]', 'min'=>1, 'max'=>1}
|
165
|
+
}
|
166
|
+
|
167
|
+
attr_accessor :id # 0-1 id
|
168
|
+
attr_accessor :extension # 0-* [ Extension ]
|
169
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
170
|
+
attr_accessor :code # 1-1 code
|
171
|
+
attr_accessor :valueCode # 1-1 code
|
172
|
+
attr_accessor :valueCoding # 1-1 Coding
|
173
|
+
attr_accessor :valueString # 1-1 string
|
174
|
+
attr_accessor :valueInteger # 1-1 integer
|
175
|
+
attr_accessor :valueBoolean # 1-1 boolean
|
176
|
+
attr_accessor :valueDateTime # 1-1 dateTime
|
177
|
+
end
|
178
|
+
|
179
|
+
attr_accessor :id # 0-1 id
|
180
|
+
attr_accessor :extension # 0-* [ Extension ]
|
181
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
182
|
+
attr_accessor :code # 1-1 code
|
183
|
+
attr_accessor :display # 0-1 string
|
184
|
+
attr_accessor :definition # 0-1 string
|
185
|
+
attr_accessor :designation # 0-* [ CodeSystem::Concept::Designation ]
|
186
|
+
attr_accessor :property # 0-* [ CodeSystem::Concept::Property ]
|
187
|
+
attr_accessor :concept # 0-* [ CodeSystem::Concept ]
|
188
|
+
end
|
189
|
+
|
190
|
+
attr_accessor :id # 0-1 id
|
191
|
+
attr_accessor :meta # 0-1 Meta
|
192
|
+
attr_accessor :implicitRules # 0-1 uri
|
193
|
+
attr_accessor :language # 0-1 code
|
194
|
+
attr_accessor :text # 0-1 Narrative
|
195
|
+
attr_accessor :contained # 0-* [ Resource ]
|
196
|
+
attr_accessor :extension # 0-* [ Extension ]
|
197
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
198
|
+
attr_accessor :url # 0-1 uri
|
199
|
+
attr_accessor :identifier # 0-1 Identifier
|
200
|
+
attr_accessor :version # 0-1 string
|
201
|
+
attr_accessor :name # 0-1 string
|
202
|
+
attr_accessor :status # 1-1 code
|
203
|
+
attr_accessor :experimental # 0-1 boolean
|
204
|
+
attr_accessor :publisher # 0-1 string
|
205
|
+
attr_accessor :contact # 0-* [ CodeSystem::Contact ]
|
206
|
+
attr_accessor :date # 0-1 dateTime
|
207
|
+
attr_accessor :description # 0-1 string
|
208
|
+
attr_accessor :useContext # 0-* [ CodeableConcept ]
|
209
|
+
attr_accessor :requirements # 0-1 string
|
210
|
+
attr_accessor :copyright # 0-1 string
|
211
|
+
attr_accessor :caseSensitive # 0-1 boolean
|
212
|
+
attr_accessor :valueSet # 0-1 uri
|
213
|
+
attr_accessor :compositional # 0-1 boolean
|
214
|
+
attr_accessor :versionNeeded # 0-1 boolean
|
215
|
+
attr_accessor :content # 1-1 code
|
216
|
+
attr_accessor :count # 0-1 unsignedInt
|
217
|
+
attr_accessor :filter # 0-* [ CodeSystem::Filter ]
|
218
|
+
attr_accessor :property # 0-* [ CodeSystem::Property ]
|
219
|
+
attr_accessor :concept # 0-* [ CodeSystem::Concept ]
|
220
|
+
|
221
|
+
def resourceType
|
222
|
+
'CodeSystem'
|
223
|
+
end
|
224
|
+
end
|
225
|
+
end
|
@@ -0,0 +1,83 @@
|
|
1
|
+
module FHIR
|
2
|
+
class Communication < FHIR::Model
|
3
|
+
include FHIR::Hashable
|
4
|
+
include FHIR::Json
|
5
|
+
include FHIR::Xml
|
6
|
+
|
7
|
+
SEARCH_PARAMS = ["category", "encounter", "identifier", "medium", "patient", "received", "recipient", "request", "sender", "sent", "status", "subject"]
|
8
|
+
METADATA = {
|
9
|
+
'id' => {'type'=>'id', 'path'=>'Communication.id', 'min'=>0, 'max'=>1},
|
10
|
+
'meta' => {'type'=>'Meta', 'path'=>'Communication.meta', 'min'=>0, 'max'=>1},
|
11
|
+
'implicitRules' => {'type'=>'uri', 'path'=>'Communication.implicitRules', 'min'=>0, 'max'=>1},
|
12
|
+
'language' => {'type'=>'code', 'path'=>'Communication.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
|
13
|
+
'text' => {'type'=>'Narrative', 'path'=>'Communication.text', 'min'=>0, 'max'=>1},
|
14
|
+
'contained' => {'type'=>'Resource', 'path'=>'Communication.contained', 'min'=>0, 'max'=>Float::INFINITY},
|
15
|
+
'extension' => {'type'=>'Extension', 'path'=>'Communication.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
16
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Communication.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
17
|
+
'identifier' => {'type'=>'Identifier', 'path'=>'Communication.identifier', 'min'=>0, 'max'=>Float::INFINITY},
|
18
|
+
'category' => {'type'=>'CodeableConcept', 'path'=>'Communication.category', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
|
19
|
+
'sender' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson'], 'type'=>'Reference', 'path'=>'Communication.sender', 'min'=>0, 'max'=>1},
|
20
|
+
'recipient' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson', 'http://hl7.org/fhir/StructureDefinition/Group'], 'type'=>'Reference', 'path'=>'Communication.recipient', 'min'=>0, 'max'=>Float::INFINITY},
|
21
|
+
'payload' => {'type'=>'Communication::Payload', 'path'=>'Communication.payload', 'min'=>0, 'max'=>Float::INFINITY},
|
22
|
+
'medium' => {'valid_codes'=>{'http://hl7.org/fhir/v3/ParticipationMode'=>['ELECTRONIC', 'PHYSICAL', 'REMOTE', 'VERBAL', 'DICTATE', 'FACE', 'PHONE', 'VIDEOCONF', 'WRITTEN', 'FAXWRIT', 'HANDWRIT', 'MAILWRIT', 'ONLINEWRIT', 'EMAILWRIT', 'TYPEWRIT']}, 'type'=>'CodeableConcept', 'path'=>'Communication.medium', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/v3-ParticipationMode'}},
|
23
|
+
'status' => {'valid_codes'=>{'http://hl7.org/fhir/communication-status'=>['in-progress', 'completed', 'suspended', 'rejected', 'failed']}, 'type'=>'code', 'path'=>'Communication.status', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/communication-status'}},
|
24
|
+
'encounter' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Encounter'], 'type'=>'Reference', 'path'=>'Communication.encounter', 'min'=>0, 'max'=>1},
|
25
|
+
'sent' => {'type'=>'dateTime', 'path'=>'Communication.sent', 'min'=>0, 'max'=>1},
|
26
|
+
'received' => {'type'=>'dateTime', 'path'=>'Communication.received', 'min'=>0, 'max'=>1},
|
27
|
+
'reason' => {'type'=>'CodeableConcept', 'path'=>'Communication.reason', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
|
28
|
+
'subject' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Patient'], 'type'=>'Reference', 'path'=>'Communication.subject', 'min'=>0, 'max'=>1},
|
29
|
+
'requestDetail' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/CommunicationRequest'], 'type'=>'Reference', 'path'=>'Communication.requestDetail', 'min'=>0, 'max'=>1}
|
30
|
+
}
|
31
|
+
|
32
|
+
class Payload < FHIR::Model
|
33
|
+
include FHIR::Hashable
|
34
|
+
include FHIR::Json
|
35
|
+
include FHIR::Xml
|
36
|
+
|
37
|
+
MULTIPLE_TYPES = {
|
38
|
+
'content' => ['string', 'Attachment', 'Reference']
|
39
|
+
}
|
40
|
+
METADATA = {
|
41
|
+
'id' => {'type'=>'id', 'path'=>'Payload.id', 'min'=>0, 'max'=>1},
|
42
|
+
'extension' => {'type'=>'Extension', 'path'=>'Payload.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
43
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Payload.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
44
|
+
'contentString' => {'type'=>'string', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1},
|
45
|
+
'contentAttachment' => {'type'=>'Attachment', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1},
|
46
|
+
'contentReference' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Resource'], 'type'=>'Reference', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1}
|
47
|
+
}
|
48
|
+
|
49
|
+
attr_accessor :id # 0-1 id
|
50
|
+
attr_accessor :extension # 0-* [ Extension ]
|
51
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
52
|
+
attr_accessor :contentString # 1-1 string
|
53
|
+
attr_accessor :contentAttachment # 1-1 Attachment
|
54
|
+
attr_accessor :contentReference # 1-1 Reference(Resource)
|
55
|
+
end
|
56
|
+
|
57
|
+
attr_accessor :id # 0-1 id
|
58
|
+
attr_accessor :meta # 0-1 Meta
|
59
|
+
attr_accessor :implicitRules # 0-1 uri
|
60
|
+
attr_accessor :language # 0-1 code
|
61
|
+
attr_accessor :text # 0-1 Narrative
|
62
|
+
attr_accessor :contained # 0-* [ Resource ]
|
63
|
+
attr_accessor :extension # 0-* [ Extension ]
|
64
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
65
|
+
attr_accessor :identifier # 0-* [ Identifier ]
|
66
|
+
attr_accessor :category # 0-1 CodeableConcept
|
67
|
+
attr_accessor :sender # 0-1 Reference(Device|Organization|Patient|Practitioner|RelatedPerson)
|
68
|
+
attr_accessor :recipient # 0-* [ Reference(Device|Organization|Patient|Practitioner|RelatedPerson|Group) ]
|
69
|
+
attr_accessor :payload # 0-* [ Communication::Payload ]
|
70
|
+
attr_accessor :medium # 0-* [ CodeableConcept ]
|
71
|
+
attr_accessor :status # 0-1 code
|
72
|
+
attr_accessor :encounter # 0-1 Reference(Encounter)
|
73
|
+
attr_accessor :sent # 0-1 dateTime
|
74
|
+
attr_accessor :received # 0-1 dateTime
|
75
|
+
attr_accessor :reason # 0-* [ CodeableConcept ]
|
76
|
+
attr_accessor :subject # 0-1 Reference(Patient)
|
77
|
+
attr_accessor :requestDetail # 0-1 Reference(CommunicationRequest)
|
78
|
+
|
79
|
+
def resourceType
|
80
|
+
'Communication'
|
81
|
+
end
|
82
|
+
end
|
83
|
+
end
|
@@ -0,0 +1,90 @@
|
|
1
|
+
module FHIR
|
2
|
+
class CommunicationRequest < FHIR::Model
|
3
|
+
include FHIR::Hashable
|
4
|
+
include FHIR::Json
|
5
|
+
include FHIR::Xml
|
6
|
+
|
7
|
+
MULTIPLE_TYPES = {
|
8
|
+
'scheduled' => ['dateTime', 'Period']
|
9
|
+
}
|
10
|
+
SEARCH_PARAMS = ["category", "encounter", "identifier", "medium", "patient", "priority", "recipient", "requested", "requester", "sender", "status", "subject", "time"]
|
11
|
+
METADATA = {
|
12
|
+
'id' => {'type'=>'id', 'path'=>'CommunicationRequest.id', 'min'=>0, 'max'=>1},
|
13
|
+
'meta' => {'type'=>'Meta', 'path'=>'CommunicationRequest.meta', 'min'=>0, 'max'=>1},
|
14
|
+
'implicitRules' => {'type'=>'uri', 'path'=>'CommunicationRequest.implicitRules', 'min'=>0, 'max'=>1},
|
15
|
+
'language' => {'type'=>'code', 'path'=>'CommunicationRequest.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
|
16
|
+
'text' => {'type'=>'Narrative', 'path'=>'CommunicationRequest.text', 'min'=>0, 'max'=>1},
|
17
|
+
'contained' => {'type'=>'Resource', 'path'=>'CommunicationRequest.contained', 'min'=>0, 'max'=>Float::INFINITY},
|
18
|
+
'extension' => {'type'=>'Extension', 'path'=>'CommunicationRequest.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
19
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'CommunicationRequest.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
20
|
+
'identifier' => {'type'=>'Identifier', 'path'=>'CommunicationRequest.identifier', 'min'=>0, 'max'=>Float::INFINITY},
|
21
|
+
'category' => {'type'=>'CodeableConcept', 'path'=>'CommunicationRequest.category', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
|
22
|
+
'sender' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson'], 'type'=>'Reference', 'path'=>'CommunicationRequest.sender', 'min'=>0, 'max'=>1},
|
23
|
+
'recipient' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Device', 'http://hl7.org/fhir/StructureDefinition/Organization', 'http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson'], 'type'=>'Reference', 'path'=>'CommunicationRequest.recipient', 'min'=>0, 'max'=>Float::INFINITY},
|
24
|
+
'payload' => {'type'=>'CommunicationRequest::Payload', 'path'=>'CommunicationRequest.payload', 'min'=>0, 'max'=>Float::INFINITY},
|
25
|
+
'medium' => {'valid_codes'=>{'http://hl7.org/fhir/v3/ParticipationMode'=>['ELECTRONIC', 'PHYSICAL', 'REMOTE', 'VERBAL', 'DICTATE', 'FACE', 'PHONE', 'VIDEOCONF', 'WRITTEN', 'FAXWRIT', 'HANDWRIT', 'MAILWRIT', 'ONLINEWRIT', 'EMAILWRIT', 'TYPEWRIT']}, 'type'=>'CodeableConcept', 'path'=>'CommunicationRequest.medium', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/v3-ParticipationMode'}},
|
26
|
+
'requester' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Practitioner', 'http://hl7.org/fhir/StructureDefinition/Patient', 'http://hl7.org/fhir/StructureDefinition/RelatedPerson'], 'type'=>'Reference', 'path'=>'CommunicationRequest.requester', 'min'=>0, 'max'=>1},
|
27
|
+
'status' => {'valid_codes'=>{'http://hl7.org/fhir/communication-request-status'=>['proposed', 'planned', 'requested', 'received', 'accepted', 'in-progress', 'completed', 'suspended', 'rejected', 'failed']}, 'type'=>'code', 'path'=>'CommunicationRequest.status', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/communication-request-status'}},
|
28
|
+
'encounter' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Encounter'], 'type'=>'Reference', 'path'=>'CommunicationRequest.encounter', 'min'=>0, 'max'=>1},
|
29
|
+
'scheduledDateTime' => {'type'=>'dateTime', 'path'=>'CommunicationRequest.scheduled[x]', 'min'=>0, 'max'=>1},
|
30
|
+
'scheduledPeriod' => {'type'=>'Period', 'path'=>'CommunicationRequest.scheduled[x]', 'min'=>0, 'max'=>1},
|
31
|
+
'reason' => {'type'=>'CodeableConcept', 'path'=>'CommunicationRequest.reason', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'example', 'uri'=>nil}},
|
32
|
+
'requestedOn' => {'type'=>'dateTime', 'path'=>'CommunicationRequest.requestedOn', 'min'=>0, 'max'=>1},
|
33
|
+
'subject' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Patient'], 'type'=>'Reference', 'path'=>'CommunicationRequest.subject', 'min'=>0, 'max'=>1},
|
34
|
+
'priority' => {'valid_codes'=>{'http://hl7.org/fhir/diagnostic-order-priority'=>['routine', 'urgent', 'stat', 'asap']}, 'type'=>'CodeableConcept', 'path'=>'CommunicationRequest.priority', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'example', 'uri'=>'http://hl7.org/fhir/ValueSet/diagnostic-order-priority'}}
|
35
|
+
}
|
36
|
+
|
37
|
+
class Payload < FHIR::Model
|
38
|
+
include FHIR::Hashable
|
39
|
+
include FHIR::Json
|
40
|
+
include FHIR::Xml
|
41
|
+
|
42
|
+
MULTIPLE_TYPES = {
|
43
|
+
'content' => ['string', 'Attachment', 'Reference']
|
44
|
+
}
|
45
|
+
METADATA = {
|
46
|
+
'id' => {'type'=>'id', 'path'=>'Payload.id', 'min'=>0, 'max'=>1},
|
47
|
+
'extension' => {'type'=>'Extension', 'path'=>'Payload.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
48
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Payload.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
49
|
+
'contentString' => {'type'=>'string', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1},
|
50
|
+
'contentAttachment' => {'type'=>'Attachment', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1},
|
51
|
+
'contentReference' => {'type_profiles'=>['http://hl7.org/fhir/StructureDefinition/Resource'], 'type'=>'Reference', 'path'=>'Payload.content[x]', 'min'=>1, 'max'=>1}
|
52
|
+
}
|
53
|
+
|
54
|
+
attr_accessor :id # 0-1 id
|
55
|
+
attr_accessor :extension # 0-* [ Extension ]
|
56
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
57
|
+
attr_accessor :contentString # 1-1 string
|
58
|
+
attr_accessor :contentAttachment # 1-1 Attachment
|
59
|
+
attr_accessor :contentReference # 1-1 Reference(Resource)
|
60
|
+
end
|
61
|
+
|
62
|
+
attr_accessor :id # 0-1 id
|
63
|
+
attr_accessor :meta # 0-1 Meta
|
64
|
+
attr_accessor :implicitRules # 0-1 uri
|
65
|
+
attr_accessor :language # 0-1 code
|
66
|
+
attr_accessor :text # 0-1 Narrative
|
67
|
+
attr_accessor :contained # 0-* [ Resource ]
|
68
|
+
attr_accessor :extension # 0-* [ Extension ]
|
69
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
70
|
+
attr_accessor :identifier # 0-* [ Identifier ]
|
71
|
+
attr_accessor :category # 0-1 CodeableConcept
|
72
|
+
attr_accessor :sender # 0-1 Reference(Device|Organization|Patient|Practitioner|RelatedPerson)
|
73
|
+
attr_accessor :recipient # 0-* [ Reference(Device|Organization|Patient|Practitioner|RelatedPerson) ]
|
74
|
+
attr_accessor :payload # 0-* [ CommunicationRequest::Payload ]
|
75
|
+
attr_accessor :medium # 0-* [ CodeableConcept ]
|
76
|
+
attr_accessor :requester # 0-1 Reference(Practitioner|Patient|RelatedPerson)
|
77
|
+
attr_accessor :status # 0-1 code
|
78
|
+
attr_accessor :encounter # 0-1 Reference(Encounter)
|
79
|
+
attr_accessor :scheduledDateTime # 0-1 dateTime
|
80
|
+
attr_accessor :scheduledPeriod # 0-1 Period
|
81
|
+
attr_accessor :reason # 0-* [ CodeableConcept ]
|
82
|
+
attr_accessor :requestedOn # 0-1 dateTime
|
83
|
+
attr_accessor :subject # 0-1 Reference(Patient)
|
84
|
+
attr_accessor :priority # 0-1 CodeableConcept
|
85
|
+
|
86
|
+
def resourceType
|
87
|
+
'CommunicationRequest'
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
@@ -0,0 +1,98 @@
|
|
1
|
+
module FHIR
|
2
|
+
class CompartmentDefinition < FHIR::Model
|
3
|
+
include FHIR::Hashable
|
4
|
+
include FHIR::Json
|
5
|
+
include FHIR::Xml
|
6
|
+
|
7
|
+
SEARCH_PARAMS = ["code", "date", "name", "resource", "status", "url"]
|
8
|
+
METADATA = {
|
9
|
+
'id' => {'type'=>'id', 'path'=>'CompartmentDefinition.id', 'min'=>0, 'max'=>1},
|
10
|
+
'meta' => {'type'=>'Meta', 'path'=>'CompartmentDefinition.meta', 'min'=>0, 'max'=>1},
|
11
|
+
'implicitRules' => {'type'=>'uri', 'path'=>'CompartmentDefinition.implicitRules', 'min'=>0, 'max'=>1},
|
12
|
+
'language' => {'type'=>'code', 'path'=>'CompartmentDefinition.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://tools.ietf.org/html/bcp47'}},
|
13
|
+
'text' => {'type'=>'Narrative', 'path'=>'CompartmentDefinition.text', 'min'=>0, 'max'=>1},
|
14
|
+
'contained' => {'type'=>'Resource', 'path'=>'CompartmentDefinition.contained', 'min'=>0, 'max'=>Float::INFINITY},
|
15
|
+
'extension' => {'type'=>'Extension', 'path'=>'CompartmentDefinition.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
16
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'CompartmentDefinition.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
17
|
+
'url' => {'type'=>'uri', 'path'=>'CompartmentDefinition.url', 'min'=>1, 'max'=>1},
|
18
|
+
'name' => {'type'=>'string', 'path'=>'CompartmentDefinition.name', 'min'=>1, 'max'=>1},
|
19
|
+
'status' => {'valid_codes'=>{'http://hl7.org/fhir/conformance-resource-status'=>['draft', 'active', 'retired']}, 'type'=>'code', 'path'=>'CompartmentDefinition.status', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/conformance-resource-status'}},
|
20
|
+
'experimental' => {'type'=>'boolean', 'path'=>'CompartmentDefinition.experimental', 'min'=>0, 'max'=>1},
|
21
|
+
'publisher' => {'type'=>'string', 'path'=>'CompartmentDefinition.publisher', 'min'=>0, 'max'=>1},
|
22
|
+
'contact' => {'type'=>'CompartmentDefinition::Contact', 'path'=>'CompartmentDefinition.contact', 'min'=>0, 'max'=>Float::INFINITY},
|
23
|
+
'date' => {'type'=>'dateTime', 'path'=>'CompartmentDefinition.date', 'min'=>0, 'max'=>1},
|
24
|
+
'description' => {'type'=>'string', 'path'=>'CompartmentDefinition.description', 'min'=>0, 'max'=>1},
|
25
|
+
'requirements' => {'type'=>'string', 'path'=>'CompartmentDefinition.requirements', 'min'=>0, 'max'=>1},
|
26
|
+
'code' => {'valid_codes'=>{'http://hl7.org/fhir/compartment-type'=>['Patient', 'Encounter', 'RelatedPerson', 'Practitioner', 'Device']}, 'type'=>'code', 'path'=>'CompartmentDefinition.code', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/compartment-type'}},
|
27
|
+
'search' => {'type'=>'boolean', 'path'=>'CompartmentDefinition.search', 'min'=>1, 'max'=>1},
|
28
|
+
'resource' => {'type'=>'CompartmentDefinition::Resource', 'path'=>'CompartmentDefinition.resource', 'min'=>0, 'max'=>Float::INFINITY}
|
29
|
+
}
|
30
|
+
|
31
|
+
class Contact < FHIR::Model
|
32
|
+
include FHIR::Hashable
|
33
|
+
include FHIR::Json
|
34
|
+
include FHIR::Xml
|
35
|
+
|
36
|
+
METADATA = {
|
37
|
+
'id' => {'type'=>'id', 'path'=>'Contact.id', 'min'=>0, 'max'=>1},
|
38
|
+
'extension' => {'type'=>'Extension', 'path'=>'Contact.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
39
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Contact.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
40
|
+
'name' => {'type'=>'string', 'path'=>'Contact.name', 'min'=>0, 'max'=>1},
|
41
|
+
'telecom' => {'type'=>'ContactPoint', 'path'=>'Contact.telecom', 'min'=>0, 'max'=>Float::INFINITY}
|
42
|
+
}
|
43
|
+
|
44
|
+
attr_accessor :id # 0-1 id
|
45
|
+
attr_accessor :extension # 0-* [ Extension ]
|
46
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
47
|
+
attr_accessor :name # 0-1 string
|
48
|
+
attr_accessor :telecom # 0-* [ ContactPoint ]
|
49
|
+
end
|
50
|
+
|
51
|
+
class Resource < FHIR::Model
|
52
|
+
include FHIR::Hashable
|
53
|
+
include FHIR::Json
|
54
|
+
include FHIR::Xml
|
55
|
+
|
56
|
+
METADATA = {
|
57
|
+
'id' => {'type'=>'id', 'path'=>'Resource.id', 'min'=>0, 'max'=>1},
|
58
|
+
'extension' => {'type'=>'Extension', 'path'=>'Resource.extension', 'min'=>0, 'max'=>Float::INFINITY},
|
59
|
+
'modifierExtension' => {'type'=>'Extension', 'path'=>'Resource.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
|
60
|
+
'code' => {'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'=>'Resource.code', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/resource-types'}},
|
61
|
+
'param' => {'type'=>'string', 'path'=>'Resource.param', 'min'=>0, 'max'=>Float::INFINITY},
|
62
|
+
'documentation' => {'type'=>'string', 'path'=>'Resource.documentation', 'min'=>0, 'max'=>1}
|
63
|
+
}
|
64
|
+
|
65
|
+
attr_accessor :id # 0-1 id
|
66
|
+
attr_accessor :extension # 0-* [ Extension ]
|
67
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
68
|
+
attr_accessor :code # 1-1 code
|
69
|
+
attr_accessor :param # 0-* [ string ]
|
70
|
+
attr_accessor :documentation # 0-1 string
|
71
|
+
end
|
72
|
+
|
73
|
+
attr_accessor :id # 0-1 id
|
74
|
+
attr_accessor :meta # 0-1 Meta
|
75
|
+
attr_accessor :implicitRules # 0-1 uri
|
76
|
+
attr_accessor :language # 0-1 code
|
77
|
+
attr_accessor :text # 0-1 Narrative
|
78
|
+
attr_accessor :contained # 0-* [ Resource ]
|
79
|
+
attr_accessor :extension # 0-* [ Extension ]
|
80
|
+
attr_accessor :modifierExtension # 0-* [ Extension ]
|
81
|
+
attr_accessor :url # 1-1 uri
|
82
|
+
attr_accessor :name # 1-1 string
|
83
|
+
attr_accessor :status # 0-1 code
|
84
|
+
attr_accessor :experimental # 0-1 boolean
|
85
|
+
attr_accessor :publisher # 0-1 string
|
86
|
+
attr_accessor :contact # 0-* [ CompartmentDefinition::Contact ]
|
87
|
+
attr_accessor :date # 0-1 dateTime
|
88
|
+
attr_accessor :description # 0-1 string
|
89
|
+
attr_accessor :requirements # 0-1 string
|
90
|
+
attr_accessor :code # 1-1 code
|
91
|
+
attr_accessor :search # 1-1 boolean
|
92
|
+
attr_accessor :resource # 0-* [ CompartmentDefinition::Resource ]
|
93
|
+
|
94
|
+
def resourceType
|
95
|
+
'CompartmentDefinition'
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|