Completed
Push — php7-travis-apcu ( 9bbcee...fd63c3 )
by Alexander
14:47
created

BadRequestHttpException   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 13
rs 10
c 0
b 0
f 0
ccs 0
cts 4
cp 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
1
<?php
2
/**
3
 * @link http://www.yiiframework.com/
4
 * @copyright Copyright (c) 2008 Yii Software LLC
5
 * @license http://www.yiiframework.com/license/
6
 */
7
8
namespace yii\web;
9
10
/**
11
 * BadRequestHttpException represents a "Bad Request" HTTP exception with status code 400.
12
 *
13
 * Use this exception to represent a generic client error. In many cases, there
14
 * may be an HTTP exception that more precisely describes the error. In that
15
 * case, consider using the more precise exception to provide the user with
16
 * additional information.
17
 *
18
 * @see https://tools.ietf.org/html/rfc7231#section-6.5.1
19
 * @author Qiang Xue <[email protected]>
20
 * @since 2.0
21
 */
22
class BadRequestHttpException extends HttpException
23
{
24
    /**
25
     * Constructor.
26
     * @param string $message error message
27
     * @param int $code error code
28
     * @param \Exception $previous The previous exception used for the exception chaining.
29
     */
30
    public function __construct($message = null, $code = 0, \Exception $previous = null)
31
    {
32
        parent::__construct(400, $message, $code, $previous);
33
    }
34
}
35