class Cql::Protocol::SchemaChangeEventResponse

Constants

TYPE

Attributes

change[R]
keyspace[R]
table[R]
type[R]

Public Class Methods

decode(protocol_version, buffer, length, trace_id=nil) click to toggle source
# File lib/cql/protocol/responses/schema_change_event_response.rb, line 15
def self.decode(protocol_version, buffer, length, trace_id=nil)
  new(buffer.read_string, buffer.read_string, buffer.read_string)
end
new(*args) click to toggle source
# File lib/cql/protocol/responses/schema_change_event_response.rb, line 10
def initialize(*args)
  @change, @keyspace, @table = args
  @type = TYPE
end

Public Instance Methods

==(rs)
Alias for: eql?
eql?(rs) click to toggle source
# File lib/cql/protocol/responses/schema_change_event_response.rb, line 19
def eql?(rs)
  rs.type == self.type && rs.change == self.change && rs.keyspace == self.keyspace && rs.table == self.table
end
Also aliased as: ==
hash() click to toggle source
# File lib/cql/protocol/responses/schema_change_event_response.rb, line 24
def hash
  @h ||= begin
    h = 0
    h = ((h & 33554431) * 31) ^ @type.hash
    h = ((h & 33554431) * 31) ^ @change.hash
    h = ((h & 33554431) * 31) ^ @keyspace.hash
    h = ((h & 33554431) * 31) ^ @table.hash
    h
  end
end
to_s() click to toggle source
# File lib/cql/protocol/responses/schema_change_event_response.rb, line 35
def to_s
  %(EVENT #@type #@change "#@keyspace" "#@table")
end