Class: OpenEHR::RM::DataTypes::URI::DvEhrUri

Inherits:
DvUri show all
Defined in:
lib/open_ehr/rm/data_types/uri.rb

Constant Summary

Constants included from Support::Definition::BasicDefinition

Support::Definition::BasicDefinition::CR, Support::Definition::BasicDefinition::LF

Instance Attribute Summary

Attributes inherited from Basic::DataValue

#value

Instance Method Summary collapse

Methods inherited from DvUri

#fragment_id, #path, #query, #scheme, #value

Methods inherited from Basic::DataValue

#==

Constructor Details

#initialize(value) ⇒ DvEhrUri

Returns a new instance of DvEhrUri.



71
72
73
# File 'lib/open_ehr/rm/data_types/uri.rb', line 71

def initialize(value)
  super
end

Instance Method Details

#value=(value) ⇒ Object

Raises:

  • (ArgumentError)


75
76
77
78
# File 'lib/open_ehr/rm/data_types/uri.rb', line 75

def value=(value)
  raise ArgumentError, "scheme must be ehr" if !(value =~ /^ehr/i)
  parse(value)
end