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.
Completed
Pull Request — master (#113)
by Ha
02:28
created

Quota::delete()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php declare(strict_types=1);
2
3
namespace OpenStack\Networking\v2\Models;
4
5
use OpenStack\Common\Resource\Deletable;
6
use OpenStack\Common\Resource\OperatorResource;
7
use OpenStack\Common\Resource\Retrievable;
8
use OpenStack\Common\Resource\Updateable;
9
use OpenStack\Networking\v2\Api;
10
11
/**
12
 * Represents a Neutron v2 Quota
13
 *
14
 * @property Api $api
15
 */
16
class Quota extends OperatorResource implements Retrievable, Updateable, Deletable
17
{
18
    /**
19
     * @var int
20
     */
21
    public $subnet;
22
23
    /**
24
     * @var int
25
     */
26
    public $network;
27
28
    /**
29
     * @var int
30
     */
31
    public $floatingip;
32
33
    /**
34
     * @var string
35
     */
36
    public $tenantId;
37
38
    /**
39
     * @var int
40
     */
41
    public $subnetpool;
42
43
44
    /**
45
     * @var int
46
     */
47
    public $securityGroupRule;
48
49
    /**
50
     * @var int
51
     */
52
    public $securityGroup;
53
54
    /**
55
     * @var int
56
     */
57
    public $router;
58
59
    /**
60
     * @var int
61
     */
62
    public $rbacPolicy;
63
64
    /**
65
     * @var int
66
     */
67
    public $port;
68
69
    protected $resourcesKey = 'quotas';
70
    protected $resourceKey = 'quota';
71
72
    protected $aliases = [
73
        'tenant_id'           => 'tenantId',
74
        'security_group_rule' => 'securityGroupRule',
75
        'security_group'      => 'securityGroup',
76
        'rbac_policy'         => 'rbacPolicy',
77
    ];
78
79
    /**
80
     * {@inheritDoc}
81
     */
82
    public function retrieve()
83
    {
84
        $response = $this->execute($this->api->getQuota(), ['tenantId' => (string)$this->tenantId]);
85
        $this->populateFromResponse($response);
86
    }
87
88
    /**
89
     * {@inheritDoc}
90
     */
91
    public function update()
92
    {
93
        $response = $this->executeWithState($this->api->putQuota());
94
        $this->populateFromResponse($response);
95
    }
96
97
    /**
98
     * {@inheritDoc}
99
     */
100
    public function delete()
101
    {
102
        $this->executeWithState($this->api->deleteQuota());
103
    }
104
}
105