Class: Pinnacle::Company::CompanyRegisterResponse
- Inherits:
 - 
      Object
      
        
- Object
 - Pinnacle::Company::CompanyRegisterResponse
 
 
- Defined in:
 - lib/rcs/company/types/company_register_response.rb
 
Constant Summary collapse
- OMIT =
 Object.new
Instance Attribute Summary collapse
- 
  
    
      #additional_properties  ⇒ OpenStruct 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
Additional properties unmapped to the current class definition.
 - #brand ⇒ Pinnacle::Company::CompanyRegisterResponseBrand readonly
 
Class Method Summary collapse
- 
  
    
      .from_json(json_object:)  ⇒ Pinnacle::Company::CompanyRegisterResponse 
    
    
  
  
  
  
  
  
  
  
  
    
Deserialize a JSON object to an instance of CompanyRegisterResponse.
 - 
  
    
      .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(brand:, additional_properties: nil) ⇒ Pinnacle::Company::CompanyRegisterResponse constructor
 - 
  
    
      #to_json(*_args)  ⇒ String 
    
    
  
  
  
  
  
  
  
  
  
    
Serialize an instance of CompanyRegisterResponse to a JSON object.
 
Constructor Details
#initialize(brand:, additional_properties: nil) ⇒ Pinnacle::Company::CompanyRegisterResponse
      23 24 25 26 27  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 23 def initialize(brand:, additional_properties: nil) @brand = brand @additional_properties = additional_properties @_field_set = { "brand": brand } end  | 
  
Instance Attribute Details
#additional_properties ⇒ OpenStruct (readonly)
Returns Additional properties unmapped to the current class definition.
      13 14 15  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 13 def additional_properties @additional_properties end  | 
  
#brand ⇒ Pinnacle::Company::CompanyRegisterResponseBrand (readonly)
      11 12 13  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 11 def brand @brand end  | 
  
Class Method Details
.from_json(json_object:) ⇒ Pinnacle::Company::CompanyRegisterResponse
Deserialize a JSON object to an instance of CompanyRegisterResponse
      33 34 35 36 37 38 39 40 41 42 43  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 33 def self.from_json(json_object:) struct = JSON.parse(json_object, object_class: OpenStruct) parsed_json = JSON.parse(json_object) if parsed_json["brand"].nil? brand = nil else brand = parsed_json["brand"].to_json brand = Pinnacle::Company::CompanyRegisterResponseBrand.from_json(json_object: brand) end new(brand: brand, 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.
  
      58 59 60  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 58 def self.validate_raw(obj:) Pinnacle::Company::CompanyRegisterResponseBrand.validate_raw(obj: obj.brand) end  | 
  
Instance Method Details
#to_json(*_args) ⇒ String
Serialize an instance of CompanyRegisterResponse to a JSON object
      48 49 50  | 
    
      # File 'lib/rcs/company/types/company_register_response.rb', line 48 def to_json(*_args) @_field_set&.to_json end  |