StreamRead   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 50%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
c 1
b 0
f 0
dl 0
loc 10
ccs 2
cts 4
cp 0.5
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A isWrite() 0 3 1
A applyGzip() 0 4 1
1
<?php
0 ignored issues
show
introduced by
Missing declare(strict_types=1).
Loading history...
2
3
namespace ClickHouseDB\Transport;
4
5
/**
6
 * Class StreamRead
0 ignored issues
show
introduced by
Documentation comment contains forbidden comment "Class StreamRead".
Loading history...
7
 * @package ClickHouseDB\Transport
0 ignored issues
show
introduced by
Expected 1 lines between description and annotations, found 0.
Loading history...
introduced by
Use of annotation @package is forbidden.
Loading history...
8
 */
9
class StreamRead extends Stream
10
{
11 1
    public function isWrite()
0 ignored issues
show
introduced by
Method \ClickHouseDB\Transport\StreamRead::isWrite() does not have return type hint nor @return annotation for its return value.
Loading history...
12
    {
13 1
        return false;
14
    }
0 ignored issues
show
Coding Style introduced by
Expected 1 blank line after function; 0 found
Loading history...
15
    public function applyGzip()
0 ignored issues
show
introduced by
Method \ClickHouseDB\Transport\StreamRead::applyGzip() does not have void return type hint.
Loading history...
16
    {
17
//        stream_filter_append($this->source, 'zlib.deflate', STREAM_FILTER_READ, ['window' => 30]);
18
        $this->enableGzipHeader();
19
    }
20
}
21