InsightModuleResponse::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 14
Code Lines 12

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 1
eloc 12
c 2
b 0
f 0
nc 1
nop 1
dl 0
loc 14
rs 9.8666
1
<?php
2
3
namespace AcquiaCloudApi\Response;
4
5
class InsightModuleResponse
6
{
7
    public int $module_id;
8
9
    public string $name;
10
11
    public string $filename;
12
13
    public string $version;
14
15
    public ?string $supported_majors;
16
17
    public ?string $recommended_major;
18
19
    public string $package;
20
21
    public string $core;
22
23
    public string $project;
24
25
    public ?string $release_date;
26
27
    public object $flags;
28
29
    /**
30
     * @var array<string> $tags
31
     */
32
    public array $tags;
33
34
    public function __construct(object $module)
35
    {
36
        $this->module_id = $module->module_id;
37
        $this->name = $module->name;
38
        $this->filename = $module->filename;
39
        $this->version = $module->version;
40
        $this->supported_majors = $module->supported_majors;
41
        $this->recommended_major = $module->recommended_major;
42
        $this->package = $module->package;
43
        $this->core = $module->core;
44
        $this->project = $module->project;
45
        $this->release_date = $module->release_date;
46
        $this->flags = $module->flags;
47
        $this->tags = $module->tags;
48
    }
49
}
50