UsageResource.php 661 B

1234567891011121314151617181920
  1. <?php
  2. /**
  3. * Parent class for all UsageRecord subclasses
  4. * @author Kevin Burke <kevin@twilio.com>
  5. * @license http://creativecommons.org/licenses/MIT/ MIT
  6. * @link http://pear.php.net/package/Services_Twilio
  7. */
  8. class Services_Twilio_UsageResource extends Services_Twilio_ListResource {
  9. public function getResourceName($camelized = false) {
  10. $this->instance_name = 'Services_Twilio_Rest_UsageRecord';
  11. return $camelized ? 'UsageRecords' : 'usage_records';
  12. }
  13. public function __construct($client, $uri) {
  14. $uri = preg_replace("#UsageRecords#", "Usage/Records", $uri);
  15. parent::__construct($client, $uri);
  16. }
  17. }