Class: CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder
- Inherits:
-
Object
- Object
- CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder
- Defined in:
- lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb
Overview
The patient’s active coverages, in order of primary, secondary, etc.
Constant Summary collapse
- OMIT =
Object.new
Instance Attribute Summary collapse
-
#additional_properties ⇒ OpenStruct
readonly
Additional properties unmapped to the current class definition.
- #coverages ⇒ Array<String> readonly
Class Method Summary collapse
-
.from_json(json_object:) ⇒ CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder
Deserialize a JSON object to an instance of FilingOrder.
-
.validate_raw(obj:) ⇒ Void
Leveraged for Union-type generation, validate_raw attempts to parse the given hash and check each fields type against the current object’s property definitions.
Instance Method Summary collapse
- #initialize(coverages:, additional_properties: nil) ⇒ CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder constructor
-
#to_json(*_args) ⇒ String
Serialize an instance of FilingOrder to a JSON object.
Constructor Details
#initialize(coverages:, additional_properties: nil) ⇒ CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder
26 27 28 29 30 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 26 def initialize(coverages:, additional_properties: nil) @coverages = coverages @additional_properties = additional_properties @_field_set = { "coverages": coverages } end |
Instance Attribute Details
#additional_properties ⇒ OpenStruct (readonly)
Returns Additional properties unmapped to the current class definition.
16 17 18 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 16 def additional_properties @additional_properties end |
#coverages ⇒ Array<String> (readonly)
14 15 16 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 14 def coverages @coverages end |
Class Method Details
.from_json(json_object:) ⇒ CandidApiClient::PreEncounter::Patients::V1::Types::FilingOrder
Deserialize a JSON object to an instance of FilingOrder
36 37 38 39 40 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 36 def self.from_json(json_object:) struct = JSON.parse(json_object, object_class: OpenStruct) coverages = struct["coverages"] new(coverages: coverages, additional_properties: struct) end |
.validate_raw(obj:) ⇒ Void
Leveraged for Union-type generation, validate_raw attempts to parse the given
hash and check each fields type against the current object's property
definitions.
55 56 57 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 55 def self.validate_raw(obj:) obj.coverages.is_a?(Array) != false || raise("Passed value for field obj.coverages is not the expected type, validation failed.") end |
Instance Method Details
#to_json(*_args) ⇒ String
Serialize an instance of FilingOrder to a JSON object
45 46 47 |
# File 'lib/candidhealth/pre_encounter/patients/v_1/types/filing_order.rb', line 45 def to_json(*_args) @_field_set&.to_json end |