- def reset!
- return if broken?
- begin
- seek_to! start_offset
- rescue SourceError
- end
- end
- def == o; o.to_s == to_s; end
- def done?;
- return true if broken?
- begin
- (self.cur_offset ||= start_offset) >= end_offset
- rescue SourceError => e
- true
- end
- end
- def is_source_for? s; to_s == s; end
+ def reset!; seek_to! start_offset; end
+ def == o; o.uri == uri; end
+ def done?; start_offset.nil? || (self.cur_offset ||= start_offset) >= end_offset; end
+ def is_source_for? uri; uri == @uri; end
+
+ ## check should throw a FatalSourceError or an OutOfSyncSourcError
+ ## if it can detect a problem. it is called when the sup starts up
+ ## to proactively notify the user of any source problems.
+ def check; end