openehr 1.1.6 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
data/.travis.yml CHANGED
@@ -1,3 +1,5 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 1.9.3
3
+ - 2.0.0
4
+ - 1.9.3
5
+ - 1.9.2
data/README.rdoc CHANGED
@@ -5,12 +5,12 @@ Ruby openEHR implementation project.
5
5
 
6
6
  = Version
7
7
 
8
- Release-1.1.5
8
+ Release-1.2.0
9
9
 
10
10
  = Requirements
11
11
 
12
12
  * Ruby 1.9.2 or later recommended
13
- * Tested with Ruby 1.9.3 on Linux and FreeBSD.
13
+ * Developed with CRuby 2.0.0, 1.9.3 on Linux and FreeBSD.
14
14
  * It would work with some adjustment on Ruby 1.8 or earlier,
15
15
  but not confirmed.
16
16
  * It should work on other platforms with Ruby
@@ -38,7 +38,7 @@ This package excludes:
38
38
  * ADL serializer(in progress)
39
39
  * ADL validator(in progress)
40
40
  * Data store/retrieve would be separate to the other project.
41
- * Terminology service(moved to open_terminology package)
41
+ * Terminology service(moved to openehr-terminology package)
42
42
  * Rails plugin(moved to openehr-rails package
43
43
 
44
44
  Almost all classes passed the test constructed by RSpec2. These spec
data/Rakefile CHANGED
@@ -1,7 +1,6 @@
1
1
  require 'rubygems'
2
2
  require 'bundler'
3
3
  require "bundler/gem_tasks"
4
- Bundler::GemHelper::install_tasks
5
4
 
6
5
  require 'rake'
7
6
  require 'rspec/core'
@@ -1,10 +1,9 @@
1
1
  Given /^\"DV_TEXT\" in archetype definition with attribute$/ do
2
2
  @type= "DV_TEXT"
3
- @params = [value: 'text']
4
3
  end
5
4
 
6
5
  When /^RM Factory generates instance$/ do
7
- @dv_text = OpenEHR::RM::Factory.create(@type, @params)
6
+ @dv_text = OpenEHR::RM::Factory.create(@type, value: 'text')
8
7
  end
9
8
 
10
9
  Then /^DvText instance should be available$/ do
@@ -9,8 +9,6 @@ module OpenEHR
9
9
  autoload :Ontology, 'archetype/ontology'
10
10
 
11
11
  module ADLDefinition
12
- include OpenEHR::RM::Support::Terminology
13
- # include OpenEHR::RM::Support::Terminology::OpenEHR_Code_Set_Identifier
14
12
  CURRENT_ADL_VERSION = "1.4"
15
13
  end
16
14
 
@@ -8,7 +8,6 @@ module OpenEHR
8
8
  autoload :Definition, 'support/definition'
9
9
  autoload :Identification, 'support/identification'
10
10
  autoload :Measurement, 'support/measurement'
11
- autoload :Terminology, 'support/terminology'
12
11
  end
13
12
  end
14
13
  end
@@ -1,3 +1,3 @@
1
1
  module OpenEHR
2
- VERSION = "1.1.6"
2
+ VERSION = "1.2.0"
3
3
  end
data/lib/openehr.rb CHANGED
@@ -7,5 +7,4 @@ module OpenEHR
7
7
  autoload :AM, 'openehr/am'
8
8
  autoload :Parser, 'openehr/parser'
9
9
  autoload :Serializer, 'openehr/serializer'
10
- autoload :Terminology, 'openehr/terminology'
11
10
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: openehr
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.6
4
+ version: 1.2.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,14 +10,14 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2013-02-20 00:00:00.000000000 Z
13
+ date: 2013-02-25 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rake
17
17
  requirement: !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
- - - ! '>='
20
+ - - '>='
21
21
  - !ruby/object:Gem::Version
22
22
  version: '0'
23
23
  type: :runtime
@@ -25,7 +25,7 @@ dependencies:
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  none: false
27
27
  requirements:
28
- - - ! '>='
28
+ - - '>='
29
29
  - !ruby/object:Gem::Version
30
30
  version: '0'
31
31
  - !ruby/object:Gem::Dependency
@@ -33,7 +33,7 @@ dependencies:
33
33
  requirement: !ruby/object:Gem::Requirement
34
34
  none: false
35
35
  requirements:
36
- - - ! '>='
36
+ - - '>='
37
37
  - !ruby/object:Gem::Version
38
38
  version: '0'
39
39
  type: :runtime
@@ -41,7 +41,7 @@ dependencies:
41
41
  version_requirements: !ruby/object:Gem::Requirement
42
42
  none: false
43
43
  requirements:
44
- - - ! '>='
44
+ - - '>='
45
45
  - !ruby/object:Gem::Version
46
46
  version: '0'
47
47
  - !ruby/object:Gem::Dependency
@@ -49,7 +49,7 @@ dependencies:
49
49
  requirement: !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
- - - ! '>='
52
+ - - '>='
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  type: :runtime
@@ -57,7 +57,7 @@ dependencies:
57
57
  version_requirements: !ruby/object:Gem::Requirement
58
58
  none: false
59
59
  requirements:
60
- - - ! '>='
60
+ - - '>='
61
61
  - !ruby/object:Gem::Version
62
62
  version: '0'
63
63
  - !ruby/object:Gem::Dependency
@@ -65,7 +65,7 @@ dependencies:
65
65
  requirement: !ruby/object:Gem::Requirement
66
66
  none: false
67
67
  requirements:
68
- - - ! '>='
68
+ - - '>='
69
69
  - !ruby/object:Gem::Version
70
70
  version: '0'
71
71
  type: :runtime
@@ -73,7 +73,7 @@ dependencies:
73
73
  version_requirements: !ruby/object:Gem::Requirement
74
74
  none: false
75
75
  requirements:
76
- - - ! '>='
76
+ - - '>='
77
77
  - !ruby/object:Gem::Version
78
78
  version: '0'
79
79
  - !ruby/object:Gem::Dependency
@@ -81,7 +81,7 @@ dependencies:
81
81
  requirement: !ruby/object:Gem::Requirement
82
82
  none: false
83
83
  requirements:
84
- - - ! '>='
84
+ - - '>='
85
85
  - !ruby/object:Gem::Version
86
86
  version: '0'
87
87
  type: :runtime
@@ -89,7 +89,7 @@ dependencies:
89
89
  version_requirements: !ruby/object:Gem::Requirement
90
90
  none: false
91
91
  requirements:
92
- - - ! '>='
92
+ - - '>='
93
93
  - !ruby/object:Gem::Version
94
94
  version: '0'
95
95
  - !ruby/object:Gem::Dependency
@@ -97,7 +97,7 @@ dependencies:
97
97
  requirement: !ruby/object:Gem::Requirement
98
98
  none: false
99
99
  requirements:
100
- - - ! '>='
100
+ - - '>='
101
101
  - !ruby/object:Gem::Version
102
102
  version: '0'
103
103
  type: :runtime
@@ -105,7 +105,7 @@ dependencies:
105
105
  version_requirements: !ruby/object:Gem::Requirement
106
106
  none: false
107
107
  requirements:
108
- - - ! '>='
108
+ - - '>='
109
109
  - !ruby/object:Gem::Version
110
110
  version: '0'
111
111
  - !ruby/object:Gem::Dependency
@@ -113,7 +113,7 @@ dependencies:
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  none: false
115
115
  requirements:
116
- - - ! '>='
116
+ - - '>='
117
117
  - !ruby/object:Gem::Version
118
118
  version: '0'
119
119
  type: :runtime
@@ -121,7 +121,7 @@ dependencies:
121
121
  version_requirements: !ruby/object:Gem::Requirement
122
122
  none: false
123
123
  requirements:
124
- - - ! '>='
124
+ - - '>='
125
125
  - !ruby/object:Gem::Version
126
126
  version: '0'
127
127
  - !ruby/object:Gem::Dependency
@@ -129,7 +129,7 @@ dependencies:
129
129
  requirement: !ruby/object:Gem::Requirement
130
130
  none: false
131
131
  requirements:
132
- - - ! '>='
132
+ - - '>='
133
133
  - !ruby/object:Gem::Version
134
134
  version: '0'
135
135
  type: :runtime
@@ -137,7 +137,7 @@ dependencies:
137
137
  version_requirements: !ruby/object:Gem::Requirement
138
138
  none: false
139
139
  requirements:
140
- - - ! '>='
140
+ - - '>='
141
141
  - !ruby/object:Gem::Version
142
142
  version: '0'
143
143
  - !ruby/object:Gem::Dependency
@@ -145,7 +145,7 @@ dependencies:
145
145
  requirement: !ruby/object:Gem::Requirement
146
146
  none: false
147
147
  requirements:
148
- - - ! '>='
148
+ - - '>='
149
149
  - !ruby/object:Gem::Version
150
150
  version: '0'
151
151
  type: :runtime
@@ -153,7 +153,7 @@ dependencies:
153
153
  version_requirements: !ruby/object:Gem::Requirement
154
154
  none: false
155
155
  requirements:
156
- - - ! '>='
156
+ - - '>='
157
157
  - !ruby/object:Gem::Version
158
158
  version: '0'
159
159
  - !ruby/object:Gem::Dependency
@@ -161,7 +161,7 @@ dependencies:
161
161
  requirement: !ruby/object:Gem::Requirement
162
162
  none: false
163
163
  requirements:
164
- - - ! '>='
164
+ - - '>='
165
165
  - !ruby/object:Gem::Version
166
166
  version: '0'
167
167
  type: :runtime
@@ -169,7 +169,7 @@ dependencies:
169
169
  version_requirements: !ruby/object:Gem::Requirement
170
170
  none: false
171
171
  requirements:
172
- - - ! '>='
172
+ - - '>='
173
173
  - !ruby/object:Gem::Version
174
174
  version: '0'
175
175
  - !ruby/object:Gem::Dependency
@@ -177,7 +177,7 @@ dependencies:
177
177
  requirement: !ruby/object:Gem::Requirement
178
178
  none: false
179
179
  requirements:
180
- - - ! '>='
180
+ - - '>='
181
181
  - !ruby/object:Gem::Version
182
182
  version: '0'
183
183
  type: :runtime
@@ -185,7 +185,7 @@ dependencies:
185
185
  version_requirements: !ruby/object:Gem::Requirement
186
186
  none: false
187
187
  requirements:
188
- - - ! '>='
188
+ - - '>='
189
189
  - !ruby/object:Gem::Version
190
190
  version: '0'
191
191
  - !ruby/object:Gem::Dependency
@@ -193,7 +193,7 @@ dependencies:
193
193
  requirement: !ruby/object:Gem::Requirement
194
194
  none: false
195
195
  requirements:
196
- - - ! '>='
196
+ - - '>='
197
197
  - !ruby/object:Gem::Version
198
198
  version: '0'
199
199
  type: :development
@@ -201,7 +201,7 @@ dependencies:
201
201
  version_requirements: !ruby/object:Gem::Requirement
202
202
  none: false
203
203
  requirements:
204
- - - ! '>='
204
+ - - '>='
205
205
  - !ruby/object:Gem::Version
206
206
  version: '0'
207
207
  - !ruby/object:Gem::Dependency
@@ -209,7 +209,7 @@ dependencies:
209
209
  requirement: !ruby/object:Gem::Requirement
210
210
  none: false
211
211
  requirements:
212
- - - ! '>='
212
+ - - '>='
213
213
  - !ruby/object:Gem::Version
214
214
  version: '0'
215
215
  type: :development
@@ -217,7 +217,7 @@ dependencies:
217
217
  version_requirements: !ruby/object:Gem::Requirement
218
218
  none: false
219
219
  requirements:
220
- - - ! '>='
220
+ - - '>='
221
221
  - !ruby/object:Gem::Version
222
222
  version: '0'
223
223
  - !ruby/object:Gem::Dependency
@@ -225,7 +225,7 @@ dependencies:
225
225
  requirement: !ruby/object:Gem::Requirement
226
226
  none: false
227
227
  requirements:
228
- - - ! '>='
228
+ - - '>='
229
229
  - !ruby/object:Gem::Version
230
230
  version: '0'
231
231
  type: :development
@@ -233,7 +233,7 @@ dependencies:
233
233
  version_requirements: !ruby/object:Gem::Requirement
234
234
  none: false
235
235
  requirements:
236
- - - ! '>='
236
+ - - '>='
237
237
  - !ruby/object:Gem::Version
238
238
  version: '0'
239
239
  - !ruby/object:Gem::Dependency
@@ -257,7 +257,7 @@ dependencies:
257
257
  requirement: !ruby/object:Gem::Requirement
258
258
  none: false
259
259
  requirements:
260
- - - ! '>='
260
+ - - '>='
261
261
  - !ruby/object:Gem::Version
262
262
  version: '0'
263
263
  type: :development
@@ -265,7 +265,7 @@ dependencies:
265
265
  version_requirements: !ruby/object:Gem::Requirement
266
266
  none: false
267
267
  requirements:
268
- - - ! '>='
268
+ - - '>='
269
269
  - !ruby/object:Gem::Version
270
270
  version: '0'
271
271
  - !ruby/object:Gem::Dependency
@@ -273,7 +273,7 @@ dependencies:
273
273
  requirement: !ruby/object:Gem::Requirement
274
274
  none: false
275
275
  requirements:
276
- - - ! '>'
276
+ - - '>'
277
277
  - !ruby/object:Gem::Version
278
278
  version: 1.0rc
279
279
  type: :development
@@ -281,7 +281,7 @@ dependencies:
281
281
  version_requirements: !ruby/object:Gem::Requirement
282
282
  none: false
283
283
  requirements:
284
- - - ! '>'
284
+ - - '>'
285
285
  - !ruby/object:Gem::Version
286
286
  version: 1.0rc
287
287
  - !ruby/object:Gem::Dependency
@@ -289,7 +289,7 @@ dependencies:
289
289
  requirement: !ruby/object:Gem::Requirement
290
290
  none: false
291
291
  requirements:
292
- - - ! '>='
292
+ - - '>='
293
293
  - !ruby/object:Gem::Version
294
294
  version: '0'
295
295
  type: :development
@@ -297,7 +297,7 @@ dependencies:
297
297
  version_requirements: !ruby/object:Gem::Requirement
298
298
  none: false
299
299
  requirements:
300
- - - ! '>='
300
+ - - '>='
301
301
  - !ruby/object:Gem::Version
302
302
  version: '0'
303
303
  - !ruby/object:Gem::Dependency
@@ -305,7 +305,7 @@ dependencies:
305
305
  requirement: !ruby/object:Gem::Requirement
306
306
  none: false
307
307
  requirements:
308
- - - ! '>='
308
+ - - '>='
309
309
  - !ruby/object:Gem::Version
310
310
  version: '0'
311
311
  type: :development
@@ -313,7 +313,7 @@ dependencies:
313
313
  version_requirements: !ruby/object:Gem::Requirement
314
314
  none: false
315
315
  requirements:
316
- - - ! '>='
316
+ - - '>='
317
317
  - !ruby/object:Gem::Version
318
318
  version: '0'
319
319
  - !ruby/object:Gem::Dependency
@@ -337,7 +337,7 @@ dependencies:
337
337
  requirement: !ruby/object:Gem::Requirement
338
338
  none: false
339
339
  requirements:
340
- - - ! '>='
340
+ - - '>='
341
341
  - !ruby/object:Gem::Version
342
342
  version: '0'
343
343
  type: :development
@@ -345,7 +345,7 @@ dependencies:
345
345
  version_requirements: !ruby/object:Gem::Requirement
346
346
  none: false
347
347
  requirements:
348
- - - ! '>='
348
+ - - '>='
349
349
  - !ruby/object:Gem::Version
350
350
  version: '0'
351
351
  description: This project is an implementation of the openEHR specification on Ruby.
@@ -424,10 +424,7 @@ files:
424
424
  - lib/openehr/rm/support/definition.rb
425
425
  - lib/openehr/rm/support/identification.rb
426
426
  - lib/openehr/rm/support/measurement.rb
427
- - lib/openehr/rm/support/terminology.rb
428
427
  - lib/openehr/serializer.rb
429
- - lib/openehr/terminology.rb
430
- - lib/openehr/terminology/open_ehr_terminology.rb
431
428
  - lib/openehr/version.rb
432
429
  - lib/openehr/writer.rb
433
430
  - openehr.gemspec
@@ -735,14 +732,12 @@ files:
735
732
  - spec/lib/openehr/rm/support/identification/uid_spec.rb
736
733
  - spec/lib/openehr/rm/support/identification/version_tree_id_spec.rb
737
734
  - spec/lib/openehr/rm/support/measurement_service_spec.rb
738
- - spec/lib/openehr/rm/support/terminology_service_spec.rb
739
735
  - spec/lib/openehr/serializer/adl-test-entry.most_minimal.test.adl
740
736
  - spec/lib/openehr/serializer/adl_serializer_spec.rb
741
737
  - spec/lib/openehr/serializer/openEHR-EHR-SECTION.test.v1.adl
742
738
  - spec/lib/openehr/serializer/openEHR-EHR-SECTION.test.v1.xml
743
739
  - spec/lib/openehr/serializer/sample_archetype_spec.rb
744
740
  - spec/lib/openehr/serializer/xml_serializer_spec.rb
745
- - spec/lib/openehr/terminology/open_ehr_terminology_spec.rb
746
741
  - spec/spec.opts
747
742
  - spec/spec_helper.rb
748
743
  homepage: http://openehr.jp
@@ -755,13 +750,13 @@ require_paths:
755
750
  required_ruby_version: !ruby/object:Gem::Requirement
756
751
  none: false
757
752
  requirements:
758
- - - ! '>='
753
+ - - '>='
759
754
  - !ruby/object:Gem::Version
760
755
  version: '0'
761
756
  required_rubygems_version: !ruby/object:Gem::Requirement
762
757
  none: false
763
758
  requirements:
764
- - - ! '>='
759
+ - - '>='
765
760
  - !ruby/object:Gem::Version
766
761
  version: '0'
767
762
  requirements: []
@@ -771,4 +766,3 @@ signing_key:
771
766
  specification_version: 3
772
767
  summary: Ruby implementation of the openEHR specification
773
768
  test_files: []
774
- has_rdoc:
@@ -1,135 +0,0 @@
1
-
2
- module OpenEHR
3
- module RM
4
- module Support
5
- module Terminology
6
- class CodeSetAccess
7
- def all_codes
8
- raise NotImplementedError, "all_codes must be implemented"
9
- end
10
-
11
- def has_code(a_code)
12
- raise NotImplementedError, "has_code must be implemented"
13
- end
14
-
15
- def has_lang(a_lang)
16
- raise NotImplementedError, "has_lang must be implemented"
17
- end
18
-
19
- def id
20
- raise NotImplementedError, "id must be returned"
21
- end
22
- end
23
-
24
- module OpenEHRCodeSetIdentifier
25
- CODE_SET_ID_CHARACER_SETS = "character sets".freeze
26
- CODE_SET_ID_COMPRESSION_ALGORITHMS = "compression algorithms".freeze
27
- CODE_SET_ID_COUNTRIES = "countries".freeze
28
- CODE_SET_ID_INTEGRITY_CHECK_ALGORITHMS = "integrity check algorithms".freeze
29
- CODE_SET_ID_LANGUAGES = "languages".freeze
30
- CODE_SET_ID_MEDIA_TYPES = "media types".freeze
31
- def valid_code_set_id(an_id)
32
- !@an_id.nil?
33
- end
34
- end
35
-
36
- module OpenEHRTerminologyGroupIdentifiers
37
- GROUP_ID_ATTESTATION_REASON = "attestation reason".freeze
38
- GROUP_ID_AUDIT_CHANGE_TYPE = "audit change type".freeze
39
- GROUP_ID_COMPOSITION_CATEGORY = "composition category".freeze
40
- GROUP_ID_MATH_FUNCTION = "event math function".freeze
41
- GROUP_ID_INSTRUCTION_STATES = "instruction states".freeze
42
- GROUP_ID_INSTRUCTION_TRANSITIONS = "instruction transitions".freeze
43
- GROUP_ID_NULL_FLAVOURS = "null flavours".freeze
44
- GROUP_ID_PARTICIPATION_FUNCTION = "participation function".freeze
45
- GROUP_ID_PARTICIPATION_MODE = "participation mode".freeze
46
- GROUP_ID_PROPERTY = "property".freeze
47
- GROUP_ID_SETTING = "setting".freeze.freeze
48
- GROUP_ID_SUBJECT_RELATIONSHIP = "subject relationship".freeze
49
- GROUP_ID_TERM_MAPPING_PURPOSE = "term mapping purpose".freeze
50
- GROUP_ID_VERSION_LIFECYCLE_STATE = "version lifecycle state".freeze
51
- TERMINOLOGY_ID = "openehr".freeze
52
- end
53
-
54
- class TerminologyAccess
55
- attr_reader :id
56
-
57
- def initialize(args = {})
58
- self.id = args[:id]
59
- end
60
-
61
- def all_codes
62
- raise NotImplementedError, "all_codes is not implemented"
63
- end
64
-
65
- def codes_for_group_id(group_id)
66
- raise NotImplementedError, "codes_for_group_id is not implemented"
67
- end
68
-
69
- def codes_for_group_name(name, lang)
70
- raise NotImplementedError, "codes_for_group_name is not implemented"
71
- end
72
-
73
- def has_code_for_group_id(group_id, a_code)
74
-
75
- end
76
-
77
- def id=(id)
78
- @terminology = Terminology.find_all_by_name(id)
79
- @id = id
80
- end
81
-
82
- def rubric_for_code(code, lang)
83
- return Terminology.find(:first, :conditions => {:code => code,
84
- :lang => lang})
85
- end
86
-
87
- private
88
- def id_exists
89
- if id.nil?
90
- raise ArgumentError, "id must not be nil"
91
- elsif id.empty?
92
- raise ArgumentError, "id must not be empty"
93
- end
94
- end
95
- end
96
-
97
- class TerminologyService
98
- include OpenEHRCodeSetIdentifier, OpenEHRTerminologyGroupIdentifiers
99
-
100
- def code_set(name)
101
- raise NotImplementedError, "code_set is not implemented"
102
- end
103
-
104
- def code_set_for_id(id)
105
- raise NotImplementedError, "code_set_for_id is not implemented"
106
- end
107
-
108
- def code_set_identifiers
109
- raise NotImplementedError, "code_set_for_identifiers is not implemented"
110
- end
111
-
112
- def has_code_set(name)
113
- raise NotImplementedError, "has_code_set is not implemented"
114
- end
115
-
116
- def has_terminology?(name)
117
- raise NotImplementedError, "has_terminology is not implemented"
118
- end
119
-
120
- def openehr_code_sets
121
- raise NotImplementedError, "openehr_code_set is not implemented"
122
- end
123
-
124
- def terminology(name)
125
- return TerminologyAccess.new(:id => name)
126
- end
127
-
128
- def terminology_identifiers
129
- raise NotImplementedError, "terminology_identiferes is not implemented"
130
- end
131
- end
132
- end # of Terminology
133
- end # of Support
134
- end # of RM
135
- end # of OpenEHR
@@ -1,41 +0,0 @@
1
- require 'rubygems'
2
- require 'xmlsimple'
3
- #require 'ActiveSupport'
4
-
5
- module OpenEHR
6
- module Terminology
7
- class OpenEHRTerminology
8
- def initialize
9
- @terms = XmlSimple.xml_in(File.open('doc/openehr_terminology.xml'))
10
- end
11
-
12
- def languages
13
- @terms['Language']
14
- end
15
-
16
- def primary_rubrics
17
- @terms['PrimaryRubric']
18
- end
19
-
20
- def concepts
21
- @terms['Concept']
22
- end
23
-
24
- def groupers
25
- @terms['Grouper']
26
- end
27
-
28
- def grouped_concepts
29
- @terms['GroupedConcept']
30
- end
31
-
32
- def terminology_identifiers
33
- @terms['TerminologyIdentifiers']
34
- end
35
-
36
- def territories
37
- @terms['Territory']
38
- end
39
- end
40
- end
41
- end
@@ -1,7 +0,0 @@
1
- $:.unshift(File.dirname(__FILE__)) unless
2
- $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
3
- module OpenEHR
4
- module Terminology
5
- autoload :OpenEHRTerminology, 'terminology/open_ehr_terminology'
6
- end
7
- end
@@ -1,22 +0,0 @@
1
- require File.dirname(__FILE__) + '/../../../../spec_helper'
2
- include OpenEHR::RM::Support::Terminology
3
-
4
- describe TerminologyService do
5
- before(:each) do
6
- @ts ||= TerminologyService.new
7
- end
8
-
9
- it 'should get terminology by its name'
10
-
11
- it 'should get code_set by its name'
12
-
13
- it 'should reply if it has terminology or not'
14
-
15
- it 'should reply if it has terminology or not'
16
-
17
- it 'should reply all terminology_identifires'
18
-
19
- it 'should get openehr code stes'
20
-
21
- it 'should get code_set_identifiers'
22
- end
@@ -1,40 +0,0 @@
1
- require File.dirname(__FILE__) + '/../../../spec_helper'
2
-
3
- describe 'OpenEHRTerminology' do
4
- before(:each) do
5
- @term = OpenEHR::Terminology::OpenEHRTerminology.new
6
- end
7
-
8
- it 'should parse and return languages' do
9
- @term.languages[0].should == {'code' => 'af', 'Description' => 'Afrikaans'}
10
- end
11
-
12
- it 'should parse and return primary rubrics' do
13
- @term.primary_rubrics[0].should == {'Id' => '0', 'Language' => 'en'}
14
- end
15
-
16
- it 'should parse and return concepts' do
17
- @term.concepts[0].should == {'Rubric' => 'self', 'Language' => 'en',
18
- 'ConceptID' => '0'}
19
- end
20
-
21
- it 'should parse and return groupers' do
22
- @term.groupers[0].should == {'id' => '0', 'ConceptID' => '154'}
23
- end
24
-
25
- it 'should parse and return grouped_concepts' do
26
- @term.grouped_concepts[0].should == {'ChildID' => '0', 'GrouperID' => '1'}
27
- end
28
-
29
- it 'should parse and return terminology identifiers' do
30
- @term.terminology_identifiers[0].should ==
31
- {'VSAB' => 'AIR93', 'Authority' => 'UMLS2003AA',
32
- 'SourceName' => 'AI/RHEUM,1993'}
33
- end
34
-
35
- it 'should parse and return territory' do
36
- @term.territories[0].should ==
37
- {'Text' => 'Afghanistan', 'ThreeLetter'=>'AFG',
38
- 'NumericCode' => '004', 'TwoLetter' => 'AF'}
39
- end
40
- end