Class: VisaAcceptanceMergedSpec::Features24
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- VisaAcceptanceMergedSpec::Features24
- Defined in:
- lib/visa_acceptance_merged_spec/models/features24.rb
Overview
Features24 Model.
Instance Attribute Summary collapse
-
#acceptance_level ⇒ String
This field contains the acceptance level of the PAN.
-
#account_funding_source ⇒ String
This field contains the account funding source.
-
#account_funding_source_sub_type ⇒ String
This field contains the type of prepaid card.
-
#card_platform ⇒ String
This field contains the type of card platform.
-
#card_product ⇒ String
This field contains the type of issuer product.
-
#combo_card ⇒ String
This field indicates the type of combo card.
-
#message_type ⇒ String
This field contains the type of BIN based authentication.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(account_funding_source: SKIP, account_funding_source_sub_type: SKIP, card_product: SKIP, message_type: SKIP, acceptance_level: SKIP, card_platform: SKIP, combo_card: SKIP, additional_properties: nil) ⇒ Features24
constructor
A new instance of Features24.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(account_funding_source: SKIP, account_funding_source_sub_type: SKIP, card_product: SKIP, message_type: SKIP, acceptance_level: SKIP, card_platform: SKIP, combo_card: SKIP, additional_properties: nil) ⇒ Features24
Returns a new instance of Features24.
104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 104 def initialize(account_funding_source: SKIP, account_funding_source_sub_type: SKIP, card_product: SKIP, message_type: SKIP, acceptance_level: SKIP, card_platform: SKIP, combo_card: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @account_funding_source = account_funding_source unless account_funding_source == SKIP unless account_funding_source_sub_type == SKIP @account_funding_source_sub_type = account_funding_source_sub_type end @card_product = card_product unless card_product == SKIP @message_type = unless == SKIP @acceptance_level = acceptance_level unless acceptance_level == SKIP @card_platform = card_platform unless card_platform == SKIP @combo_card = combo_card unless combo_card == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#acceptance_level ⇒ String
This field contains the acceptance level of the PAN. Possible values:
- `0` : Normal
- `1` : Monitor
- `2` : Refuse
- `3` : Not Allowed
- `4` : Private
- `5` : Test
53 54 55 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 53 def acceptance_level @acceptance_level end |
#account_funding_source ⇒ String
This field contains the account funding source. Possible values:
- `CREDIT`
- `DEBIT`
- `PREPAID`
- `DEFERRED DEBIT`
- `CHARGE`
20 21 22 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 20 def account_funding_source @account_funding_source end |
#account_funding_source_sub_type ⇒ String
This field contains the type of prepaid card. Possible values:
- `Reloadable`
- `Non-reloadable`
27 28 29 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 27 def account_funding_source_sub_type @account_funding_source_sub_type end |
#card_platform ⇒ String
This field contains the type of card platform. Possible values:
- `BUSINESS`
- `CONSUMER`
- `COMMERCIAL`
- `GOVERNMENT`
62 63 64 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 62 def card_platform @card_platform end |
#card_product ⇒ String
This field contains the type of issuer product. Example values:
- Visa Classic
- Visa Signature
- Visa Infinite
35 36 37 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 35 def card_product @card_product end |
#combo_card ⇒ String
This field indicates the type of combo card. Possible values:
- 0 (Not a combo card)
- 1 (Credit and Prepaid Combo card)
- 2 (Credit and Debit Combo card)
70 71 72 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 70 def combo_card @combo_card end |
#message_type ⇒ String
This field contains the type of BIN based authentication. Possible values:
- `S`: Single Message
- `D`: Dual Message
42 43 44 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 42 def @message_type end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 126 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. account_funding_source = hash.key?('accountFundingSource') ? hash['accountFundingSource'] : SKIP account_funding_source_sub_type = hash.key?('accountFundingSourceSubType') ? hash['accountFundingSourceSubType'] : SKIP card_product = hash.key?('cardProduct') ? hash['cardProduct'] : SKIP = hash.key?('messageType') ? hash['messageType'] : SKIP acceptance_level = hash.key?('acceptanceLevel') ? hash['acceptanceLevel'] : SKIP card_platform = hash.key?('cardPlatform') ? hash['cardPlatform'] : SKIP combo_card = hash.key?('comboCard') ? hash['comboCard'] : SKIP # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. Features24.new(account_funding_source: account_funding_source, account_funding_source_sub_type: account_funding_source_sub_type, card_product: card_product, message_type: , acceptance_level: acceptance_level, card_platform: card_platform, combo_card: combo_card, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
73 74 75 76 77 78 79 80 81 82 83 84 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 73 def self.names @_hash = {} if @_hash.nil? @_hash['account_funding_source'] = 'accountFundingSource' @_hash['account_funding_source_sub_type'] = 'accountFundingSourceSubType' @_hash['card_product'] = 'cardProduct' @_hash['message_type'] = 'messageType' @_hash['acceptance_level'] = 'acceptanceLevel' @_hash['card_platform'] = 'cardPlatform' @_hash['combo_card'] = 'comboCard' @_hash end |
.nullables ⇒ Object
An array for nullable fields
100 101 102 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 100 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
87 88 89 90 91 92 93 94 95 96 97 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 87 def self.optionals %w[ account_funding_source account_funding_source_sub_type card_product message_type acceptance_level card_platform combo_card ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
170 171 172 173 174 175 176 177 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 170 def inspect class_name = self.class.name.split('::').last "<#{class_name} account_funding_source: #{@account_funding_source.inspect},"\ " account_funding_source_sub_type: #{@account_funding_source_sub_type.inspect},"\ " card_product: #{@card_product.inspect}, message_type: #{@message_type.inspect},"\ " acceptance_level: #{@acceptance_level.inspect}, card_platform: #{@card_platform.inspect},"\ " combo_card: #{@combo_card.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
160 161 162 163 164 165 166 167 |
# File 'lib/visa_acceptance_merged_spec/models/features24.rb', line 160 def to_s class_name = self.class.name.split('::').last "<#{class_name} account_funding_source: #{@account_funding_source},"\ " account_funding_source_sub_type: #{@account_funding_source_sub_type}, card_product:"\ " #{@card_product}, message_type: #{@message_type}, acceptance_level: #{@acceptance_level},"\ " card_platform: #{@card_platform}, combo_card: #{@combo_card}, additional_properties:"\ " #{@additional_properties}>" end |