Class: Cheezmiz::LoginRequest

Inherits:
Message
  • Object
show all
Defined in:
lib/protocol/login.rb

Instance Method Summary collapse

Methods inherited from Message

#data_fields, #initialize, #operation, parse, #prototype, #sequence_number

Constructor Details

This class inherits a constructor from Cheezmiz::Message

Instance Method Details

#default_params(params) ⇒ Object



37
38
39
40
41
# File 'lib/protocol/login.rb', line 37

def default_params(params)
  params[:timezone] ||= 8
  params[:window_size] ||= 5 # 2..13
  params
end

#operation_codeObject



33
34
35
# File 'lib/protocol/login.rb', line 33

def operation_code
  '01'
end

#params_lutObject



24
25
26
27
28
29
30
31
# File 'lib/protocol/login.rb', line 24

def params_lut
  {
    :username => '005',
    :password => '002',
    :timezone => '004',
    :window_size => '003'
  }
end