Method: ExoBasic::Timer#merge_with

Defined in:
lib/exobasic/time/timer.rb

#merge_with(that) ⇒ Object



44
45
46
47
48
49
50
51
52
53
# File 'lib/exobasic/time/timer.rb', line 44

def merge_with(that)
  if that.start < @start
    @start    = that.start
    @samples += 1
  end
  if that.now > @now
    @now      = that.now
    @samples += 1
  end
end