Class: Dogfood::Step

Inherits:
Object
  • Object
show all
Defined in:
lib/dogfood/step.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(number:, actor:, event:, action:, notes: nil) ⇒ Step

Returns a new instance of Step.



7
8
9
10
11
12
13
# File 'lib/dogfood/step.rb', line 7

def initialize(number:, actor:, event:, action:, notes: nil)
  @number = number
  @actor = actor
  @event = event
  @action = action
  @notes = notes || ""
end

Instance Attribute Details

#actionObject (readonly)

Returns the value of attribute action.



5
6
7
# File 'lib/dogfood/step.rb', line 5

def action
  @action
end

#actorObject (readonly)

Returns the value of attribute actor.



5
6
7
# File 'lib/dogfood/step.rb', line 5

def actor
  @actor
end

#eventObject (readonly)

Returns the value of attribute event.



5
6
7
# File 'lib/dogfood/step.rb', line 5

def event
  @event
end

#notesObject (readonly)

Returns the value of attribute notes.



5
6
7
# File 'lib/dogfood/step.rb', line 5

def notes
  @notes
end

#numberObject (readonly)

Returns the value of attribute number.



5
6
7
# File 'lib/dogfood/step.rb', line 5

def number
  @number
end

Instance Method Details

#to_rowObject



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

def to_row
  [number, actor, event, action, notes]
end