Class: Worldline::Connect::SDK::V1::Domain::CardFraudResults
- Inherits:
-
FraudResults
- Object
- Domain::DataObject
- FraudResults
- Worldline::Connect::SDK::V1::Domain::CardFraudResults
- Defined in:
- lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb
Instance Attribute Summary collapse
-
#avs_result ⇒ String
The current value of avs_result.
-
#cvv_result ⇒ String
The current value of cvv_result.
-
#fraugster ⇒ Worldline::Connect::SDK::V1::Domain::FraugsterResults
The current value of fraugster.
-
#retail_decisions ⇒ Worldline::Connect::SDK::V1::Domain::FraudResultsRetailDecisions
The current value of retail_decisions.
Attributes inherited from FraudResults
#fraud_service_result, #in_auth, #microsoft_fraud_protection
Instance Method Summary collapse
Methods inherited from Domain::DataObject
Instance Attribute Details
#avs_result ⇒ String
Returns the current value of avs_result.
18 19 20 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 18 def avs_result @avs_result end |
#cvv_result ⇒ String
Returns the current value of cvv_result.
18 19 20 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 18 def cvv_result @cvv_result end |
#fraugster ⇒ Worldline::Connect::SDK::V1::Domain::FraugsterResults
Returns the current value of fraugster.
18 19 20 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 18 def fraugster @fraugster end |
#retail_decisions ⇒ Worldline::Connect::SDK::V1::Domain::FraudResultsRetailDecisions
Returns the current value of retail_decisions.
18 19 20 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 18 def retail_decisions @retail_decisions end |
Instance Method Details
#from_hash(hash) ⇒ Object
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 38 def from_hash(hash) super if hash.has_key? 'avsResult' @avs_result = hash['avsResult'] end if hash.has_key? 'cvvResult' @cvv_result = hash['cvvResult'] end if hash.has_key? 'fraugster' raise TypeError, "value '%s' is not a Hash" % [hash['fraugster']] unless hash['fraugster'].is_a? Hash @fraugster = Worldline::Connect::SDK::V1::Domain::FraugsterResults.new_from_hash(hash['fraugster']) end if hash.has_key? 'retailDecisions' raise TypeError, "value '%s' is not a Hash" % [hash['retailDecisions']] unless hash['retailDecisions'].is_a? Hash @retail_decisions = Worldline::Connect::SDK::V1::Domain::FraudResultsRetailDecisions.new_from_hash(hash['retailDecisions']) end end |
#to_h ⇒ Hash
29 30 31 32 33 34 35 36 |
# File 'lib/worldline/connect/sdk/v1/domain/card_fraud_results.rb', line 29 def to_h hash = super hash['avsResult'] = @avs_result unless @avs_result.nil? hash['cvvResult'] = @cvv_result unless @cvv_result.nil? hash['fraugster'] = @fraugster.to_h unless @fraugster.nil? hash['retailDecisions'] = @retail_decisions.to_h unless @retail_decisions.nil? hash end |