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.

IngestStatus   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 2
eloc 11
c 1
b 0
f 1
dl 0
loc 32
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A fromArray() 0 6 1
A __construct() 0 5 1
1
<?php
2
3
namespace ApiVideo\Client\Model;
4
5
class IngestStatus
6
{
7
    /** @var string */
8
    public $status;
9
    /** @var int */
10
    public $fileSize;
11
    /** @var array */
12
    public $receivedBytes;
13
14
    /**
15
     * IngestStatus constructor.
16
     * @param string $status
17
     * @param int    $fileSize
18
     * @param array  $receivedBytes
19
     */
20
    public function __construct($status, $fileSize, array $receivedBytes)
21
    {
22
        $this->status        = $status;
23
        $this->fileSize      = $fileSize;
24
        $this->receivedBytes = $receivedBytes;
25
    }
26
27
    /**
28
     * @param array $data
29
     * @return self
30
     */
31
    public static function fromArray(array $data)
32
    {
33
        return new self(
34
            $data['status'],
35
            $data['filesize'],
36
            $data['receivedBytes']
37
        );
38
    }
39
}