mongo-ruby-driver/lib/mongo/message/kill_cursors_message.rb

21 lines
363 B
Ruby
Raw Normal View History

2008-11-22 01:00:51 +00:00
require 'mongo/message/message'
require 'mongo/message/opcodes'
module XGen
module Mongo
module Driver
class KillCursorsMessage < Message
def initialize(*cursors)
super(OP_KILL_CURSORS)
write_int(0)
write_int(cursors.length)
cursors.each { |c| write_long c }
end
end
end
end
end