Class: FHIR::CodeSystem

Inherits:
Model
  • Object
show all
Includes:
Hashable, Json, Xml
Defined in:
lib/fhir/resources/CodeSystem.rb

Defined Under Namespace

Classes: Concept, Contact, Filter, Property

Constant Summary collapse

SEARCH_PARAMS =
["code", "content", "context", "date", "description", "identifier", "language", "name", "publisher", "status", "system", "url", "version"]
METADATA =
{
  'id' => {'type'=>'id', 'path'=>'CodeSystem.id', 'min'=>0, 'max'=>1},
  'meta' => {'type'=>'Meta', 'path'=>'CodeSystem.meta', 'min'=>0, 'max'=>1},
  'implicitRules' => {'type'=>'uri', 'path'=>'CodeSystem.implicitRules', 'min'=>0, 'max'=>1},
  'language' => {'type'=>'code', 'path'=>'CodeSystem.language', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/languages'}},
  'text' => {'type'=>'Narrative', 'path'=>'CodeSystem.text', 'min'=>0, 'max'=>1},
  'contained' => {'type'=>'Resource', 'path'=>'CodeSystem.contained', 'min'=>0, 'max'=>Float::INFINITY},
  'extension' => {'type'=>'Extension', 'path'=>'CodeSystem.extension', 'min'=>0, 'max'=>Float::INFINITY},
  'modifierExtension' => {'type'=>'Extension', 'path'=>'CodeSystem.modifierExtension', 'min'=>0, 'max'=>Float::INFINITY},
  'url' => {'type'=>'uri', 'path'=>'CodeSystem.url', 'min'=>0, 'max'=>1},
  'identifier' => {'type'=>'Identifier', 'path'=>'CodeSystem.identifier', 'min'=>0, 'max'=>1},
  'version' => {'type'=>'string', 'path'=>'CodeSystem.version', 'min'=>0, 'max'=>1},
  'name' => {'type'=>'string', 'path'=>'CodeSystem.name', 'min'=>0, 'max'=>1},
  'status' => {'valid_codes'=>{'http://hl7.org/fhir/conformance-resource-status'=>['draft', 'active', 'retired', 'draft', 'active', 'retired']}, 'type'=>'code', 'path'=>'CodeSystem.status', 'min'=>1, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/conformance-resource-status'}},
  'experimental' => {'type'=>'boolean', 'path'=>'CodeSystem.experimental', 'min'=>0, 'max'=>1},
  'publisher' => {'type'=>'string', 'path'=>'CodeSystem.publisher', 'min'=>0, 'max'=>1},
  'contact' => {'type'=>'CodeSystem::Contact', 'path'=>'CodeSystem.contact', 'min'=>0, 'max'=>Float::INFINITY},
  'date' => {'type'=>'dateTime', 'path'=>'CodeSystem.date', 'min'=>0, 'max'=>1},
  'description' => {'type'=>'markdown', 'path'=>'CodeSystem.description', 'min'=>0, 'max'=>1},
  'useContext' => {'valid_codes'=>{'https://www.usps.com/'=>['AK', 'AL', 'AR', 'AS', 'AZ', 'CA', 'CO', 'CT', 'DC', 'DE', 'FL', 'FM', 'GA', 'GU', 'HI', 'IA', 'ID', 'IL', 'IN', 'KS', 'KY', 'LA', 'MA', 'MD', 'ME', 'MH', 'MI', 'MN', 'MO', 'MP', 'MS', 'MT', 'NC', 'ND', 'NE', 'NH', 'NJ', 'NM', 'NV', 'NY', 'OH', 'OK', 'OR', 'PA', 'PR', 'PW', 'RI', 'SC', 'SD', 'TN', 'TX', 'UM', 'UT', 'VA', 'VI', 'VT', 'WA', 'WI', 'WV', 'WY'], 'http://hl7.org/fhir/practitioner-specialty'=>['cardio', 'dent', 'dietary', 'midw', 'sysarch'], 'urn:iso:std:iso:3166'=>['AD', 'AE', 'AF', 'AG', 'AI', 'AL', 'AM', 'AN', 'AO', 'AQ', 'AR', 'AS', 'AT', 'AU', 'AW', 'AX', 'AZ', 'BA', 'BB', 'BD', 'BE', 'BF', 'BG', 'BH', 'BI', 'BJ', 'BL', 'BM', 'BN', 'BO', 'BQ', 'BR', 'BS', 'BT', 'BU', 'BV', 'BW', 'BY', 'BZ', 'CA', 'CC', 'CD', 'CF', 'CG', 'CH', 'CI', 'CK', 'CL', 'CM', 'CN', 'CO', 'CR', 'CS', 'CT', 'CU', 'CV', 'CW', 'CX', 'CY', 'CZ', 'DD', 'DE', 'DJ', 'DK', 'DM', 'DO', 'DY', 'DZ', 'EC', 'EE', 'EG', 'EH', 'ER', 'ES', 'ET', 'FI', 'FJ', 'FK', 'FM', 'FO', 'FQ', 'FR', 'GA', 'GB', 'GD', 'GE', 'GF', 'GG', 'GH', 'GI', 'GL', 'GM', 'GN', 'GP', 'GQ', 'GR', 'GS', 'GT', 'GU', 'GW', 'GY', 'HK', 'HM', 'HN', 'HR', 'HT', 'HU', 'HV', 'ID', 'IE', 'IL', 'IM', 'IN', 'IO', 'IQ', 'IR', 'IS', 'IT', 'JE', 'JM', 'JO', 'JP', 'JT', 'KE', 'KG', 'KH', 'KI', 'KM', 'KN', 'KP', 'KR', 'KW', 'KY', 'KZ', 'LA', 'LB', 'LC', 'LI', 'LK', 'LR', 'LS', 'LT', 'LU', 'LV', 'LY', 'MA', 'MC', 'MD', 'ME', 'MF', 'MG', 'MH', 'MI', 'MK', 'ML', 'MM', 'MN', 'MO', 'MP', 'MQ', 'MR', 'MS', 'MT', 'MU', 'MV', 'MW', 'MX', 'MY', 'MZ', 'NA', 'NC', 'NE', 'NF', 'NG', 'NH', 'NI', 'NL', 'NO', 'NP', 'NQ', 'NR', 'NT', 'NU', 'NZ', 'OM', 'PA', 'PC', 'PE', 'PF', 'PG', 'PH', 'PK', 'PL', 'PM', 'PN', 'PR', 'PS', 'PT', 'PU', 'PW', 'PY', 'PZ', 'QA', 'RE', 'RH', 'RO', 'RS', 'RU', 'RW', 'SA', 'SB', 'SC', 'SD', 'SE', 'SG', 'SH', 'SI', 'SJ', 'SK', 'SL', 'SM', 'SN', 'SO', 'SR', 'SS', 'ST', 'SU', 'SV', 'SX', 'SY', 'SZ', 'TC', 'TD', 'TF', 'TG', 'TH', 'TJ', 'TK', 'TL', 'TM', 'TN', 'TO', 'TP', 'TR', 'TT', 'TV', 'TW', 'TZ', 'UA', 'UG', 'UM', 'US', 'UY', 'UZ', 'VA', 'VC', 'VD', 'VE', 'VG', 'VI', 'VN', 'VU', 'WF', 'WK', 'WS', 'YD', 'YE', 'YT', 'YU', 'ZA', 'ZM', 'ZR', 'ZW'], 'http://unstats.un.org/unsd/methods/m49/m49.htm'=>['004', '008', '012', '016', '020', '024', '028', '031', '032', '036', '040', '044', '048', '050', '051', '052', '056', '060', '064', '068', '070', '072', '076', '084', '090', '092', '096', '100', '104', '108', '112', '116', '120', '124', '132', '136', '140', '144', '148', '152', '156', '170', '174', '175', '178', '180', '184', '188', '191', '192', '196', '203', '204', '208', '212', '214', '218', '222', '226', '231', '232', '233', '234', '238', '242', '246', '248', '250', '254', '258', '262', '266', '268', '270', '275', '276', '288', '292', '296', '300', '304', '308', '312', '316', '320', '324', '328', '332', '336', '340', '344', '348', '352', '356', '360', '364', '368', '372', '376', '380', '384', '388', '392', '398', '400', '404', '408', '410', '414', '417', '418', '422', '426', '428', '430', '434', '438', '440', '442', '446', '450', '454', '458', '462', '466', '470', '474', '478', '480', '484', '492', '496', '498', '499', '500', '504', '508', '512', '516', '520', '524', '528', '531', '533', '534', '535', '540', '548', '554', '558', '562', '566', '570', '574', '578', '580', '583', '584', '585', '586', '591', '598', '600', '604', '608', '612', '616', '620', '624', '626', '630', '634', '638', '642', '643', '646', '652', '654', '659', '660', '662', '663', '666', '670', '674', '678', '680', '682', '686', '688', '690', '694', '702', '703', '704', '705', '706', '710', '716', '724', '728', '729', '732', '740', '744', '748', '752', '756', '760', '762', '764', '768', '772', '776', '780', '784', '788', '792', '795', '796', '798', '800', '804', '807', '818', '826', '830', '831', '832', '833', '834', '840', '850', '854', '858', '860', '862', '876', '882', '887', '894']}, 'type'=>'CodeableConcept', 'path'=>'CodeSystem.useContext', 'min'=>0, 'max'=>Float::INFINITY, 'binding'=>{'strength'=>'extensible', 'uri'=>'http://hl7.org/fhir/ValueSet/use-context'}},
  'requirements' => {'type'=>'markdown', 'path'=>'CodeSystem.requirements', 'min'=>0, 'max'=>1},
  'copyright' => {'type'=>'string', 'path'=>'CodeSystem.copyright', 'min'=>0, 'max'=>1},
  'caseSensitive' => {'type'=>'boolean', 'path'=>'CodeSystem.caseSensitive', 'min'=>0, 'max'=>1},
  'valueSet' => {'type'=>'uri', 'path'=>'CodeSystem.valueSet', 'min'=>0, 'max'=>1},
  'hierarchyMeaning' => {'valid_codes'=>{'http://hl7.org/fhir/codesystem-hierarchy-meaning'=>['grouped-by', 'subsumes', 'part-of', 'classified-with', 'grouped-by', 'subsumes', 'part-of', 'classified-with']}, 'type'=>'code', 'path'=>'CodeSystem.hierarchyMeaning', 'min'=>0, 'max'=>1, 'binding'=>{'strength'=>'required', 'uri'=>'http://hl7.org/fhir/ValueSet/codesystem-hierarchy-meaning'}},
  'compositional' => {'type'=>'boolean', 'path'=>'CodeSystem.compositional', 'min'=>0, 'max'=>1},
  'versionNeeded' => {'type'=>'boolean', 'path'=>'CodeSystem.versionNeeded', 'min'=>0, 'max'=>1},
  'content' => {'valid_codes'=>{'http://hl7.org/fhir/codesystem-content-mode'=>['not-present', 'examplar', 'fragment', 'complete', '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'}},
  'count' => {'type'=>'unsignedInt', 'path'=>'CodeSystem.count', 'min'=>0, 'max'=>1},
  'filter' => {'type'=>'CodeSystem::Filter', 'path'=>'CodeSystem.filter', 'min'=>0, 'max'=>Float::INFINITY},
  'property' => {'type'=>'CodeSystem::Property', 'path'=>'CodeSystem.property', 'min'=>0, 'max'=>Float::INFINITY},
  'concept' => {'type'=>'CodeSystem::Concept', 'path'=>'CodeSystem.concept', 'min'=>0, 'max'=>Float::INFINITY}
}

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Xml

from_xml, is_valid?, #to_xml, validate

Methods included from Json

from_json, #to_json

Methods included from Hashable

#from_hash, #to_hash

Methods inherited from Model

#attribute_mismatch, #compare_attribute, #equals?, #initialize, #is_valid?, #method_missing, #mismatch, #to_reference, #validate, #validate_profile

Constructor Details

This class inherits a constructor from FHIR::Model

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class FHIR::Model

Instance Attribute Details

#caseSensitiveObject

0-1 boolean



214
215
216
# File 'lib/fhir/resources/CodeSystem.rb', line 214

def caseSensitive
  @caseSensitive
end

#compositionalObject

0-1 boolean



217
218
219
# File 'lib/fhir/resources/CodeSystem.rb', line 217

def compositional
  @compositional
end

#conceptObject

0-* [ CodeSystem::Concept ]



223
224
225
# File 'lib/fhir/resources/CodeSystem.rb', line 223

def concept
  @concept
end

#contactObject

0-* [ CodeSystem::Contact ]



208
209
210
# File 'lib/fhir/resources/CodeSystem.rb', line 208

def contact
  @contact
end

#containedObject

0-* [ Resource ]



198
199
200
# File 'lib/fhir/resources/CodeSystem.rb', line 198

def contained
  @contained
end

#contentObject

1-1 code



219
220
221
# File 'lib/fhir/resources/CodeSystem.rb', line 219

def content
  @content
end

0-1 string



213
214
215
# File 'lib/fhir/resources/CodeSystem.rb', line 213

def copyright
  @copyright
end

#countObject

0-1 unsignedInt



220
221
222
# File 'lib/fhir/resources/CodeSystem.rb', line 220

def count
  @count
end

#dateObject

0-1 dateTime



209
210
211
# File 'lib/fhir/resources/CodeSystem.rb', line 209

def date
  @date
end

#descriptionObject

0-1 markdown



210
211
212
# File 'lib/fhir/resources/CodeSystem.rb', line 210

def description
  @description
end

#experimentalObject

0-1 boolean



206
207
208
# File 'lib/fhir/resources/CodeSystem.rb', line 206

def experimental
  @experimental
end

#extensionObject

0-* [ Extension ]



199
200
201
# File 'lib/fhir/resources/CodeSystem.rb', line 199

def extension
  @extension
end

#filterObject

0-* [ CodeSystem::Filter ]



221
222
223
# File 'lib/fhir/resources/CodeSystem.rb', line 221

def filter
  @filter
end

#hierarchyMeaningObject

0-1 code



216
217
218
# File 'lib/fhir/resources/CodeSystem.rb', line 216

def hierarchyMeaning
  @hierarchyMeaning
end

#idObject

0-1 id



193
194
195
# File 'lib/fhir/resources/CodeSystem.rb', line 193

def id
  @id
end

#identifierObject

0-1 Identifier



202
203
204
# File 'lib/fhir/resources/CodeSystem.rb', line 202

def identifier
  @identifier
end

#implicitRulesObject

0-1 uri



195
196
197
# File 'lib/fhir/resources/CodeSystem.rb', line 195

def implicitRules
  @implicitRules
end

#languageObject

0-1 code



196
197
198
# File 'lib/fhir/resources/CodeSystem.rb', line 196

def language
  @language
end

#metaObject

0-1 Meta



194
195
196
# File 'lib/fhir/resources/CodeSystem.rb', line 194

def meta
  @meta
end

#modifierExtensionObject

0-* [ Extension ]



200
201
202
# File 'lib/fhir/resources/CodeSystem.rb', line 200

def modifierExtension
  @modifierExtension
end

#nameObject

0-1 string



204
205
206
# File 'lib/fhir/resources/CodeSystem.rb', line 204

def name
  @name
end

#propertyObject

0-* [ CodeSystem::Property ]



222
223
224
# File 'lib/fhir/resources/CodeSystem.rb', line 222

def property
  @property
end

#publisherObject

0-1 string



207
208
209
# File 'lib/fhir/resources/CodeSystem.rb', line 207

def publisher
  @publisher
end

#requirementsObject

0-1 markdown



212
213
214
# File 'lib/fhir/resources/CodeSystem.rb', line 212

def requirements
  @requirements
end

#statusObject

1-1 code



205
206
207
# File 'lib/fhir/resources/CodeSystem.rb', line 205

def status
  @status
end

#textObject

0-1 Narrative



197
198
199
# File 'lib/fhir/resources/CodeSystem.rb', line 197

def text
  @text
end

#urlObject

0-1 uri



201
202
203
# File 'lib/fhir/resources/CodeSystem.rb', line 201

def url
  @url
end

#useContextObject

0-* [ CodeableConcept ]



211
212
213
# File 'lib/fhir/resources/CodeSystem.rb', line 211

def useContext
  @useContext
end

#valueSetObject

0-1 uri



215
216
217
# File 'lib/fhir/resources/CodeSystem.rb', line 215

def valueSet
  @valueSet
end

#versionObject

0-1 string



203
204
205
# File 'lib/fhir/resources/CodeSystem.rb', line 203

def version
  @version
end

#versionNeededObject

0-1 boolean



218
219
220
# File 'lib/fhir/resources/CodeSystem.rb', line 218

def versionNeeded
  @versionNeeded
end

Instance Method Details

#resourceTypeObject



225
226
227
# File 'lib/fhir/resources/CodeSystem.rb', line 225

def resourceType
  'CodeSystem'
end