GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

ValuesRule   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 3

Test Coverage

Coverage 100%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A values() 0 4 1
1
<?php
2
namespace PhpBoot\DB\rules\replace;
3
4
use PhpBoot\DB\rules\basic\BasicRule;
5
use PhpBoot\DB\rules\basic\ExecRule;
6
use PhpBoot\DB\impls\ReplaceImpl;
7
use PhpBoot\DB\impls\ValuesImpl;
8
9
require_once dirname(__DIR__).'/impls.php';
10
require_once __DIR__.'/basic.php';
11
12
class ReplaceIntoRule extends BasicRule
13
{
14
    /**
15
     * replaceInto('table')->values([1,2]) => "REPLACE INTO table VALUES(1,2)"
16
     * @param string $table
17
     * @return \PhpBoot\DB\rules\replace\ValuesRule
18
     */
19 2
    public function replaceInto($table) {
20 2
        ReplaceImpl::replaceInto($this->context, $table);
21 2
        return new ValuesRule($this->context);
22
    }
23
}
24
class ValuesRule extends BasicRule
25
{
26
    /**
27
     * replaceInto('table')->values([1,2]) => "REPLACE INTO table VALUES(1,2)"
28
     * replaceInto('table')->values(['a'=>1, 'b'=>Sql::raw('now()')]) => "REPLACE INTO table(a,b) VALUES(1,now())"
29
     * @param array $values
30
     * @return \PhpBoot\DB\rules\basic\ExecRule
31
     */
32 2
    public function values($values) {
33 2
        ValuesImpl::values($this->context, $values);
34 2
        return new ExecRule($this->context);
35
    }
36
}