class OpenEHR::RM::DataStructures::History::History
Attributes
duration[RW]
events[R]
origin[R]
period[RW]
summary[RW]
Public Class Methods
new(args = { })
click to toggle source
Calls superclass method
OpenEHR::RM::DataStructures::DataStructure::new
# File lib/open_ehr/rm/data_structures/history.rb, line 20 def initialize(args = { }) super(args) self.origin = args[:origin] self.duration = args[:duration] self.period = args[:period] self.events = args[:events] self.summary = args[:summary] end
Public Instance Methods
events=(events)
click to toggle source
# File lib/open_ehr/rm/data_structures/history.rb, line 34 def events=(events) if !events.nil? and events.empty? raise ArgumentError, 'events should not be empty' end @events = events end
is_periodic?()
click to toggle source
# File lib/open_ehr/rm/data_structures/history.rb, line 41 def is_periodic? return !@period.nil? end
origin=(origin)
click to toggle source
# File lib/open_ehr/rm/data_structures/history.rb, line 29 def origin=(origin) raise ArgumentError, 'origin is mandatory' if origin.nil? @origin = origin end