class Pinnacle::AdditionalPhoneNumber

def self.from_json(json_object:)

Returns:
  • (Pinnacle::AdditionalPhoneNumber) -

Parameters:
  • json_object (String) --
def self.from_json(json_object:)
  struct = JSON.parse(json_object, object_class: OpenStruct)
  parsed_json = JSON.parse(json_object)
  phone = parsed_json["phone"]
  label = parsed_json["label"]
  new(
    phone: phone,
    label: label,
    additional_properties: struct
  )
end

def self.validate_raw(obj:)

Returns:
  • (Void) -

Parameters:
  • obj (Object) --
def self.validate_raw(obj:)
  obj.phone.is_a?(String) != false || raise("Passed value for field obj.phone is not the expected type, validation failed.")
  obj.label.is_a?(String) != false || raise("Passed value for field obj.label is not the expected type, validation failed.")
end

def initialize(phone:, label:, additional_properties: nil)

Returns:
  • (Pinnacle::AdditionalPhoneNumber) -

Parameters:
  • additional_properties (OpenStruct) -- Additional properties unmapped to the current class definition
  • label (String) -- Label for the additional phone number.
  • phone (String) -- Additional phone number in international format.
def initialize(phone:, label:, additional_properties: nil)
  @phone = phone
  @label = label
  @additional_properties = additional_properties
  @_field_set = { "phone": phone, "label": label }
end

def to_json(*_args)

Returns:
  • (String) -
def to_json(*_args)
  @_field_set&.to_json
end