Class: VisaAcceptanceMergedSpec::PtsV2CreditsVoidsPost201Response
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- VisaAcceptanceMergedSpec::PtsV2CreditsVoidsPost201Response
- Defined in:
- lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb
Overview
PtsV2CreditsVoidsPost201Response Model.
Instance Attribute Summary collapse
-
#client_reference_information ⇒ ClientReferenceInformation1
The status of the submitted transaction.
-
#id ⇒ String
An unique identification number generated by Visa Acceptance to identify the submitted request.
-
#links ⇒ Links1
TODO: Write general description for this method.
-
#processor_information ⇒ ProcessorInformation10
The status of the submitted transaction.
-
#reconciliation_id ⇒ String
Reference number that you use to reconcile Visa Acceptance reports with your reports.
-
#status ⇒ String
The status of the submitted transaction.
-
#submit_time_utc ⇒ String
Time of request in UTC.
-
#void_amount_details ⇒ VoidAmountDetails
The status of the submitted transaction.
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(links: SKIP, id: SKIP, submit_time_utc: SKIP, status: SKIP, client_reference_information: SKIP, void_amount_details: SKIP, processor_information: SKIP, reconciliation_id: SKIP, additional_properties: nil) ⇒ PtsV2CreditsVoidsPost201Response
constructor
A new instance of PtsV2CreditsVoidsPost201Response.
-
#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(links: SKIP, id: SKIP, submit_time_utc: SKIP, status: SKIP, client_reference_information: SKIP, void_amount_details: SKIP, processor_information: SKIP, reconciliation_id: SKIP, additional_properties: nil) ⇒ PtsV2CreditsVoidsPost201Response
Returns a new instance of PtsV2CreditsVoidsPost201Response.
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 102 def initialize(links: SKIP, id: SKIP, submit_time_utc: SKIP, status: SKIP, client_reference_information: SKIP, void_amount_details: SKIP, processor_information: SKIP, reconciliation_id: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @links = links unless links == SKIP @id = id unless id == SKIP @submit_time_utc = submit_time_utc unless submit_time_utc == SKIP @status = status unless status == SKIP unless client_reference_information == SKIP @client_reference_information = client_reference_information end @void_amount_details = void_amount_details unless void_amount_details == SKIP @processor_information = processor_information unless processor_information == SKIP @reconciliation_id = reconciliation_id unless reconciliation_id == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#client_reference_information ⇒ ClientReferenceInformation1
The status of the submitted transaction. Possible values:
- VOIDED
- CANCELLED
- FAILED
46 47 48 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 46 def client_reference_information @client_reference_information end |
#id ⇒ String
An unique identification number generated by Visa Acceptance to identify the submitted request. Returned by all services. It is also appended to the endpoint of the resource. On incremental authorizations, this value with be the same as the identification number returned in the original authorization response.
22 23 24 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 22 def id @id end |
#links ⇒ Links1
TODO: Write general description for this method
14 15 16 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 14 def links @links end |
#processor_information ⇒ ProcessorInformation10
The status of the submitted transaction. Possible values:
- VOIDED
- CANCELLED
- FAILED
62 63 64 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 62 def processor_information @processor_information end |
#reconciliation_id ⇒ String
Reference number that you use to reconcile Visa Acceptance reports with your reports.
67 68 69 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 67 def reconciliation_id @reconciliation_id end |
#status ⇒ String
The status of the submitted transaction. Possible values:
- VOIDED
- CANCELLED
- FAILED
38 39 40 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 38 def status @status end |
#submit_time_utc ⇒ String
Time of request in UTC. Format: YYYY-MM-DDThh:mm:ssZ
Example 2016-08-11T22:47:57Z equals August 11, 2016, at 22:47:57
(10:47:57 p.m.).
The T separates the date and the time. The Z indicates UTC.
Returned by Visa Acceptance for all services.
30 31 32 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 30 def submit_time_utc @submit_time_utc end |
#void_amount_details ⇒ VoidAmountDetails
The status of the submitted transaction. Possible values:
- VOIDED
- CANCELLED
- FAILED
54 55 56 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 54 def void_amount_details @void_amount_details end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
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 151 152 153 154 155 156 157 158 159 160 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 124 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. links = Links1.from_hash(hash['_links']) if hash['_links'] id = hash.key?('id') ? hash['id'] : SKIP submit_time_utc = hash.key?('submitTimeUtc') ? hash['submitTimeUtc'] : SKIP status = hash.key?('status') ? hash['status'] : SKIP if hash['clientReferenceInformation'] client_reference_information = ClientReferenceInformation1.from_hash(hash['clientReferenceInformation']) end void_amount_details = VoidAmountDetails.from_hash(hash['voidAmountDetails']) if hash['voidAmountDetails'] processor_information = ProcessorInformation10.from_hash(hash['processorInformation']) if hash['processorInformation'] reconciliation_id = hash.key?('reconciliationId') ? hash['reconciliationId'] : 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. PtsV2CreditsVoidsPost201Response.new(links: links, id: id, submit_time_utc: submit_time_utc, status: status, client_reference_information: client_reference_information, void_amount_details: void_amount_details, processor_information: processor_information, reconciliation_id: reconciliation_id, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 70 def self.names @_hash = {} if @_hash.nil? @_hash['links'] = '_links' @_hash['id'] = 'id' @_hash['submit_time_utc'] = 'submitTimeUtc' @_hash['status'] = 'status' @_hash['client_reference_information'] = 'clientReferenceInformation' @_hash['void_amount_details'] = 'voidAmountDetails' @_hash['processor_information'] = 'processorInformation' @_hash['reconciliation_id'] = 'reconciliationId' @_hash end |
.nullables ⇒ Object
An array for nullable fields
98 99 100 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 98 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
84 85 86 87 88 89 90 91 92 93 94 95 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 84 def self.optionals %w[ links id submit_time_utc status client_reference_information void_amount_details processor_information reconciliation_id ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
173 174 175 176 177 178 179 180 181 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 173 def inspect class_name = self.class.name.split('::').last "<#{class_name} links: #{@links.inspect}, id: #{@id.inspect}, submit_time_utc:"\ " #{@submit_time_utc.inspect}, status: #{@status.inspect}, client_reference_information:"\ " #{@client_reference_information.inspect}, void_amount_details:"\ " #{@void_amount_details.inspect}, processor_information: #{@processor_information.inspect},"\ " reconciliation_id: #{@reconciliation_id.inspect}, additional_properties:"\ " #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
163 164 165 166 167 168 169 170 |
# File 'lib/visa_acceptance_merged_spec/models/pts_v2_credits_voids_post201_response.rb', line 163 def to_s class_name = self.class.name.split('::').last "<#{class_name} links: #{@links}, id: #{@id}, submit_time_utc: #{@submit_time_utc}, status:"\ " #{@status}, client_reference_information: #{@client_reference_information},"\ " void_amount_details: #{@void_amount_details}, processor_information:"\ " #{@processor_information}, reconciliation_id: #{@reconciliation_id},"\ " additional_properties: #{@additional_properties}>" end |