From 7e90be6807d098f7a3d06b0401eebf419d1b4a02 Mon Sep 17 00:00:00 2001 From: Ben Glassman Date: Sun, 15 Sep 2013 20:47:30 -0400 Subject: [PATCH] Remove add/setException methods. Remove @access/@return annotations. Move $exceptions property above methods. --- .../Exception/ChainNoResultException.php | 50 ++++--------------- 1 file changed, 9 insertions(+), 41 deletions(-) diff --git a/src/Geocoder/Exception/ChainNoResultException.php b/src/Geocoder/Exception/ChainNoResultException.php index edf18af42..c4475d227 100644 --- a/src/Geocoder/Exception/ChainNoResultException.php +++ b/src/Geocoder/Exception/ChainNoResultException.php @@ -17,62 +17,30 @@ class ChainNoResultException extends NoResultException { /** - * Constructor - * - * @param string $message - * @param array $exceptions Array of Exception instances - * @access public - * @return void - */ - public function __construct($message = "", array $exceptions = array()) - { - parent::__construct($message); - $this->setExceptions($exceptions); - } - - /** - * exceptions + * Exceptions from chained providers * * @var array - * @access private */ private $exceptions = array(); /** - * Get the exceptions - * - * @access public - * @return void - */ - public function getExceptions() - { - return $this->exceptions; - } - - /** - * Set the exceptions + * Constructor * + * @param string $message * @param array $exceptions Array of Exception instances - * @access public - * @return void */ - public function setExceptions(array $exceptions) + public function __construct($message = "", array $exceptions = array()) { - foreach ($exceptions as $exception) { - $this->addException($exception); - } + parent::__construct($message); + $this->exceptions = $exceptions; } /** - * Add an exception - * - * @param Exception $exception - * @access public - * @return void + * Get the exceptions from chained providers */ - public function addException(\Exception $exception) + public function getExceptions() { - $this->exceptions[] = $exception; + return $this->exceptions; } }