Passed
Pull Request — master (#793)
by Alexander
10:27 queued 08:06
created

QueryContext   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 4
c 1
b 0
f 0
dl 0
loc 15
rs 10
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A getCategory() 0 3 1
A getRawSql() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Db\Logger\Context;
6
7
final class QueryContext extends AbstractContext
8
{
9
    public function __construct(string $methodName, private string $rawSql, private string $category)
10
    {
11
        parent::__construct($methodName);
12
    }
13
14
    public function getRawSql(): string
15
    {
16
        return $this->rawSql;
17
    }
18
19
    public function getCategory(): string
20
    {
21
        return $this->category;
22
    }
23
}
24