Class: Providence::EventHandler::Darwin
- Inherits:
-
FSEvent
- Object
- FSEvent
- Providence::EventHandler::Darwin
- Includes:
- Watchr::EventHandler::Base
- Defined in:
- lib/providence/event_handlers/darwin.rb
Overview
Uses ruby-fsevents (github.com/thibaudgg/rb-fsevent)
Instance Attribute Summary collapse
-
#watched_paths ⇒ Object
Returns the value of attribute watched_paths.
Instance Method Summary collapse
-
#initialize ⇒ Darwin
constructor
A new instance of Darwin.
- #listen(monitored_paths) ⇒ Object
- #refresh(monitored_paths) ⇒ Object
Constructor Details
#initialize ⇒ Darwin
Returns a new instance of Darwin.
11 12 13 |
# File 'lib/providence/event_handlers/darwin.rb', line 11 def initialize super end |
Instance Attribute Details
#watched_paths ⇒ Object
Returns the value of attribute watched_paths.
8 9 10 |
# File 'lib/providence/event_handlers/darwin.rb', line 8 def watched_paths @watched_paths end |
Instance Method Details
#listen(monitored_paths) ⇒ Object
15 16 17 18 |
# File 'lib/providence/event_handlers/darwin.rb', line 15 def listen(monitored_paths) watch_paths(monitored_paths) run end |
#refresh(monitored_paths) ⇒ Object
20 21 22 23 |
# File 'lib/providence/event_handlers/darwin.rb', line 20 def refresh(monitored_paths) stop listen(monitored_paths) end |