class LogTools::PostProcessing::Matcher

Public Instance Methods

filters_logfiles?() click to toggle source

Tests if this matcher acts on the log files (i.e. if {matches_logfile?} does something). If false, matches_logfile? will not be called and all included streams will be passed to {matches_stream?}

# File lib/log_tools/post_processing.rb, line 291
def filters_logfiles?; false end
filters_streams?() click to toggle source

Tests if this matcher acts on the streams (i.e. if {matches_streams?} does something). If false, matches_streams? will not be called and all included streams will be passed to {matching_regions}

# File lib/log_tools/post_processing.rb, line 297
def filters_streams?; false end
matches_logfile?(path) click to toggle source

Tests if this matcher object requires to include or exclude a logfile

@param [String] path the logfile's basename @return [Boolean] whether the log file is matched by this object

or not
# File lib/log_tools/post_processing.rb, line 305
def matches_logfile?(path); end
matches_stream?(stream) click to toggle source

Tests if this matcher object requires to include or exclude a stream

If {filters_logfiles?} returns true, this method will be called only for streams for which {matches_logfile?} returned true.

@param [Pocolog::DataStream] stream the stream object @return [Boolean] whether the stream is matched by this object

or not
# File lib/log_tools/post_processing.rb, line 316
def matches_stream?(stream); end
matching_regions(stream, annotations) click to toggle source

Returns which parts of a stream should be processed

If either {filters_logfiles?} or {filters_streams?} return true, this method will be called only for streams for which the corresponding matching methods returned true.

@param [Pocolog::DataStream] stream the stream object @param [Array<Types::Logger::Annotations>] annotations the annotations

known to this dataset that apply to this stream

@return [Array<Region>]

# File lib/log_tools/post_processing.rb, line 328
def matching_regions(stream, annotations); [Region.new(*stream.time_interval)] end