Sha256: 1838e4ee85a8887e664e79963173db460227f5640cc16be2f66f6b6a4f4382c0
Contents?: true
Size: 751 Bytes
Versions: 25
Compression:
Stored size: 751 Bytes
Contents
module Twilio module REST module TaskRouter module Statistics def statistics(args={}) path = "#{@path}/Statistics" response = @client.get(path, args) statistics_class.new(path, @client, response) end private ## # Gets the class for the statistics of the current class. # Should just be Object.const_get("#{self.class.to_s}Statistics") but # Ruby 1.9.3 did not agree. Can be updated if support is dropped. def statistics_class current_class = self.class.to_s.split('::').last statistics_class = Twilio::REST::TaskRouter.const_get( "#{current_class}Statistics" ) end end end end end
Version data entries
25 entries across 25 versions & 1 rubygems