class TRecs::YamlStoreReader
Attributes
file[R]
frames[R]
player[RW]
timestamps[R]
Public Class Methods
new(options={})
click to toggle source
# File lib/trecs/readers/yaml_store_reader.rb, line 11 def initialize(options={}) # trecs_file -> output file by convention @file = options.fetch(:trecs_file) File.open(@file) store = YAML::Store.new Pathname(@file) @frames = store.transaction do store["frames"] end @timestamps = @frames.keys end
Public Instance Methods
frame_at(time)
click to toggle source
# File lib/trecs/readers/yaml_store_reader.rb, line 27 def frame_at(time) @frames[time] end
setup()
click to toggle source
# File lib/trecs/readers/yaml_store_reader.rb, line 23 def setup true end
to_s()
click to toggle source
# File lib/trecs/readers/yaml_store_reader.rb, line 31 def to_s "<#{self.class}>" end
Also aliased as: inspect