AuthorizationAdjustment.php 829 B

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. namespace Braintree;
  3. /**
  4. * Creates an instance of AuthorizationAdjustment as returned from a transaction
  5. *
  6. * @package Braintree
  7. *
  8. * @property-read string $amount
  9. * @property-read DateTime $timestamp
  10. * @property-read boolean $success
  11. *
  12. */
  13. class AuthorizationAdjustment extends Base
  14. {
  15. public static function factory($attributes)
  16. {
  17. $instance = new self();
  18. $instance->_initialize($attributes);
  19. return $instance;
  20. }
  21. protected function _initialize($authorizationAdjustmentAttribs)
  22. {
  23. $this->_attributes = $authorizationAdjustmentAttribs;
  24. }
  25. public function __toString()
  26. {
  27. return __CLASS__ . '[' . Util::attributesToString($this->_attributes) . ']';
  28. }
  29. }
  30. class_alias('Braintree\AuthorizationAdjustment', 'Braintree_Authorization_Adjustment');