Class: FdxV660Api::OccurrenceBasedLimitsForAPaymentNetwork
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- FdxV660Api::OccurrenceBasedLimitsForAPaymentNetwork
- Defined in:
- lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb
Overview
This provides the occurrence-based limits applied to the account within the payment network
Instance Attribute Summary collapse
-
#transfer_max_amount ⇒ Float
Maximum limit of funds that can be transferred to/from the account using the timeframe limits.
-
#transfer_remaining_amount ⇒ Float
Remaining value of the maximum limit of funds that can be transferred to/from the account using the timeframe limits.
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(transfer_max_amount: SKIP, transfer_remaining_amount: SKIP, additional_properties: nil) ⇒ OccurrenceBasedLimitsForAPaymentNetwork
constructor
A new instance of OccurrenceBasedLimitsForAPaymentNetwork.
-
#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(transfer_max_amount: SKIP, transfer_remaining_amount: SKIP, additional_properties: nil) ⇒ OccurrenceBasedLimitsForAPaymentNetwork
Returns a new instance of OccurrenceBasedLimitsForAPaymentNetwork.
44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 44 def initialize(transfer_max_amount: SKIP, transfer_remaining_amount: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @transfer_max_amount = transfer_max_amount unless transfer_max_amount == SKIP unless transfer_remaining_amount == SKIP @transfer_remaining_amount = transfer_remaining_amount end @additional_properties = additional_properties end |
Instance Attribute Details
#transfer_max_amount ⇒ Float
Maximum limit of funds that can be transferred to/from the account using the timeframe limits
16 17 18 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 16 def transfer_max_amount @transfer_max_amount end |
#transfer_remaining_amount ⇒ Float
Remaining value of the maximum limit of funds that can be transferred to/from the account using the timeframe limits
21 22 23 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 21 def transfer_remaining_amount @transfer_remaining_amount end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 58 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. transfer_max_amount = hash.key?('transferMaxAmount') ? hash['transferMaxAmount'] : SKIP transfer_remaining_amount = hash.key?('transferRemainingAmount') ? hash['transferRemainingAmount'] : 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. OccurrenceBasedLimitsForAPaymentNetwork.new(transfer_max_amount: transfer_max_amount, transfer_remaining_amount: transfer_remaining_amount, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
24 25 26 27 28 29 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 24 def self.names @_hash = {} if @_hash.nil? @_hash['transfer_max_amount'] = 'transferMaxAmount' @_hash['transfer_remaining_amount'] = 'transferRemainingAmount' @_hash end |
.nullables ⇒ Object
An array for nullable fields
40 41 42 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 40 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
32 33 34 35 36 37 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 32 def self.optionals %w[ transfer_max_amount transfer_remaining_amount ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
88 89 90 91 92 93 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 88 def inspect class_name = self.class.name.split('::').last "<#{class_name} transfer_max_amount: #{@transfer_max_amount.inspect},"\ " transfer_remaining_amount: #{@transfer_remaining_amount.inspect}, additional_properties:"\ " #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
81 82 83 84 85 |
# File 'lib/fdx_v660_api/models/occurrence_based_limits_for_a_payment_network.rb', line 81 def to_s class_name = self.class.name.split('::').last "<#{class_name} transfer_max_amount: #{@transfer_max_amount}, transfer_remaining_amount:"\ " #{@transfer_remaining_amount}, additional_properties: #{@additional_properties}>" end |