Class: Logbook::Duration

Inherits:
Struct
  • Object
show all
Defined in:
lib/logbook.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#minutesObject

Returns the value of attribute minutes

Returns:

  • (Object)

    the current value of minutes



14
15
16
# File 'lib/logbook.rb', line 14

def minutes
  @minutes
end

Instance Method Details

#+(other_duration) ⇒ Object



15
16
17
# File 'lib/logbook.rb', line 15

def +(other_duration)
  Duration.new(self.minutes + other_duration.minutes)
end