Class: Mongo::Cursor::Builder::OpGetMore
- Inherits:
-
Object
- Object
- Mongo::Cursor::Builder::OpGetMore
- Extended by:
- Forwardable
- Defined in:
- lib/mongo/cursor/builder/op_get_more.rb
Overview
Encapsulates behaviour around generating an OP_GET_MORE specification.
Instance Attribute Summary collapse
-
#cursor ⇒ Cursor
readonly
Cursor The cursor.
Instance Method Summary collapse
-
#initialize(cursor) ⇒ OpGetMore
constructor
Create the new builder.
-
#specification ⇒ Hash
Get the specification.
Constructor Details
#initialize(cursor) ⇒ OpGetMore
Create the new builder.
38 39 40 |
# File 'lib/mongo/cursor/builder/op_get_more.rb', line 38 def initialize(cursor) @cursor = cursor end |
Instance Attribute Details
#cursor ⇒ Cursor (readonly)
Returns cursor The cursor.
26 27 28 |
# File 'lib/mongo/cursor/builder/op_get_more.rb', line 26 def cursor @cursor end |
Instance Method Details
#specification ⇒ Hash
Get the specification.
50 51 52 53 54 55 56 57 |
# File 'lib/mongo/cursor/builder/op_get_more.rb', line 50 def specification { :to_return => to_return, :cursor_id => cursor.id, :db_name => database.name, :coll_name => collection_name } end |