Changeset 97 for ruby/trunk/lib/models/rm/support/identification.rb
- Timestamp:
- Aug 16, 2008, 6:46:52 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ruby/trunk/lib/models/rm/support/identification.rb
r95 r97 47 47 end 48 48 end 49 49 50 50 class Archetype_ID < Object_ID 51 51 attr_reader :domain_concept, :rm_name, :rm_entity, :rm_originator, :specialisation, :version_id … … 129 129 super(value) 130 130 end 131 131 132 def extension 132 133 if self.has_extension? … … 136 137 end 137 138 end 139 138 140 def has_extension? 139 141 @value.include? '::' 140 142 end 143 141 144 def root 142 145 if self.has_extension? … … 145 148 @value 146 149 end 150 end 151 end 152 153 class Locatable_Ref < Object_Ref 154 attr_reader :namespace, :type, :id, :path 155 156 def initialize(namespace, type, id, path) 157 super(namespace, type, id) 158 self.path = path 159 end 160 161 def path=(path) 162 raise ArgumentError if path.nil? or path.empty? 163 @path = path 164 end 165 166 def as_uri 167 'ehr://' + @id.value + '/' + @path 147 168 end 148 169 end
Note:
See TracChangeset
for help on using the changeset viewer.