Class: Syskit::Coordination::DataMonitoringErrorMatcher

Inherits:
Roby::Queries::LocalizedErrorMatcher
  • Object
show all
Defined in:
lib/syskit/coordination/data_monitoring_error_matcher.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeDataMonitoringErrorMatcher

Returns a new instance of DataMonitoringErrorMatcher



7
8
9
10
# File 'lib/syskit/coordination/data_monitoring_error_matcher.rb', line 7

def initialize
    super
    with_model(DataMonitoringError)
end

Instance Attribute Details

#monitorObject (readonly)

The monitor model that should be matched



5
6
7
# File 'lib/syskit/coordination/data_monitoring_error_matcher.rb', line 5

def monitor
  @monitor
end

Instance Method Details

#===(exception) ⇒ Object



17
18
19
20
# File 'lib/syskit/coordination/data_monitoring_error_matcher.rb', line 17

def ===(exception)
    return false if !super
    exception.monitor.model == monitor
end

#from_monitor(monitor) ⇒ Object



12
13
14
15
# File 'lib/syskit/coordination/data_monitoring_error_matcher.rb', line 12

def from_monitor(monitor)
    @monitor = monitor
    self
end