# This file was automatically generated by APIMATIC v2.0 on 06/23/2016

require 'magic_telecom_api/models/item'

module MagicTelecomApi
  class TrunkItem < Item 
    # TODO: Write general description for this method
    # @return [Numeric]
    attr_accessor :channels

    # TODO: Write general description for this method
    # @return [String]
    attr_accessor :trunk_handle

    # TODO: Write general description for this method
    # @return [String]
    attr_accessor :sip_uri

    # TODO: Write general description for this method
    # @return [String]
    attr_accessor :attributes

    # TODO: Write general description for this method
    # @return [Routing]
    attr_accessor :routing

    def method_missing(method_name)
      puts "there's no method called '#{method_name}'"
    end

    # Creates JSON of the curent object
    def to_json
      hash = key_map
      hash.to_json
    end

    # Defines the key map for json serialization
    def key_map
      hash = {}
      hash['channels'] = channels
      hash['trunk_handle'] = trunk_handle
      hash['sip_uri'] = sip_uri
      hash['attributes'] = attributes
      hash['_routing'] = routing
      hash = super().merge(hash) 
      hash
    end
  end
end
