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
Push — master ( 8fccc5...dea5ad )
by Jamie
8s
created

Service::floatingIp()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %
Metric Value
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
namespace OpenStack\Networking\v2\Extensions\Layer3;
4
5
use OpenCloud\Common\Service\AbstractService;
6
use OpenStack\Networking\v2\Extensions\Layer3\Models\FloatingIp;
7
use OpenStack\Networking\v2\Extensions\Layer3\Models\Router;
8
9
/**
10
 * @property Api $api
11
 */
12
class Service extends AbstractService
13
{
14
    private function floatingIp(array $info = []): FloatingIp
15
    {
16
        return $this->model(FloatingIp::class, $info);
17
    }
18
19
    private function router(array $info = []): Router
20
    {
21
        return $this->model(Router::class, $info);
22
    }
23
24
    /**
25
     * @param array $options
26
     *
27
     * @return FloatingIp
28
     */
29
    public function createFloatingIp(array $options): FloatingIp
30
    {
31
        return $this->floatingIp()->create($options);
32
    }
33
34
    /**
35
     * @return FloatingIp
36
     */
37
    public function getFloatingIp($id): FloatingIp
38
    {
39
        return $this->floatingIp(['id' => $id]);
40
    }
41
42
    /**
43
     * @return \Generator
44
     */
45
    public function listFloatingIps(): \Generator
46
    {
47
        return $this->floatingIp()->enumerate($this->api->getFloatingIps());
48
    }
49
50
    /**
51
     * @param array $options
52
     *
53
     * @return Router
54
     */
55
    public function createRouter(array $options): Router
56
    {
57
        return $this->router()->create($options);
58
    }
59
60
    /**
61
     * @return Router
62
     */
63
    public function getRouter($id): Router
64
    {
65
        return $this->router(['id' => $id]);
66
    }
67
68
    /**
69
     * @return \Generator
70
     */
71
    public function listRouters(): \Generator
72
    {
73
        return $this->router()->enumerate($this->api->getRouters());
74
    }
75
}
76