Sha256: 04358ac1c1b3b85daa9a3f83eb666f4ce9e76ae6cceffa4248216d0b9c50ee05
Contents?: true
Size: 862 Bytes
Versions: 37
Compression:
Stored size: 862 Bytes
Contents
# Toplevel Pubnub module. module Pubnub # Every message from server is formatted into easy to use Envelope object class Envelope # Ruby specific attr_accessor :id, :first, :last attr_accessor :history_start, :history_end # Pubnub Required attr_accessor :status, :result, :timetoken def initialize(options) @id = UUID.generate # internal usage only @event = options[:event] @event_options = options[:event_options] @status = options[:status] @result = options[:result] @timetoken = options[:timetoken] end def repeat(client, changes = {}) client.send @event, @event_options.merge(changes) end def error? @status[:error] end # :nocov: def last? last end # :nocov: # :nocov: def first? first end # :nocov: end end
Version data entries
37 entries across 37 versions & 1 rubygems