class Syncano::Packets::Auth

Class representing auth packets used in communication with the Sync Server

Attributes

error[RW]
message_id[RW]
status[RW]

Public Class Methods

new(attributes) click to toggle source

Constructor for Syncano::Packets::Auth object @param [Hash] attributes

Calls superclass method Syncano::Packets::Base::new
# File lib/syncano/packets/auth.rb, line 9
def initialize(attributes)
  super(attributes)
  self.message_id = 'auth'
  self.status = attributes[:result]
  self.error = attributes[:error]
end

Public Instance Methods

auth?() click to toggle source

Returns true if is an auth packet @return [TrueClass, FalseClass]

# File lib/syncano/packets/auth.rb, line 18
def auth?
  true
end