class OpenEHR::RM::DataStructures::History::Event
Attributes
data[R]
state[RW]
time[R]
Public Class Methods
new(args = { })
click to toggle source
Calls superclass method
OpenEHR::RM::Common::Archetyped::Locatable::new
# File lib/openehr/rm/data_structures/history.rb, line 52 def initialize(args = { }) super(args) self.data = args[:data] self.time = args[:time] self.state = args[:state] end
Public Instance Methods
data=(data)
click to toggle source
# File lib/openehr/rm/data_structures/history.rb, line 59 def data=(data) raise ArgumentError, 'data is mandatory' if data.nil? @data = data end
offset()
click to toggle source
# File lib/openehr/rm/data_structures/history.rb, line 69 def offset return @time.diff(@parent.origin) end
time=(time)
click to toggle source
# File lib/openehr/rm/data_structures/history.rb, line 64 def time=(time) raise ArgumentError, 'time is mandatory' if time.nil? @time = time end