Module: PromptNavigator::HistoryManageable
- Extended by:
- ActiveSupport::Concern
- Defined in:
- app/controllers/concerns/prompt_navigator/history_manageable.rb
Instance Method Summary collapse
- #initialize_history(history) ⇒ Object
- #push_to_history(new_state) ⇒ Object
- #set_active_message_uuid(uuid) ⇒ Object
Instance Method Details
#initialize_history(history) ⇒ Object
7 8 9 |
# File 'app/controllers/concerns/prompt_navigator/history_manageable.rb', line 7 def initialize_history(history) @history = history.to_a end |
#push_to_history(new_state) ⇒ Object
15 16 17 |
# File 'app/controllers/concerns/prompt_navigator/history_manageable.rb', line 15 def push_to_history(new_state) @history << new_state end |
#set_active_message_uuid(uuid) ⇒ Object
11 12 13 |
# File 'app/controllers/concerns/prompt_navigator/history_manageable.rb', line 11 def (uuid) @active_message_uuid = uuid end |