Class: Cheezmiz::SubmitRequest
Instance Method Summary
collapse
Methods inherited from Message
#data_fields, #initialize, #operation, parse, #prototype, #sequence_number
Instance Method Details
#check_params(params) ⇒ Object
44
45
46
47
48
|
# File 'lib/protocol/submit.rb', line 44
def check_params(params)
if params.has_key?(:msisdn) && params.has_key?(:buddy_number)
raise 'msisdn and buddy_number cannot be both present'
end
end
|
#default_params(params) ⇒ Object
39
40
41
42
|
# File 'lib/protocol/submit.rb', line 39
def default_params(params)
params[:type] ||= 1 params
end
|
#operation_code ⇒ Object
35
36
37
|
# File 'lib/protocol/submit.rb', line 35
def operation_code
'14'
end
|
#params_lut ⇒ Object
24
25
26
27
28
29
30
31
32
33
|
# File 'lib/protocol/submit.rb', line 24
def params_lut
{
:message => '032',
:buddy_number => '021', :origin => '023', :time_stamp => '022', :type => '030',
:msisdn => '001'
}
end
|