Class: AdaptivePay::Callback

Inherits:
Object
  • Object
show all
Defined in:
lib/adaptive_pay/callback.rb

Instance Method Summary collapse

Constructor Details

#initialize(params) ⇒ Callback

Returns a new instance of Callback.



4
5
6
# File 'lib/adaptive_pay/callback.rb', line 4

def initialize(params)
  @params = params
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(name, *args) ⇒ Object



8
9
10
# File 'lib/adaptive_pay/callback.rb', line 8

def method_missing(name, *args)
  @params[name.to_s] || super
end

Instance Method Details

#completed?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/adaptive_pay/callback.rb', line 12

def completed?
  payment_status == "Completed"
end