MethodNotAllowedException::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
1
<?php
2
3
namespace Piface\Router\Exception;
4
5
use Piface\Router\Exception;
6
7
class MethodNotAllowedException extends Exception
8
{
9
    public function __construct(array $allow, string $path)
10
    {
11
        $message = sprintf("No route found for '%s'. Method not allowed (Allow: %s)", $path, implode(',', $allow));
12
        parent::__construct($message);
13
    }
14
}
15