1: <?php
2: /**
3: * PHP OpenCloud library.
4: *
5: * @copyright 2013 Rackspace Hosting, Inc. See LICENSE for information.
6: * @license https://www.apache.org/licenses/LICENSE-2.0
7: * @author Jamie Hannaford <jamie.hannaford@rackspace.com>
8: */
9:
10: namespace OpenCloud\ObjectStore\Exception;
11:
12: class BulkOperationException extends \Exception
13: {
14: public function __construct(array $errors)
15: {
16: $output = '';
17:
18: foreach ($errors as $error) {
19: $output .= "$error[0]: $error[1]" . PHP_EOL;
20: }
21:
22: parent::__construct(
23: 'These errors occurred while performing an archive upload: ' . $output
24: );
25: }
26: }