LimitDescriptor   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 2
dl 0
loc 14
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 2
1
<?php
2
// Copyright 1999-2021. Plesk International GmbH.
3
4
namespace PleskX\Api\Struct\Webspace;
5
6
class LimitDescriptor extends \PleskX\Api\Struct
7
{
8
    /** @var array */
9
    public $limits;
10
11
    public function __construct($apiResponse)
12
    {
13
        $this->limits = [];
14
15
        foreach ($apiResponse->descriptor->property as $propertyInfo) {
16
            $this->limits[(string) $propertyInfo->name] = new LimitInfo($propertyInfo);
17
        }
18
    }
19
}
20