class RethinkDB::AsyncHandler
Extend this class to define a new way of running rethinkdb queries asynchronously
Attributes
callback[RW]
The callback is set to be the user defined callback by the async_run method
connection[RW]
options[RW]
Public Instance Methods
handler()
click to toggle source
This method should return a handler that will deal with incoming messages
# File lib/nobrainer_streams/rethinkdb_monkeypatch.rb, line 19 def handler raise "Must override AsyncHandler#handler" end
run(&action)
click to toggle source
This method is called with a block that runs a rethinkdb connection synchronously
# File lib/nobrainer_streams/rethinkdb_monkeypatch.rb, line 14 def run(&action) raise "Must override AsyncHandler#run" end