Module: MongoMutation::CursorMutation
- Defined in:
- lib/mongo_mutation.rb
Overview
Cursor =
Class Method Summary collapse
Instance Method Summary collapse
-
#each_mutant(&b) ⇒ Object
legacy.
- #each_mutant_with_index(&b) ⇒ Object
- #next ⇒ Object
- #set_mutant_class ⇒ Object
Class Method Details
.extended(into) ⇒ Object
257 258 259 |
# File 'lib/mongo_mutation.rb', line 257 def self.extended(into) into.set_mutant_class end |
Instance Method Details
#each_mutant(&b) ⇒ Object
legacy
268 |
# File 'lib/mongo_mutation.rb', line 268 def each_mutant(&b); each(&b); end |
#each_mutant_with_index(&b) ⇒ Object
269 |
# File 'lib/mongo_mutation.rb', line 269 def each_mutant_with_index(&b); each_with_index(&b); end |
#next ⇒ Object
263 264 265 266 |
# File 'lib/mongo_mutation.rb', line 263 def next n = super n.nil? ? nil : @mutant_class.new(n) end |
#set_mutant_class ⇒ Object
260 261 262 |
# File 'lib/mongo_mutation.rb', line 260 def set_mutant_class @mutant_class = Kernel.const_get(collection.name) end |