Class: EM::PG::Watcher
- Inherits:
-
Connection
- Object
- Connection
- EM::PG::Watcher
- Defined in:
- lib/em/pg.rb
Instance Attribute Summary collapse
-
#postgres ⇒ Object
Returns the value of attribute postgres.
Instance Method Summary collapse
-
#initialize(postgres) ⇒ Watcher
constructor
A new instance of Watcher.
- #notify_readable ⇒ Object
- #notify_writable ⇒ Object
- #unbind ⇒ Object
Constructor Details
#initialize(postgres) ⇒ Watcher
Returns a new instance of Watcher.
35 36 37 |
# File 'lib/em/pg.rb', line 35 def initialize(postgres) @postgres = postgres end |
Instance Attribute Details
#postgres ⇒ Object
Returns the value of attribute postgres.
34 35 36 |
# File 'lib/em/pg.rb', line 34 def postgres @postgres end |
Instance Method Details
#notify_readable ⇒ Object
39 40 41 |
# File 'lib/em/pg.rb', line 39 def notify_readable @postgres.handle end |
#notify_writable ⇒ Object
43 44 45 46 |
# File 'lib/em/pg.rb', line 43 def notify_writable self.notify_writable = false @postgres.handle end |
#unbind ⇒ Object
48 49 50 |
# File 'lib/em/pg.rb', line 48 def unbind @postgres.unbind end |