Scopes::getScopeEntityByIdentifier()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 0

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 0
c 1
b 0
f 1
dl 0
loc 2
rs 10
ccs 0
cts 1
cp 0
cc 1
nc 1
nop 1
crap 2
1
<?php
2
3
namespace ByTIC\Hello\Models\Scopes;
4
5
use League\OAuth2\Server\Entities\ClientEntityInterface;
6
use League\OAuth2\Server\Entities\ScopeEntityInterface;
7
use League\OAuth2\Server\Repositories\ScopeRepositoryInterface;
8
9
/**
10
 * Class Tokens
11
 * @package ByTIC\Hello\Models\Scopes
12
 */
13
class Scopes extends \Nip\Records\RecordManager implements ScopeRepositoryInterface
14
{
15
    /**
16
     * Return information about a scope.
17
     *
18
     * @param string $identifier The scope identifier
19
     *
20
     * @return ScopeEntityInterface
21
     */
22
    public function getScopeEntityByIdentifier($identifier)
23
    {
24
        // TODO: Implement getScopeEntityByIdentifier() method.
25
    }
26
27
    /**
28
     * Given a client, grant type and optional user identifier validate the set of scopes requested are valid and optionally
29
     * append additional scopes or remove requested scopes.
30
     *
31
     * @param ScopeEntityInterface[] $scopes
32
     * @param string $grantType
33
     * @param ClientEntityInterface $clientEntity
34
     * @param null|string $userIdentifier
35
     *
36
     * @return ScopeEntityInterface[]
37
     */
38
    public function finalizeScopes(
39
        array $scopes,
40
        $grantType,
41
        ClientEntityInterface $clientEntity,
42
        $userIdentifier = null
43
    ) {
44
        // TODO: Implement finalizeScopes() method.
45
        return [];
46
    }
47
48
    /** @noinspection PhpMissingParentCallCommonInspection
49
     * @inheritDoc
50
     */
51
    protected function generateTable()
52
    {
53
        return 'oauth_scopes';
54
    }
55
}
56