Class: ChangeHealthcare::Eligibility::SwaggerClient::BenefitsDateInformation
- Inherits:
-
Object
- Object
- ChangeHealthcare::Eligibility::SwaggerClient::BenefitsDateInformation
- Defined in:
- lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb
Instance Attribute Summary collapse
-
#added ⇒ Object
Returns the value of attribute added.
-
#admission ⇒ Object
Returns the value of attribute admission.
-
#benefit ⇒ Object
Returns the value of attribute benefit.
-
#benefit_begin ⇒ Object
Returns the value of attribute benefit_begin.
-
#benefit_end ⇒ Object
Returns the value of attribute benefit_end.
-
#certification ⇒ Object
Returns the value of attribute certification.
-
#cobra_begin ⇒ Object
Returns the value of attribute cobra_begin.
-
#cobra_end ⇒ Object
Returns the value of attribute cobra_end.
-
#completion ⇒ Object
Returns the value of attribute completion.
-
#coordination_of_benefits ⇒ Object
Returns the value of attribute coordination_of_benefits.
-
#date_of_death ⇒ Object
Returns the value of attribute date_of_death.
-
#date_of_last_update ⇒ Object
Returns the value of attribute date_of_last_update.
-
#discharge ⇒ Object
Returns the value of attribute discharge.
-
#effective_date_of_change ⇒ Object
Returns the value of attribute effective_date_of_change.
-
#eligibility ⇒ Object
Returns the value of attribute eligibility.
-
#eligibility_begin ⇒ Object
Returns the value of attribute eligibility_begin.
-
#eligibility_end ⇒ Object
Returns the value of attribute eligibility_end.
-
#enrollment ⇒ Object
Returns the value of attribute enrollment.
-
#issue ⇒ Object
Returns the value of attribute issue.
-
#latest_visit_or_consultation ⇒ Object
Returns the value of attribute latest_visit_or_consultation.
-
#period_end ⇒ Object
Returns the value of attribute period_end.
-
#period_start ⇒ Object
Returns the value of attribute period_start.
-
#plan ⇒ Object
Returns the value of attribute plan.
-
#plan_begin ⇒ Object
Returns the value of attribute plan_begin.
-
#plan_end ⇒ Object
Returns the value of attribute plan_end.
-
#policy_effective ⇒ Object
Returns the value of attribute policy_effective.
-
#policy_expiration ⇒ Object
Returns the value of attribute policy_expiration.
-
#premium_paid_to_date_end ⇒ Object
Returns the value of attribute premium_paid_to_date_end.
-
#premium_paidto_date_begin ⇒ Object
Returns the value of attribute premium_paidto_date_begin.
-
#primary_care_provider ⇒ Object
Returns the value of attribute primary_care_provider.
-
#service ⇒ Object
Returns the value of attribute service.
-
#status ⇒ Object
Returns the value of attribute status.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
-
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ BenefitsDateInformation
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ BenefitsDateInformation
Initializes the object
97 98 99 100 101 102 103 104 105 106 107 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 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 97 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.transform_keys(&:to_sym) self.added = attributes[:added] if attributes.key?(:added) self.admission = attributes[:admission] if attributes.key?(:admission) self.benefit = attributes[:benefit] if attributes.key?(:benefit) self.benefit_begin = attributes[:benefitBegin] if attributes.key?(:benefitBegin) self.benefit_end = attributes[:benefitEnd] if attributes.key?(:benefitEnd) self.certification = attributes[:certification] if attributes.key?(:certification) self.cobra_begin = attributes[:cobraBegin] if attributes.key?(:cobraBegin) self.cobra_end = attributes[:cobraEnd] if attributes.key?(:cobraEnd) self.completion = attributes[:completion] if attributes.key?(:completion) self.coordination_of_benefits = attributes[:coordinationOfBenefits] if attributes.key?(:coordinationOfBenefits) self.date_of_death = attributes[:dateOfDeath] if attributes.key?(:dateOfDeath) self.date_of_last_update = attributes[:dateOfLastUpdate] if attributes.key?(:dateOfLastUpdate) self.discharge = attributes[:discharge] if attributes.key?(:discharge) self.effective_date_of_change = attributes[:effectiveDateOfChange] if attributes.key?(:effectiveDateOfChange) self.eligibility = attributes[:eligibility] if attributes.key?(:eligibility) self.eligibility_begin = attributes[:eligibilityBegin] if attributes.key?(:eligibilityBegin) self.eligibility_end = attributes[:eligibilityEnd] if attributes.key?(:eligibilityEnd) self.enrollment = attributes[:enrollment] if attributes.key?(:enrollment) self.issue = attributes[:issue] if attributes.key?(:issue) self.latest_visit_or_consultation = attributes[:latestVisitOrConsultation] if attributes.key?(:latestVisitOrConsultation) self.period_end = attributes[:periodEnd] if attributes.key?(:periodEnd) self.period_start = attributes[:periodStart] if attributes.key?(:periodStart) self.plan = attributes[:plan] if attributes.key?(:plan) self.plan_begin = attributes[:planBegin] if attributes.key?(:planBegin) self.plan_end = attributes[:planEnd] if attributes.key?(:planEnd) self.policy_effective = attributes[:policyEffective] if attributes.key?(:policyEffective) self.policy_expiration = attributes[:policyExpiration] if attributes.key?(:policyExpiration) self.premium_paid_to_date_end = attributes[:premiumPaidToDateEnd] if attributes.key?(:premiumPaidToDateEnd) self.premium_paidto_date_begin = attributes[:premiumPaidtoDateBegin] if attributes.key?(:premiumPaidtoDateBegin) self.primary_care_provider = attributes[:primaryCareProvider] if attributes.key?(:primaryCareProvider) self.service = attributes[:service] if attributes.key?(:service) self.status = attributes[:status] if attributes.key?(:status) end |
Instance Attribute Details
#added ⇒ Object
Returns the value of attribute added.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def added @added end |
#admission ⇒ Object
Returns the value of attribute admission.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def admission @admission end |
#benefit ⇒ Object
Returns the value of attribute benefit.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def benefit @benefit end |
#benefit_begin ⇒ Object
Returns the value of attribute benefit_begin.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def benefit_begin @benefit_begin end |
#benefit_end ⇒ Object
Returns the value of attribute benefit_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def benefit_end @benefit_end end |
#certification ⇒ Object
Returns the value of attribute certification.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def certification @certification end |
#cobra_begin ⇒ Object
Returns the value of attribute cobra_begin.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def cobra_begin @cobra_begin end |
#cobra_end ⇒ Object
Returns the value of attribute cobra_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def cobra_end @cobra_end end |
#completion ⇒ Object
Returns the value of attribute completion.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def completion @completion end |
#coordination_of_benefits ⇒ Object
Returns the value of attribute coordination_of_benefits.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def coordination_of_benefits @coordination_of_benefits end |
#date_of_death ⇒ Object
Returns the value of attribute date_of_death.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def date_of_death @date_of_death end |
#date_of_last_update ⇒ Object
Returns the value of attribute date_of_last_update.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def date_of_last_update @date_of_last_update end |
#discharge ⇒ Object
Returns the value of attribute discharge.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def discharge @discharge end |
#effective_date_of_change ⇒ Object
Returns the value of attribute effective_date_of_change.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def effective_date_of_change @effective_date_of_change end |
#eligibility ⇒ Object
Returns the value of attribute eligibility.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def eligibility @eligibility end |
#eligibility_begin ⇒ Object
Returns the value of attribute eligibility_begin.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def eligibility_begin @eligibility_begin end |
#eligibility_end ⇒ Object
Returns the value of attribute eligibility_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def eligibility_end @eligibility_end end |
#enrollment ⇒ Object
Returns the value of attribute enrollment.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def enrollment @enrollment end |
#issue ⇒ Object
Returns the value of attribute issue.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def issue @issue end |
#latest_visit_or_consultation ⇒ Object
Returns the value of attribute latest_visit_or_consultation.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def latest_visit_or_consultation @latest_visit_or_consultation end |
#period_end ⇒ Object
Returns the value of attribute period_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def period_end @period_end end |
#period_start ⇒ Object
Returns the value of attribute period_start.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def period_start @period_start end |
#plan ⇒ Object
Returns the value of attribute plan.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def plan @plan end |
#plan_begin ⇒ Object
Returns the value of attribute plan_begin.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def plan_begin @plan_begin end |
#plan_end ⇒ Object
Returns the value of attribute plan_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def plan_end @plan_end end |
#policy_effective ⇒ Object
Returns the value of attribute policy_effective.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def policy_effective @policy_effective end |
#policy_expiration ⇒ Object
Returns the value of attribute policy_expiration.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def policy_expiration @policy_expiration end |
#premium_paid_to_date_end ⇒ Object
Returns the value of attribute premium_paid_to_date_end.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def premium_paid_to_date_end @premium_paid_to_date_end end |
#premium_paidto_date_begin ⇒ Object
Returns the value of attribute premium_paidto_date_begin.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def premium_paidto_date_begin @premium_paidto_date_begin end |
#primary_care_provider ⇒ Object
Returns the value of attribute primary_care_provider.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def primary_care_provider @primary_care_provider end |
#service ⇒ Object
Returns the value of attribute service.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def service @service end |
#status ⇒ Object
Returns the value of attribute status.
17 18 19 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 17 def status @status end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 20 def self.attribute_map { 'added': :added, 'admission': :admission, 'benefit': :benefit, 'benefit_begin': :benefitBegin, 'benefit_end': :benefitEnd, 'certification': :certification, 'cobra_begin': :cobraBegin, 'cobra_end': :cobraEnd, 'completion': :completion, 'coordination_of_benefits': :coordinationOfBenefits, 'date_of_death': :dateOfDeath, 'date_of_last_update': :dateOfLastUpdate, 'discharge': :discharge, 'effective_date_of_change': :effectiveDateOfChange, 'eligibility': :eligibility, 'eligibility_begin': :eligibilityBegin, 'eligibility_end': :eligibilityEnd, 'enrollment': :enrollment, 'issue': :issue, 'latest_visit_or_consultation': :latestVisitOrConsultation, 'period_end': :periodEnd, 'period_start': :periodStart, 'plan': :plan, 'plan_begin': :planBegin, 'plan_end': :planEnd, 'policy_effective': :policyEffective, 'policy_expiration': :policyExpiration, 'premium_paid_to_date_end': :premiumPaidToDateEnd, 'premium_paidto_date_begin': :premiumPaidtoDateBegin, 'primary_care_provider': :primaryCareProvider, 'service': :service, 'status': :status } end |
.swagger_types ⇒ Object
Attribute type mapping.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 58 def self.swagger_types { 'added': :String, 'admission': :String, 'benefit': :String, 'benefit_begin': :String, 'benefit_end': :String, 'certification': :String, 'cobra_begin': :String, 'cobra_end': :String, 'completion': :String, 'coordination_of_benefits': :String, 'date_of_death': :String, 'date_of_last_update': :String, 'discharge': :String, 'effective_date_of_change': :String, 'eligibility': :String, 'eligibility_begin': :String, 'eligibility_end': :String, 'enrollment': :String, 'issue': :String, 'latest_visit_or_consultation': :String, 'period_end': :String, 'period_start': :String, 'plan': :String, 'plan_begin': :String, 'plan_end': :String, 'policy_effective': :String, 'policy_expiration': :String, 'premium_paid_to_date_end': :String, 'premium_paidto_date_begin': :String, 'primary_care_provider': :String, 'service': :String, 'status': :String } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 182 def ==(o) return true if equal?(o) self.class == o.class && added == o.added && admission == o.admission && benefit == o.benefit && benefit_begin == o.benefit_begin && benefit_end == o.benefit_end && certification == o.certification && cobra_begin == o.cobra_begin && cobra_end == o.cobra_end && completion == o.completion && coordination_of_benefits == o.coordination_of_benefits && date_of_death == o.date_of_death && date_of_last_update == o.date_of_last_update && discharge == o.discharge && effective_date_of_change == o.effective_date_of_change && eligibility == o.eligibility && eligibility_begin == o.eligibility_begin && eligibility_end == o.eligibility_end && enrollment == o.enrollment && issue == o.issue && latest_visit_or_consultation == o.latest_visit_or_consultation && period_end == o.period_end && period_start == o.period_start && plan == o.plan && plan_begin == o.plan_begin && plan_end == o.plan_end && policy_effective == o.policy_effective && policy_expiration == o.policy_expiration && premium_paid_to_date_end == o.premium_paid_to_date_end && premium_paidto_date_begin == o.premium_paidto_date_begin && primary_care_provider == o.primary_care_provider && service == o.service && status == o.status end |
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type
257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 257 def _deserialize(type, value) case type.to_sym when :DateTime DateTime.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :BOOLEAN if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model temp_model = SwaggerClient.const_get(type).new temp_model.build_from_hash(value) end end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
324 325 326 327 328 329 330 331 332 333 334 335 336 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 324 def _to_hash(value) if value.is_a?(Array) value.compact.map { |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 235 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize(Regexp.last_match(1), v) }) end elsif !attributes[self.class.attribute_map[key]].nil? send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(o) ⇒ Boolean
222 223 224 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 222 def eql?(o) self == o end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
228 229 230 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 228 def hash [added, admission, benefit, benefit_begin, benefit_end, certification, cobra_begin, cobra_end, completion, coordination_of_benefits, date_of_death, date_of_last_update, discharge, effective_date_of_change, eligibility, eligibility_begin, eligibility_end, enrollment, issue, latest_visit_or_consultation, period_end, period_start, plan, plan_begin, plan_end, policy_effective, policy_expiration, premium_paid_to_date_end, premium_paidto_date_begin, primary_care_provider, service, status].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
170 171 172 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 170 def list_invalid_properties [] end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
303 304 305 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 303 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
309 310 311 312 313 314 315 316 317 318 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 309 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = send(attr) next if value.nil? hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
297 298 299 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 297 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
176 177 178 |
# File 'lib/change_healthcare/eligibility/swagger_client/models/benefits_date_information.rb', line 176 def valid? true end |