change_healthcare-professional_claims 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +12 -0
- data/.rspec +3 -0
- data/.rubocop.yml +30 -0
- data/.travis.yml +6 -0
- data/.yardopts +1 -0
- data/CHANGELOG.md +0 -0
- data/Gemfile +6 -0
- data/Gemfile.lock +118 -0
- data/LICENSE.txt +21 -0
- data/README.md +39 -0
- data/Rakefile +8 -0
- data/TODO.md +8 -0
- data/bin/console +15 -0
- data/bin/rspec +29 -0
- data/bin/setup +8 -0
- data/change_healthcare-professional_claims.gemspec +43 -0
- data/lib/change_healthcare/professional_claims.rb +16 -0
- data/lib/change_healthcare/professional_claims/swagger_client.rb +106 -0
- data/lib/change_healthcare/professional_claims/swagger_client/api_client.rb +390 -0
- data/lib/change_healthcare/professional_claims/swagger_client/api_error.rb +42 -0
- data/lib/change_healthcare/professional_claims/swagger_client/configuration.rb +204 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/address.rb +219 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/ambulance_certification.rb +247 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/ambulance_transport_information.rb +259 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/clai_request.rb +283 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_adjustment.rb +244 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_adjustment_details.rb +199 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_contract_information.rb +265 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_date_information.rb +298 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_information.rb +579 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_note.rb +216 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_pricing_repricing_information.rb +363 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_reference.rb +231 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_submission_request.rb +278 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/claim_supplemental_information.rb +315 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/composite_diagnosis_code_pointers.rb +191 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/condition_indicator_durable_medical_equipment.rb +281 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/condition_information.rb +190 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/contact_information.rb +209 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/contract_information.rb +255 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/dependent.rb +294 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/drug_identification.rb +278 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/durable_medical_equipment_certificate_of_medical_necessity.rb +226 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/durable_medical_equipment_certification.rb +233 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/durable_medical_equipment_service.rb +243 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/edit_response.rb +251 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/epsdt_referral.rb +236 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/error.rb +214 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/failure.rb +194 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/form_identification.rb +240 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/health_care_information.rb +233 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/line_adjudication_information.rb +284 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/measurements.rb +256 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/medicare_outpatient_adjudication.rb +213 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_billing_provider.rb +236 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_name.rb +285 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_referring_provider.rb +192 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_rendering_provider.rb +236 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_service_facility_location.rb +192 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_supervising_provider.rb +192 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_subscriber_information.rb +430 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/other_subscriber_name.rb +288 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/patient_condition_information_vision.rb +259 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/pay_to_plan.rb +278 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/payer.rb +194 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/prior_authorization.rb +194 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/professional_service.rb +290 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/provider.rb +281 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/purchased_service_information.rb +194 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/raw_x12_request.rb +194 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/receiver.rb +189 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/reference_identification.rb +199 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/report_information.rb +261 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/response.rb +240 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/service_facility_location.rb +224 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/service_line.rb +388 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/service_line_date_information.rb +236 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/service_line_provider.rb +293 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/service_line_reference_information.rb +230 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/spinal_manipulation_service_information.rb +238 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/submitter.rb +209 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/subscriber.rb +309 -0
- data/lib/change_healthcare/professional_claims/swagger_client/models/supporting_documentation.rb +249 -0
- data/lib/change_healthcare/professional_claims/swagger_client/professional_claims_api.rb +361 -0
- data/lib/change_healthcare/professional_claims/swagger_client/version.rb +19 -0
- data/lib/change_healthcare/professional_claims/version.rb +7 -0
- data/lib/change_healthcare/professional_claims/wrapper.rb +141 -0
- metadata +274 -0
@@ -0,0 +1,213 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# #Medical Network Professional Claims v3
|
4
|
+
#
|
5
|
+
# Reference for developers
|
6
|
+
#
|
7
|
+
# OpenAPI spec version: v3
|
8
|
+
#
|
9
|
+
# Generated by: https://github.com/swagger-api/swagger-codegen.git
|
10
|
+
# Swagger Codegen version: 2.4.19
|
11
|
+
#
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module ChangeHealthcare
|
16
|
+
module ProfessionalClaims
|
17
|
+
module SwaggerClient
|
18
|
+
class MedicareOutpatientAdjudication
|
19
|
+
attr_accessor :claim_payment_remark_code, :end_stage_renal_disease_payment_amount, :hcpcs_payable_amount,
|
20
|
+
:non_payable_professional_component_billed_amount, :reimbursement_rate
|
21
|
+
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
23
|
+
def self.attribute_map
|
24
|
+
{
|
25
|
+
claim_payment_remark_code: :claimPaymentRemarkCode,
|
26
|
+
end_stage_renal_disease_payment_amount: :endStageRenalDiseasePaymentAmount,
|
27
|
+
hcpcs_payable_amount: :hcpcsPayableAmount,
|
28
|
+
non_payable_professional_component_billed_amount: :nonPayableProfessionalComponentBilledAmount,
|
29
|
+
reimbursement_rate: :reimbursementRate
|
30
|
+
}
|
31
|
+
end
|
32
|
+
|
33
|
+
# Attribute type mapping.
|
34
|
+
def self.swagger_types
|
35
|
+
{
|
36
|
+
claim_payment_remark_code: :'Array<String>',
|
37
|
+
end_stage_renal_disease_payment_amount: :String,
|
38
|
+
hcpcs_payable_amount: :String,
|
39
|
+
non_payable_professional_component_billed_amount: :String,
|
40
|
+
reimbursement_rate: :String
|
41
|
+
}
|
42
|
+
end
|
43
|
+
|
44
|
+
# Initializes the object
|
45
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
46
|
+
def initialize(attributes = {})
|
47
|
+
return unless attributes.is_a?(Hash)
|
48
|
+
|
49
|
+
# convert string to symbol for hash key
|
50
|
+
attributes = attributes.transform_keys(&:to_sym)
|
51
|
+
|
52
|
+
if attributes.key?(:claimPaymentRemarkCode) && (value = attributes[:claimPaymentRemarkCode]).is_a?(Array)
|
53
|
+
self.claim_payment_remark_code = value
|
54
|
+
end
|
55
|
+
|
56
|
+
self.end_stage_renal_disease_payment_amount = attributes[:endStageRenalDiseasePaymentAmount] if attributes.key?(:endStageRenalDiseasePaymentAmount)
|
57
|
+
|
58
|
+
self.hcpcs_payable_amount = attributes[:hcpcsPayableAmount] if attributes.key?(:hcpcsPayableAmount)
|
59
|
+
|
60
|
+
self.non_payable_professional_component_billed_amount = attributes[:nonPayableProfessionalComponentBilledAmount] if attributes.key?(:nonPayableProfessionalComponentBilledAmount)
|
61
|
+
|
62
|
+
self.reimbursement_rate = attributes[:reimbursementRate] if attributes.key?(:reimbursementRate)
|
63
|
+
end
|
64
|
+
|
65
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
66
|
+
# @return Array for valid properties with the reasons
|
67
|
+
def list_invalid_properties
|
68
|
+
[]
|
69
|
+
end
|
70
|
+
|
71
|
+
# Check to see if the all the properties in the model are valid
|
72
|
+
# @return true if the model is valid
|
73
|
+
def valid?
|
74
|
+
true
|
75
|
+
end
|
76
|
+
|
77
|
+
# Checks equality by comparing each attribute.
|
78
|
+
# @param [Object] Object to be compared
|
79
|
+
def ==(other)
|
80
|
+
return true if equal?(other)
|
81
|
+
|
82
|
+
self.class == other.class &&
|
83
|
+
claim_payment_remark_code == other.claim_payment_remark_code &&
|
84
|
+
end_stage_renal_disease_payment_amount == other.end_stage_renal_disease_payment_amount &&
|
85
|
+
hcpcs_payable_amount == other.hcpcs_payable_amount &&
|
86
|
+
non_payable_professional_component_billed_amount == other.non_payable_professional_component_billed_amount &&
|
87
|
+
reimbursement_rate == other.reimbursement_rate
|
88
|
+
end
|
89
|
+
|
90
|
+
# @see the `==` method
|
91
|
+
# @param [Object] Object to be compared
|
92
|
+
def eql?(other)
|
93
|
+
self == other
|
94
|
+
end
|
95
|
+
|
96
|
+
# Calculates hash code according to all attributes.
|
97
|
+
# @return [Fixnum] Hash code
|
98
|
+
def hash
|
99
|
+
[claim_payment_remark_code, end_stage_renal_disease_payment_amount, hcpcs_payable_amount,
|
100
|
+
non_payable_professional_component_billed_amount, reimbursement_rate].hash
|
101
|
+
end
|
102
|
+
|
103
|
+
# Builds the object from hash
|
104
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
105
|
+
# @return [Object] Returns the model itself
|
106
|
+
def build_from_hash(attributes)
|
107
|
+
return nil unless attributes.is_a?(Hash)
|
108
|
+
|
109
|
+
self.class.swagger_types.each_pair do |key, type|
|
110
|
+
if type =~ /\AArray<(.*)>/i
|
111
|
+
# check to ensure the input is an array given that the attribute
|
112
|
+
# is documented as an array but the input is not
|
113
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
114
|
+
send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
|
115
|
+
_deserialize(Regexp.last_match(1), v)
|
116
|
+
end)
|
117
|
+
end
|
118
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
119
|
+
send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
self
|
124
|
+
end
|
125
|
+
|
126
|
+
# Deserializes the data based on type
|
127
|
+
# @param string type Data type
|
128
|
+
# @param string value Value to be deserialized
|
129
|
+
# @return [Object] Deserialized data
|
130
|
+
def _deserialize(type, value)
|
131
|
+
case type.to_sym
|
132
|
+
when :DateTime
|
133
|
+
DateTime.parse(value)
|
134
|
+
when :Date
|
135
|
+
Date.parse(value)
|
136
|
+
when :String
|
137
|
+
value.to_s
|
138
|
+
when :Integer
|
139
|
+
value.to_i
|
140
|
+
when :Float
|
141
|
+
value.to_f
|
142
|
+
when :BOOLEAN
|
143
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
144
|
+
true
|
145
|
+
else
|
146
|
+
false
|
147
|
+
end
|
148
|
+
when :Object
|
149
|
+
# generic object (usually a Hash), return directly
|
150
|
+
value
|
151
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
152
|
+
inner_type = Regexp.last_match[:inner_type]
|
153
|
+
value.map { |v| _deserialize(inner_type, v) }
|
154
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
155
|
+
k_type = Regexp.last_match[:k_type]
|
156
|
+
v_type = Regexp.last_match[:v_type]
|
157
|
+
{}.tap do |hash|
|
158
|
+
value.each do |k, v|
|
159
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
160
|
+
end
|
161
|
+
end
|
162
|
+
else # model
|
163
|
+
temp_model = SwaggerClient.const_get(type).new
|
164
|
+
temp_model.build_from_hash(value)
|
165
|
+
end
|
166
|
+
end
|
167
|
+
|
168
|
+
# Returns the string representation of the object
|
169
|
+
# @return [String] String presentation of the object
|
170
|
+
def to_s
|
171
|
+
to_hash.to_s
|
172
|
+
end
|
173
|
+
|
174
|
+
# to_body is an alias to to_hash (backward compatibility)
|
175
|
+
# @return [Hash] Returns the object in the form of hash
|
176
|
+
def to_body
|
177
|
+
to_hash
|
178
|
+
end
|
179
|
+
|
180
|
+
# Returns the object in the form of hash
|
181
|
+
# @return [Hash] Returns the object in the form of hash
|
182
|
+
def to_hash
|
183
|
+
hash = {}
|
184
|
+
self.class.attribute_map.each_pair do |attr, param|
|
185
|
+
value = send(attr)
|
186
|
+
next if value.nil?
|
187
|
+
|
188
|
+
hash[param] = _to_hash(value)
|
189
|
+
end
|
190
|
+
hash
|
191
|
+
end
|
192
|
+
|
193
|
+
# Outputs non-array value in the form of hash
|
194
|
+
# For object, use to_hash. Otherwise, just return the value
|
195
|
+
# @param [Object] value Any valid value
|
196
|
+
# @return [Hash] Returns the value in the form of hash
|
197
|
+
def _to_hash(value)
|
198
|
+
if value.is_a?(Array)
|
199
|
+
value.compact.map { |v| _to_hash(v) }
|
200
|
+
elsif value.is_a?(Hash)
|
201
|
+
{}.tap do |hash|
|
202
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
203
|
+
end
|
204
|
+
elsif value.respond_to? :to_hash
|
205
|
+
value.to_hash
|
206
|
+
else
|
207
|
+
value
|
208
|
+
end
|
209
|
+
end
|
210
|
+
end
|
211
|
+
end
|
212
|
+
end
|
213
|
+
end
|
data/lib/change_healthcare/professional_claims/swagger_client/models/other_payer_billing_provider.rb
ADDED
@@ -0,0 +1,236 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# #Medical Network Professional Claims v3
|
4
|
+
#
|
5
|
+
# Reference for developers
|
6
|
+
#
|
7
|
+
# OpenAPI spec version: v3
|
8
|
+
#
|
9
|
+
# Generated by: https://github.com/swagger-api/swagger-codegen.git
|
10
|
+
# Swagger Codegen version: 2.4.19
|
11
|
+
#
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module ChangeHealthcare
|
16
|
+
module ProfessionalClaims
|
17
|
+
module SwaggerClient
|
18
|
+
class OtherPayerBillingProvider
|
19
|
+
# Allowed Values are: '1' Person, '2' Non-Person Entity
|
20
|
+
attr_accessor :entity_type_qualifier
|
21
|
+
|
22
|
+
# Allowed Values are: '0B' State License Number, '1G' Provider UPIN Number, 'G2' Provider Commercial Number, 'LU' Location Number
|
23
|
+
attr_accessor :other_payer_billing_provider_identifier
|
24
|
+
|
25
|
+
class EnumAttributeValidator
|
26
|
+
attr_reader :datatype, :allowable_values
|
27
|
+
|
28
|
+
def initialize(datatype, allowable_values)
|
29
|
+
@allowable_values = allowable_values.map do |value|
|
30
|
+
case datatype.to_s
|
31
|
+
when /Integer/i
|
32
|
+
value.to_i
|
33
|
+
when /Float/i
|
34
|
+
value.to_f
|
35
|
+
else
|
36
|
+
value
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
def valid?(value)
|
42
|
+
!value || allowable_values.include?(value)
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
47
|
+
def self.attribute_map
|
48
|
+
{
|
49
|
+
entity_type_qualifier: :entityTypeQualifier,
|
50
|
+
other_payer_billing_provider_identifier: :otherPayerBillingProviderIdentifier
|
51
|
+
}
|
52
|
+
end
|
53
|
+
|
54
|
+
# Attribute type mapping.
|
55
|
+
def self.swagger_types
|
56
|
+
{
|
57
|
+
entity_type_qualifier: :String,
|
58
|
+
other_payer_billing_provider_identifier: :'Array<ReferenceIdentification>'
|
59
|
+
}
|
60
|
+
end
|
61
|
+
|
62
|
+
# Initializes the object
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
64
|
+
def initialize(attributes = {})
|
65
|
+
return unless attributes.is_a?(Hash)
|
66
|
+
|
67
|
+
# convert string to symbol for hash key
|
68
|
+
attributes = attributes.transform_keys(&:to_sym)
|
69
|
+
|
70
|
+
self.entity_type_qualifier = attributes[:entityTypeQualifier] if attributes.key?(:entityTypeQualifier)
|
71
|
+
|
72
|
+
if attributes.key?(:otherPayerBillingProviderIdentifier) && (value = attributes[:otherPayerBillingProviderIdentifier]).is_a?(Array)
|
73
|
+
self.other_payer_billing_provider_identifier = value
|
74
|
+
end
|
75
|
+
end
|
76
|
+
|
77
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
78
|
+
# @return Array for valid properties with the reasons
|
79
|
+
def list_invalid_properties
|
80
|
+
[]
|
81
|
+
end
|
82
|
+
|
83
|
+
# Check to see if the all the properties in the model are valid
|
84
|
+
# @return true if the model is valid
|
85
|
+
def valid?
|
86
|
+
entity_type_qualifier_validator = EnumAttributeValidator.new('String', %w[1 2])
|
87
|
+
return false unless entity_type_qualifier_validator.valid?(@entity_type_qualifier)
|
88
|
+
|
89
|
+
true
|
90
|
+
end
|
91
|
+
|
92
|
+
# Custom attribute writer method checking allowed values (enum).
|
93
|
+
# @param [Object] entity_type_qualifier Object to be assigned
|
94
|
+
def entity_type_qualifier=(entity_type_qualifier)
|
95
|
+
validator = EnumAttributeValidator.new('String', %w[1 2])
|
96
|
+
unless validator.valid?(entity_type_qualifier)
|
97
|
+
raise ArgumentError,
|
98
|
+
%(invalid value for "entity_type_qualifier", must be one of #{validator.allowable_values}.)
|
99
|
+
end
|
100
|
+
|
101
|
+
@entity_type_qualifier = entity_type_qualifier
|
102
|
+
end
|
103
|
+
|
104
|
+
# Checks equality by comparing each attribute.
|
105
|
+
# @param [Object] Object to be compared
|
106
|
+
def ==(other)
|
107
|
+
return true if equal?(other)
|
108
|
+
|
109
|
+
self.class == other.class &&
|
110
|
+
entity_type_qualifier == other.entity_type_qualifier &&
|
111
|
+
other_payer_billing_provider_identifier == other.other_payer_billing_provider_identifier
|
112
|
+
end
|
113
|
+
|
114
|
+
# @see the `==` method
|
115
|
+
# @param [Object] Object to be compared
|
116
|
+
def eql?(other)
|
117
|
+
self == other
|
118
|
+
end
|
119
|
+
|
120
|
+
# Calculates hash code according to all attributes.
|
121
|
+
# @return [Fixnum] Hash code
|
122
|
+
def hash
|
123
|
+
[entity_type_qualifier, other_payer_billing_provider_identifier].hash
|
124
|
+
end
|
125
|
+
|
126
|
+
# Builds the object from hash
|
127
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
128
|
+
# @return [Object] Returns the model itself
|
129
|
+
def build_from_hash(attributes)
|
130
|
+
return nil unless attributes.is_a?(Hash)
|
131
|
+
|
132
|
+
self.class.swagger_types.each_pair do |key, type|
|
133
|
+
if type =~ /\AArray<(.*)>/i
|
134
|
+
# check to ensure the input is an array given that the attribute
|
135
|
+
# is documented as an array but the input is not
|
136
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
137
|
+
send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
|
138
|
+
_deserialize(Regexp.last_match(1), v)
|
139
|
+
end)
|
140
|
+
end
|
141
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
142
|
+
send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
143
|
+
end
|
144
|
+
end
|
145
|
+
|
146
|
+
self
|
147
|
+
end
|
148
|
+
|
149
|
+
# Deserializes the data based on type
|
150
|
+
# @param string type Data type
|
151
|
+
# @param string value Value to be deserialized
|
152
|
+
# @return [Object] Deserialized data
|
153
|
+
def _deserialize(type, value)
|
154
|
+
case type.to_sym
|
155
|
+
when :DateTime
|
156
|
+
DateTime.parse(value)
|
157
|
+
when :Date
|
158
|
+
Date.parse(value)
|
159
|
+
when :String
|
160
|
+
value.to_s
|
161
|
+
when :Integer
|
162
|
+
value.to_i
|
163
|
+
when :Float
|
164
|
+
value.to_f
|
165
|
+
when :BOOLEAN
|
166
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
167
|
+
true
|
168
|
+
else
|
169
|
+
false
|
170
|
+
end
|
171
|
+
when :Object
|
172
|
+
# generic object (usually a Hash), return directly
|
173
|
+
value
|
174
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
175
|
+
inner_type = Regexp.last_match[:inner_type]
|
176
|
+
value.map { |v| _deserialize(inner_type, v) }
|
177
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
178
|
+
k_type = Regexp.last_match[:k_type]
|
179
|
+
v_type = Regexp.last_match[:v_type]
|
180
|
+
{}.tap do |hash|
|
181
|
+
value.each do |k, v|
|
182
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
183
|
+
end
|
184
|
+
end
|
185
|
+
else # model
|
186
|
+
temp_model = SwaggerClient.const_get(type).new
|
187
|
+
temp_model.build_from_hash(value)
|
188
|
+
end
|
189
|
+
end
|
190
|
+
|
191
|
+
# Returns the string representation of the object
|
192
|
+
# @return [String] String presentation of the object
|
193
|
+
def to_s
|
194
|
+
to_hash.to_s
|
195
|
+
end
|
196
|
+
|
197
|
+
# to_body is an alias to to_hash (backward compatibility)
|
198
|
+
# @return [Hash] Returns the object in the form of hash
|
199
|
+
def to_body
|
200
|
+
to_hash
|
201
|
+
end
|
202
|
+
|
203
|
+
# Returns the object in the form of hash
|
204
|
+
# @return [Hash] Returns the object in the form of hash
|
205
|
+
def to_hash
|
206
|
+
hash = {}
|
207
|
+
self.class.attribute_map.each_pair do |attr, param|
|
208
|
+
value = send(attr)
|
209
|
+
next if value.nil?
|
210
|
+
|
211
|
+
hash[param] = _to_hash(value)
|
212
|
+
end
|
213
|
+
hash
|
214
|
+
end
|
215
|
+
|
216
|
+
# Outputs non-array value in the form of hash
|
217
|
+
# For object, use to_hash. Otherwise, just return the value
|
218
|
+
# @param [Object] value Any valid value
|
219
|
+
# @return [Hash] Returns the value in the form of hash
|
220
|
+
def _to_hash(value)
|
221
|
+
if value.is_a?(Array)
|
222
|
+
value.compact.map { |v| _to_hash(v) }
|
223
|
+
elsif value.is_a?(Hash)
|
224
|
+
{}.tap do |hash|
|
225
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
226
|
+
end
|
227
|
+
elsif value.respond_to? :to_hash
|
228
|
+
value.to_hash
|
229
|
+
else
|
230
|
+
value
|
231
|
+
end
|
232
|
+
end
|
233
|
+
end
|
234
|
+
end
|
235
|
+
end
|
236
|
+
end
|
@@ -0,0 +1,285 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# #Medical Network Professional Claims v3
|
4
|
+
#
|
5
|
+
# Reference for developers
|
6
|
+
#
|
7
|
+
# OpenAPI spec version: v3
|
8
|
+
#
|
9
|
+
# Generated by: https://github.com/swagger-api/swagger-codegen.git
|
10
|
+
# Swagger Codegen version: 2.4.19
|
11
|
+
#
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module ChangeHealthcare
|
16
|
+
module ProfessionalClaims
|
17
|
+
module SwaggerClient
|
18
|
+
class OtherPayerName
|
19
|
+
attr_accessor :other_insured_additional_identifier, :other_payer_address,
|
20
|
+
:other_payer_adjudication_or_payment_date, :other_payer_claim_adjustment_indicator, :other_payer_claim_control_number, :other_payer_identifier, :other_payer_organization_name, :other_payer_prior_authorization_number, :other_payer_prior_authorization_or_referral_number
|
21
|
+
|
22
|
+
# Allowed Values are: 'PI' Payor Identification, 'XV' Centers for Medicare and Medicaid Services PlanID
|
23
|
+
attr_accessor :other_payer_identifier_type_code
|
24
|
+
|
25
|
+
# Allowed Values are: '2U' Payer Identification Number, 'EI' Employer’s Identification Number, 'FY' Claim Office Number, 'NF' National Association of Insurance Commissioners (NAIC) Code
|
26
|
+
attr_accessor :other_payer_secondary_identifier
|
27
|
+
|
28
|
+
class EnumAttributeValidator
|
29
|
+
attr_reader :datatype, :allowable_values
|
30
|
+
|
31
|
+
def initialize(datatype, allowable_values)
|
32
|
+
@allowable_values = allowable_values.map do |value|
|
33
|
+
case datatype.to_s
|
34
|
+
when /Integer/i
|
35
|
+
value.to_i
|
36
|
+
when /Float/i
|
37
|
+
value.to_f
|
38
|
+
else
|
39
|
+
value
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
def valid?(value)
|
45
|
+
!value || allowable_values.include?(value)
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
50
|
+
def self.attribute_map
|
51
|
+
{
|
52
|
+
other_insured_additional_identifier: :otherInsuredAdditionalIdentifier,
|
53
|
+
other_payer_address: :otherPayerAddress,
|
54
|
+
other_payer_adjudication_or_payment_date: :otherPayerAdjudicationOrPaymentDate,
|
55
|
+
other_payer_claim_adjustment_indicator: :otherPayerClaimAdjustmentIndicator,
|
56
|
+
other_payer_claim_control_number: :otherPayerClaimControlNumber,
|
57
|
+
other_payer_identifier: :otherPayerIdentifier,
|
58
|
+
other_payer_identifier_type_code: :otherPayerIdentifierTypeCode,
|
59
|
+
other_payer_organization_name: :otherPayerOrganizationName,
|
60
|
+
other_payer_prior_authorization_number: :otherPayerPriorAuthorizationNumber,
|
61
|
+
other_payer_prior_authorization_or_referral_number: :otherPayerPriorAuthorizationOrReferralNumber,
|
62
|
+
other_payer_secondary_identifier: :otherPayerSecondaryIdentifier
|
63
|
+
}
|
64
|
+
end
|
65
|
+
|
66
|
+
# Attribute type mapping.
|
67
|
+
def self.swagger_types
|
68
|
+
{
|
69
|
+
other_insured_additional_identifier: :String,
|
70
|
+
other_payer_address: :Address,
|
71
|
+
other_payer_adjudication_or_payment_date: :String,
|
72
|
+
other_payer_claim_adjustment_indicator: :BOOLEAN,
|
73
|
+
other_payer_claim_control_number: :String,
|
74
|
+
other_payer_identifier: :String,
|
75
|
+
other_payer_identifier_type_code: :String,
|
76
|
+
other_payer_organization_name: :String,
|
77
|
+
other_payer_prior_authorization_number: :String,
|
78
|
+
other_payer_prior_authorization_or_referral_number: :String,
|
79
|
+
other_payer_secondary_identifier: :'Array<ReferenceIdentification>'
|
80
|
+
}
|
81
|
+
end
|
82
|
+
|
83
|
+
# Initializes the object
|
84
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
85
|
+
def initialize(attributes = {})
|
86
|
+
return unless attributes.is_a?(Hash)
|
87
|
+
|
88
|
+
# convert string to symbol for hash key
|
89
|
+
attributes = attributes.transform_keys(&:to_sym)
|
90
|
+
|
91
|
+
self.other_insured_additional_identifier = attributes[:otherInsuredAdditionalIdentifier] if attributes.key?(:otherInsuredAdditionalIdentifier)
|
92
|
+
|
93
|
+
self.other_payer_address = attributes[:otherPayerAddress] if attributes.key?(:otherPayerAddress)
|
94
|
+
|
95
|
+
self.other_payer_adjudication_or_payment_date = attributes[:otherPayerAdjudicationOrPaymentDate] if attributes.key?(:otherPayerAdjudicationOrPaymentDate)
|
96
|
+
|
97
|
+
self.other_payer_claim_adjustment_indicator = attributes[:otherPayerClaimAdjustmentIndicator] if attributes.key?(:otherPayerClaimAdjustmentIndicator)
|
98
|
+
|
99
|
+
self.other_payer_claim_control_number = attributes[:otherPayerClaimControlNumber] if attributes.key?(:otherPayerClaimControlNumber)
|
100
|
+
|
101
|
+
self.other_payer_identifier = attributes[:otherPayerIdentifier] if attributes.key?(:otherPayerIdentifier)
|
102
|
+
|
103
|
+
self.other_payer_identifier_type_code = attributes[:otherPayerIdentifierTypeCode] if attributes.key?(:otherPayerIdentifierTypeCode)
|
104
|
+
|
105
|
+
self.other_payer_organization_name = attributes[:otherPayerOrganizationName] if attributes.key?(:otherPayerOrganizationName)
|
106
|
+
|
107
|
+
self.other_payer_prior_authorization_number = attributes[:otherPayerPriorAuthorizationNumber] if attributes.key?(:otherPayerPriorAuthorizationNumber)
|
108
|
+
|
109
|
+
self.other_payer_prior_authorization_or_referral_number = attributes[:otherPayerPriorAuthorizationOrReferralNumber] if attributes.key?(:otherPayerPriorAuthorizationOrReferralNumber)
|
110
|
+
|
111
|
+
if attributes.key?(:otherPayerSecondaryIdentifier) && (value = attributes[:otherPayerSecondaryIdentifier]).is_a?(Array)
|
112
|
+
self.other_payer_secondary_identifier = value
|
113
|
+
end
|
114
|
+
end
|
115
|
+
|
116
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
117
|
+
# @return Array for valid properties with the reasons
|
118
|
+
def list_invalid_properties
|
119
|
+
[]
|
120
|
+
end
|
121
|
+
|
122
|
+
# Check to see if the all the properties in the model are valid
|
123
|
+
# @return true if the model is valid
|
124
|
+
def valid?
|
125
|
+
other_payer_identifier_type_code_validator = EnumAttributeValidator.new('String', %w[PI XV])
|
126
|
+
return false unless other_payer_identifier_type_code_validator.valid?(@other_payer_identifier_type_code)
|
127
|
+
|
128
|
+
true
|
129
|
+
end
|
130
|
+
|
131
|
+
# Custom attribute writer method checking allowed values (enum).
|
132
|
+
# @param [Object] other_payer_identifier_type_code Object to be assigned
|
133
|
+
def other_payer_identifier_type_code=(other_payer_identifier_type_code)
|
134
|
+
validator = EnumAttributeValidator.new('String', %w[PI XV])
|
135
|
+
unless validator.valid?(other_payer_identifier_type_code)
|
136
|
+
raise ArgumentError,
|
137
|
+
%(invalid value for "other_payer_identifier_type_code", must be one of #{validator.allowable_values}.)
|
138
|
+
end
|
139
|
+
|
140
|
+
@other_payer_identifier_type_code = other_payer_identifier_type_code
|
141
|
+
end
|
142
|
+
|
143
|
+
# Checks equality by comparing each attribute.
|
144
|
+
# @param [Object] Object to be compared
|
145
|
+
def ==(other)
|
146
|
+
return true if equal?(other)
|
147
|
+
|
148
|
+
self.class == other.class &&
|
149
|
+
other_insured_additional_identifier == other.other_insured_additional_identifier &&
|
150
|
+
other_payer_address == other.other_payer_address &&
|
151
|
+
other_payer_adjudication_or_payment_date == other.other_payer_adjudication_or_payment_date &&
|
152
|
+
other_payer_claim_adjustment_indicator == other.other_payer_claim_adjustment_indicator &&
|
153
|
+
other_payer_claim_control_number == other.other_payer_claim_control_number &&
|
154
|
+
other_payer_identifier == other.other_payer_identifier &&
|
155
|
+
other_payer_identifier_type_code == other.other_payer_identifier_type_code &&
|
156
|
+
other_payer_organization_name == other.other_payer_organization_name &&
|
157
|
+
other_payer_prior_authorization_number == other.other_payer_prior_authorization_number &&
|
158
|
+
other_payer_prior_authorization_or_referral_number == other.other_payer_prior_authorization_or_referral_number &&
|
159
|
+
other_payer_secondary_identifier == other.other_payer_secondary_identifier
|
160
|
+
end
|
161
|
+
|
162
|
+
# @see the `==` method
|
163
|
+
# @param [Object] Object to be compared
|
164
|
+
def eql?(other)
|
165
|
+
self == other
|
166
|
+
end
|
167
|
+
|
168
|
+
# Calculates hash code according to all attributes.
|
169
|
+
# @return [Fixnum] Hash code
|
170
|
+
def hash
|
171
|
+
[other_insured_additional_identifier, other_payer_address, other_payer_adjudication_or_payment_date,
|
172
|
+
other_payer_claim_adjustment_indicator, other_payer_claim_control_number, other_payer_identifier, other_payer_identifier_type_code, other_payer_organization_name, other_payer_prior_authorization_number, other_payer_prior_authorization_or_referral_number, other_payer_secondary_identifier].hash
|
173
|
+
end
|
174
|
+
|
175
|
+
# Builds the object from hash
|
176
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
177
|
+
# @return [Object] Returns the model itself
|
178
|
+
def build_from_hash(attributes)
|
179
|
+
return nil unless attributes.is_a?(Hash)
|
180
|
+
|
181
|
+
self.class.swagger_types.each_pair do |key, type|
|
182
|
+
if type =~ /\AArray<(.*)>/i
|
183
|
+
# check to ensure the input is an array given that the attribute
|
184
|
+
# is documented as an array but the input is not
|
185
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
186
|
+
send("#{key}=", attributes[self.class.attribute_map[key]].map do |v|
|
187
|
+
_deserialize(Regexp.last_match(1), v)
|
188
|
+
end)
|
189
|
+
end
|
190
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
191
|
+
send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
self
|
196
|
+
end
|
197
|
+
|
198
|
+
# Deserializes the data based on type
|
199
|
+
# @param string type Data type
|
200
|
+
# @param string value Value to be deserialized
|
201
|
+
# @return [Object] Deserialized data
|
202
|
+
def _deserialize(type, value)
|
203
|
+
case type.to_sym
|
204
|
+
when :DateTime
|
205
|
+
DateTime.parse(value)
|
206
|
+
when :Date
|
207
|
+
Date.parse(value)
|
208
|
+
when :String
|
209
|
+
value.to_s
|
210
|
+
when :Integer
|
211
|
+
value.to_i
|
212
|
+
when :Float
|
213
|
+
value.to_f
|
214
|
+
when :BOOLEAN
|
215
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
216
|
+
true
|
217
|
+
else
|
218
|
+
false
|
219
|
+
end
|
220
|
+
when :Object
|
221
|
+
# generic object (usually a Hash), return directly
|
222
|
+
value
|
223
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
224
|
+
inner_type = Regexp.last_match[:inner_type]
|
225
|
+
value.map { |v| _deserialize(inner_type, v) }
|
226
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
227
|
+
k_type = Regexp.last_match[:k_type]
|
228
|
+
v_type = Regexp.last_match[:v_type]
|
229
|
+
{}.tap do |hash|
|
230
|
+
value.each do |k, v|
|
231
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
232
|
+
end
|
233
|
+
end
|
234
|
+
else # model
|
235
|
+
temp_model = SwaggerClient.const_get(type).new
|
236
|
+
temp_model.build_from_hash(value)
|
237
|
+
end
|
238
|
+
end
|
239
|
+
|
240
|
+
# Returns the string representation of the object
|
241
|
+
# @return [String] String presentation of the object
|
242
|
+
def to_s
|
243
|
+
to_hash.to_s
|
244
|
+
end
|
245
|
+
|
246
|
+
# to_body is an alias to to_hash (backward compatibility)
|
247
|
+
# @return [Hash] Returns the object in the form of hash
|
248
|
+
def to_body
|
249
|
+
to_hash
|
250
|
+
end
|
251
|
+
|
252
|
+
# Returns the object in the form of hash
|
253
|
+
# @return [Hash] Returns the object in the form of hash
|
254
|
+
def to_hash
|
255
|
+
hash = {}
|
256
|
+
self.class.attribute_map.each_pair do |attr, param|
|
257
|
+
value = send(attr)
|
258
|
+
next if value.nil?
|
259
|
+
|
260
|
+
hash[param] = _to_hash(value)
|
261
|
+
end
|
262
|
+
hash
|
263
|
+
end
|
264
|
+
|
265
|
+
# Outputs non-array value in the form of hash
|
266
|
+
# For object, use to_hash. Otherwise, just return the value
|
267
|
+
# @param [Object] value Any valid value
|
268
|
+
# @return [Hash] Returns the value in the form of hash
|
269
|
+
def _to_hash(value)
|
270
|
+
if value.is_a?(Array)
|
271
|
+
value.compact.map { |v| _to_hash(v) }
|
272
|
+
elsif value.is_a?(Hash)
|
273
|
+
{}.tap do |hash|
|
274
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
275
|
+
end
|
276
|
+
elsif value.respond_to? :to_hash
|
277
|
+
value.to_hash
|
278
|
+
else
|
279
|
+
value
|
280
|
+
end
|
281
|
+
end
|
282
|
+
end
|
283
|
+
end
|
284
|
+
end
|
285
|
+
end
|