Class: Tracksperanto::Import::FlameStabilizer::StabilizerParser

Inherits:
FlameChannelParser::Parser
  • Object
show all
Defined in:
lib/import/flame_stabilizer.rb

Overview

We subclass the standard parser for a couple of reasons - we want to only parse the needed channels AND we want to provide progress reports

Constant Summary collapse

USEFUL_CHANNELS =
%w( /shift/x /shift/y /ref/x /ref/y ).map(&Regexp.method(:new))

Instance Method Summary collapse

Instance Method Details

#channel_is_useful?(channel_name) ⇒ Boolean

Returns:

  • (Boolean)


57
58
59
# File 'lib/import/flame_stabilizer.rb', line 57

def channel_is_useful?(channel_name)
  USEFUL_CHANNELS.any?{|e| channel_name =~ e }
end