Sha256: 5a532560c77e8121dbbcc992d2f7b55682f58b4f5e696ca2b8b7031f59529ee5
Contents?: true
Size: 500 Bytes
Versions: 3
Compression:
Stored size: 500 Bytes
Contents
module Himekaminize module Filters class TaskFilter < BaseFilter # @note Override # @param array [Array] # @return [Array] def call(array) seq = 0 array.map do |line| if line.is_a?(String) && line =~ /\A\s*(#{Himekaminize::Task::INCOMPLETE_PATTERN}|#{Himekaminize::Task::COMPLETE_PATTERN})/ seq += 1 Himekaminize::Task.new(line, seq) else line end end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
himekaminize-0.0.4 | lib/himekaminize/filters/task_filter.rb |
himekaminize-0.0.3 | lib/himekaminize/filters/task_filter.rb |
himekaminize-0.0.2 | lib/himekaminize/filters/task_filter.rb |