Module: Foobara::StateMachine::TransitionLog

Includes:
Concern
Included in:
Foobara::StateMachine
Defined in:
foobara-0.5.8/projects/typesystem/projects/state_machine/src/transition_log.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Concern

foobara_class_methods_module_for, foobara_concern?, included

Instance Attribute Details

#logObject

Returns the value of attribute log.



8
9
10
# File 'projects/typesystem/projects/state_machine/src/transition_log.rb', line 8

def log
  @log
end

Instance Method Details

#initializeObject



10
11
12
13
14
# File 'projects/typesystem/projects/state_machine/src/transition_log.rb', line 10

def initialize(...)
  super

  self.log = []
end

#log_transitionObject



16
17
18
# File 'projects/typesystem/projects/state_machine/src/transition_log.rb', line 16

def log_transition(**)
  log << LogEntry.new(**)
end