UploadResponse::getSize()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 0
cts 4
cp 0
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 2
1
<?php declare(strict_types = 1);
2
3
namespace PeeHaa\AsyncTwitter\Api\Request\Media\Response;
4
5
class UploadResponse
6
{
7
    private $mediaId;
8
    private $size;
9
    private $expiryTime;
10
    private $mimeType;
11
    private $width;
12
    private $height;
13
14
    public function __construct(
15
        string $mediaId, int $size, \DateTimeImmutable $expiryTime,
16
        string $mimeType, int $width, int $height
17
    ) {
18
        $this->mediaId = $mediaId;
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 4 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
19
        $this->size = $size;
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 7 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
20
        $this->expiryTime = $expiryTime;
21
        $this->mimeType = $mimeType;
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 3 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
22
        $this->width = $width;
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 6 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
23
        $this->height = $height;
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 5 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
24
    }
25
26
    public function getMediaId(): string
27
    {
28
        return $this->mediaId;
29
    }
30
31
    public function getSize(): int
32
    {
33
        return $this->size;
34
    }
35
36
    public function getExpiryTime(): \DateTimeImmutable
37
    {
38
        return $this->expiryTime;
39
    }
40
41
    public function getMimeType(): string
42
    {
43
        return $this->mimeType;
44
    }
45
46
    public function getWidth(): int
47
    {
48
        return $this->width;
49
    }
50
51
    public function getHeight(): int
52
    {
53
        return $this->height;
54
    }
55
}
56