class OpenEHR::RM::Support::Identification::ObjectRef

Attributes

id[R]
namespace[R]
type[R]

Public Class Methods

new(args = {}) click to toggle source
# File lib/open_ehr/rm/support/identification.rb, line 29
def initialize(args = {})
  self.namespace = args[:namespace]
  self.type = args[:type]
  self.id = args[:id]
end

Public Instance Methods

id=(id) click to toggle source
# File lib/open_ehr/rm/support/identification.rb, line 48
def id=(id)
  raise ArgumentError if id.nil?
  @id = id
end
namespace=(namespace) click to toggle source
# File lib/open_ehr/rm/support/identification.rb, line 35
def namespace=(namespace)
  if namespace.nil? or namespace.empty? or 
      !(/^[a-zA-Z][a-zA-Z0-9_\-\:\/\&\+\?]*$/ =~ namespace)
    raise ArgumentError
  end
  @namespace = namespace
end
type=(type) click to toggle source
# File lib/open_ehr/rm/support/identification.rb, line 43
def type=(type)
  raise ArgumentError if type.nil? or type.empty?
  @type = type
end