Class: Datatrans::XML::Transaction::CaptureResponse
- Inherits:
-
Response
- Object
- Response
- Datatrans::XML::Transaction::CaptureResponse
show all
- Defined in:
- lib/datatrans/xml/transaction/capture.rb
Instance Attribute Summary
Attributes inherited from Response
#datatrans, #params
Instance Method Summary
collapse
Methods inherited from Response
#initialize
Instance Method Details
#error_code ⇒ Object
44
45
46
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 44
def error_code
params_root_node['error']['errorCode'] rescue nil
end
|
#error_detail ⇒ Object
52
53
54
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 52
def error_detail
params_root_node['error']['errorDetail'] rescue nil
end
|
#error_message ⇒ Object
48
49
50
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 48
def error_message
params_root_node['error']['errorMessage'] rescue nil
end
|
#reference_number ⇒ Object
40
41
42
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 40
def reference_number
params_root_node['refno'] rescue nil
end
|
#response_code ⇒ Object
28
29
30
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 28
def response_code
params_root_node['response']['responseCode'] rescue nil
end
|
#response_message ⇒ Object
32
33
34
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 32
def response_message
params_root_node['response']['responseMessage'] rescue nil
end
|
#successful? ⇒ Boolean
24
25
26
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 24
def successful?
response_code == '01' && response_message == 'settlement succeeded'
end
|
#transaction_id ⇒ Object
36
37
38
|
# File 'lib/datatrans/xml/transaction/capture.rb', line 36
def transaction_id
params_root_node['request']['uppTransactionId'] rescue nil
end
|