Sha256: e8e588c20a8cea041d39b12f7fa4b87788409f637fe64f4919cd8839e12877f0

Contents?: true

Size: 402 Bytes

Versions: 9

Compression:

Stored size: 402 Bytes

Contents

module EMJack
  module Handler
    class Deleted
      RESPONSE = /^DELETED\r\n/

      def self.handles?(response)
        response =~ RESPONSE
      end

      def self.handle(deferrable, response, body, conn=nil)
        return false unless response =~ RESPONSE

        deferrable.succeed
        true
      end

      EMJack::Connection.register_handler(EMJack::Handler::Deleted)
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
em-jack-0.1.5 lib/em-jack/handlers/deleted.rb
em-jack-0.1.4 lib/em-jack/handlers/deleted.rb
em-jack-0.1.3 lib/em-jack/handlers/deleted.rb
em-jack-0.1.2 lib/em-jack/handlers/deleted.rb
em-jack-0.1.1 lib/em-jack/handlers/deleted.rb
em-jack-0.1.0 lib/em-jack/handlers/deleted.rb
em-jack-0.0.9 lib/em-jack/handlers/deleted.rb
em-jack-0.0.8 lib/em-jack/handlers/deleted.rb
em-jack-0.0.7 lib/em-jack/handlers/deleted.rb