Class: VisaAcceptanceMergedSpec::CreateOrderRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- VisaAcceptanceMergedSpec::CreateOrderRequest
- Defined in:
- lib/visa_acceptance_merged_spec/models/create_order_request.rb
Overview
CreateOrderRequest Model.
Instance Attribute Summary collapse
-
#client_reference_information ⇒ ClientReferenceInformation39
TODO: Write general description for this method.
-
#event_information ⇒ EventInformation
TODO: Write general description for this method.
-
#merchant_information ⇒ MerchantInformation16
TODO: Write general description for this method.
-
#order_information ⇒ OrderInformation30
TODO: Write general description for this method.
-
#payment_information ⇒ PaymentInformation26
TODO: Write general description for this method.
-
#processing_information ⇒ ProcessingInformation25
TODO: Write general description for this method.
-
#recipient_information ⇒ RecipientInformation2
TODO: Write general description for this method.
-
#sender_information ⇒ SenderInformation2
TODO: Write general description for this method.
-
#travel_information ⇒ TravelInformation8
TODO: Write general description for this method.
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(client_reference_information: SKIP, processing_information: SKIP, merchant_information: SKIP, payment_information: SKIP, order_information: SKIP, sender_information: SKIP, event_information: SKIP, travel_information: SKIP, recipient_information: SKIP, additional_properties: nil) ⇒ CreateOrderRequest
constructor
A new instance of CreateOrderRequest.
-
#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(client_reference_information: SKIP, processing_information: SKIP, merchant_information: SKIP, payment_information: SKIP, order_information: SKIP, sender_information: SKIP, event_information: SKIP, travel_information: SKIP, recipient_information: SKIP, additional_properties: nil) ⇒ CreateOrderRequest
Returns a new instance of CreateOrderRequest.
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 83 def initialize(client_reference_information: SKIP, processing_information: SKIP, merchant_information: SKIP, payment_information: SKIP, order_information: SKIP, sender_information: SKIP, event_information: SKIP, travel_information: SKIP, recipient_information: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? unless client_reference_information == SKIP @client_reference_information = client_reference_information end @processing_information = processing_information unless processing_information == SKIP @merchant_information = merchant_information unless merchant_information == SKIP @payment_information = payment_information unless payment_information == SKIP @order_information = order_information unless order_information == SKIP @sender_information = sender_information unless sender_information == SKIP @event_information = event_information unless event_information == SKIP @travel_information = travel_information unless travel_information == SKIP @recipient_information = recipient_information unless recipient_information == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#client_reference_information ⇒ ClientReferenceInformation39
TODO: Write general description for this method
14 15 16 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 14 def client_reference_information @client_reference_information end |
#event_information ⇒ EventInformation
TODO: Write general description for this method
38 39 40 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 38 def event_information @event_information end |
#merchant_information ⇒ MerchantInformation16
TODO: Write general description for this method
22 23 24 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 22 def merchant_information @merchant_information end |
#order_information ⇒ OrderInformation30
TODO: Write general description for this method
30 31 32 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 30 def order_information @order_information end |
#payment_information ⇒ PaymentInformation26
TODO: Write general description for this method
26 27 28 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 26 def payment_information @payment_information end |
#processing_information ⇒ ProcessingInformation25
TODO: Write general description for this method
18 19 20 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 18 def processing_information @processing_information end |
#recipient_information ⇒ RecipientInformation2
TODO: Write general description for this method
46 47 48 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 46 def recipient_information @recipient_information end |
#sender_information ⇒ SenderInformation2
TODO: Write general description for this method
34 35 36 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 34 def sender_information @sender_information end |
#travel_information ⇒ TravelInformation8
TODO: Write general description for this method
42 43 44 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 42 def travel_information @travel_information end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 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 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 108 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. if hash['clientReferenceInformation'] client_reference_information = ClientReferenceInformation39.from_hash(hash['clientReferenceInformation']) end processing_information = ProcessingInformation25.from_hash(hash['processingInformation']) if hash['processingInformation'] merchant_information = MerchantInformation16.from_hash(hash['merchantInformation']) if hash['merchantInformation'] payment_information = PaymentInformation26.from_hash(hash['paymentInformation']) if hash['paymentInformation'] order_information = OrderInformation30.from_hash(hash['orderInformation']) if hash['orderInformation'] sender_information = SenderInformation2.from_hash(hash['senderInformation']) if hash['senderInformation'] event_information = EventInformation.from_hash(hash['eventInformation']) if hash['eventInformation'] travel_information = TravelInformation8.from_hash(hash['travelInformation']) if hash['travelInformation'] recipient_information = RecipientInformation2.from_hash(hash['recipientInformation']) if hash['recipientInformation'] # 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. CreateOrderRequest.new(client_reference_information: client_reference_information, processing_information: processing_information, merchant_information: merchant_information, payment_information: payment_information, order_information: order_information, sender_information: sender_information, event_information: event_information, travel_information: travel_information, recipient_information: recipient_information, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
49 50 51 52 53 54 55 56 57 58 59 60 61 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 49 def self.names @_hash = {} if @_hash.nil? @_hash['client_reference_information'] = 'clientReferenceInformation' @_hash['processing_information'] = 'processingInformation' @_hash['merchant_information'] = 'merchantInformation' @_hash['payment_information'] = 'paymentInformation' @_hash['order_information'] = 'orderInformation' @_hash['sender_information'] = 'senderInformation' @_hash['event_information'] = 'eventInformation' @_hash['travel_information'] = 'travelInformation' @_hash['recipient_information'] = 'recipientInformation' @_hash end |
.nullables ⇒ Object
An array for nullable fields
79 80 81 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 79 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
64 65 66 67 68 69 70 71 72 73 74 75 76 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 64 def self.optionals %w[ client_reference_information processing_information merchant_information payment_information order_information sender_information event_information travel_information recipient_information ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
164 165 166 167 168 169 170 171 172 173 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 164 def inspect class_name = self.class.name.split('::').last "<#{class_name} client_reference_information: #{@client_reference_information.inspect},"\ " processing_information: #{@processing_information.inspect}, merchant_information:"\ " #{@merchant_information.inspect}, payment_information: #{@payment_information.inspect},"\ " order_information: #{@order_information.inspect}, sender_information:"\ " #{@sender_information.inspect}, event_information: #{@event_information.inspect},"\ " travel_information: #{@travel_information.inspect}, recipient_information:"\ " #{@recipient_information.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
153 154 155 156 157 158 159 160 161 |
# File 'lib/visa_acceptance_merged_spec/models/create_order_request.rb', line 153 def to_s class_name = self.class.name.split('::').last "<#{class_name} client_reference_information: #{@client_reference_information},"\ " processing_information: #{@processing_information}, merchant_information:"\ " #{@merchant_information}, payment_information: #{@payment_information}, order_information:"\ " #{@order_information}, sender_information: #{@sender_information}, event_information:"\ " #{@event_information}, travel_information: #{@travel_information}, recipient_information:"\ " #{@recipient_information}, additional_properties: #{@additional_properties}>" end |