From 77a8eb45489b075850d94a109d1be21c38e0601c Mon Sep 17 00:00:00 2001 From: 4Giedrius <4giedrius@gmail.com> Date: Mon, 8 Dec 2014 15:19:27 +0200 Subject: [PATCH] Added Dependecy Injector methods to Box_Curl() --- src/bb-library/Box/Curl.php | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/src/bb-library/Box/Curl.php b/src/bb-library/Box/Curl.php index 2f138f95a..79216bc69 100644 --- a/src/bb-library/Box/Curl.php +++ b/src/bb-library/Box/Curl.php @@ -31,7 +31,28 @@ class Box_Curl { public $authentication = 0; public $auth_name = ''; public $auth_pass = ''; - + + /** + * @var \Box_Di + */ + protected $di = null; + + /** + * @param \Box_Di $di + */ + public function setDi($di) + { + $this->di = $di; + } + + /** + * @return \Box_Di + */ + public function getDi() + { + return $this->di; + } + public function __construct($url, $timeOut = 30, $followlocation = true, $maxRedirecs = 4, $binaryTransfer = false, $includeHeader = false, $noBody = false) { if (!extension_loaded('curl')) { throw new \Box_Exception('CURL extension is not enabled');