TaskRuntimeException   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Dependencies 1

Importance

Changes 0
Metric Value
wmc 2
cbo 1
dl 0
loc 13
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 2
1
<?php
2
3
/**
4
 * This file is part of bldr
5
 *
6
 * (c) Aaron Scherer <[email protected]>
7
 *
8
 * This source file is subject to the license that is bundled
9
 * with this source code in the file LICENSE
10
 */
11
12
namespace Bldr\Exception;
13
14
/**
15
 * @author Aaron Scherer <[email protected]>
16
 */
17
class TaskRuntimeException extends BldrException
18
{
19
    /**
20
     * @param string $task    The task name
21
     * @param string $message The error output
22
     */
23
    public function __construct($task, $message = '')
24
    {
25
        parent::__construct(
26
            sprintf("There was an error running the %s task. %s", $task, empty($message) ? '' : 'Output: '.$message)
27
        );
28
    }
29
}
30