ReadonlyLinodeApiResource::delete()   A
last analyzed

Complexity

Conditions 1
Paths 0

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
eloc 1
nc 0
nop 0
1
<?php
2
3
namespace Linode\Api\Api;
4
5
abstract class ReadonlyLinodeApiResource extends LinodeApiResource
6
{
7
    /**
8
     * Update resource data.
9
     *
10
     * @param array $payload
11
     *
12
     * @throws \LogicException
13
     *
14
     * @return bool
15
     */
16
    public function update(array $payload): bool
17
    {
18
        throw new \LogicException(get_class($this).' is a read-only resource.');
19
    }
20
21
    /**
22
     * Delete current resource.
23
     *
24
     * @throws \LogicException
25
     */
26
    public function delete(): bool
27
    {
28
        throw new \LogicException(get_class($this).' is a read-only resource.');
29
    }
30
}
31