Method: PhoneComClient::ListCallerIds#initialize

Defined in:
lib/phone_com_client/models/list_caller_ids.rb

#initialize(attributes = {}) ⇒ ListCallerIds

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash



55
56
57
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
# File 'lib/phone_com_client/models/list_caller_ids.rb', line 55

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  if attributes.has_key?(:'filters')
    self.filters = attributes[:'filters']
  end

  if attributes.has_key?(:'sort')
    self.sort = attributes[:'sort']
  end

  if attributes.has_key?(:'total')
    self.total = attributes[:'total']
  end

  if attributes.has_key?(:'offset')
    self.offset = attributes[:'offset']
  end

  if attributes.has_key?(:'limit')
    self.limit = attributes[:'limit']
  end

  if attributes.has_key?(:'items')
    if (value = attributes[:'items']).is_a?(Array)
      self.items = value
    end
  end
end