class TRecs::HashStrategy
Attributes
frames_to_save[RW]
Public Class Methods
new(frames_to_save={})
click to toggle source
# File lib/trecs/strategies/hash_strategy.rb, line 9 def initialize(frames_to_save={}) @frames_to_save = frames_to_save || Hash.new @command = frames_to_save.fetch(:command) { nil } end
Public Instance Methods
inspect()
click to toggle source
# File lib/trecs/strategies/hash_strategy.rb, line 27 def inspect "<#{self.class}: frames: #{frames}>" end
perform()
click to toggle source
# File lib/trecs/strategies/hash_strategy.rb, line 14 def perform @frames_to_save.each do |time, content| if time.is_a?(Numeric) || /\A\d+\Z/ === time current_time(time.to_s.to_i) current_content(content) save_frame end end end
stop()
click to toggle source
# File lib/trecs/strategies/hash_strategy.rb, line 24 def stop end