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 ( c99574...e190cf )
by Cas
04:59
created

User::isBot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
/*
4
 * This file is part of the Slack API library.
5
 *
6
 * (c) Cas Leentfaar <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace CL\Slack\Model;
13
14
/**
15
 * @author Cas Leentfaar <[email protected]>
16
 *
17
 * @link Official documentation at https://api.slack.com/types/user
18
 */
19
class User extends AbstractModel
20
{
21
    /**
22
     * @var string
23
     */
24
    private $id;
25
26
    /**
27
     * @var string
28
     */
29
    private $name;
30
31
    /**
32
     * @var string|null
33
     */
34
    private $color;
35
36
    /**
37
     * @var UserProfile|null
38
     */
39
    private $profile;
40
41
    /**
42
     * @var bool|null
43
     */
44
    private $isAdmin;
45
46
    /**
47
     * @var bool|null
48
     */
49
    private $isBot;
50
51
    /**
52
     * @var bool|null
53
     */
54
    private $isRestricted;
55
56
    /**
57
     * @var bool|null
58
     */
59
    private $isUltraRestricted;
60
61
    /**
62
     * @var bool|null
63
     */
64
    private $deleted;
65
66
    /**
67
     * @var bool|null
68
     */
69
    private $hasFiles;
70
71
    /**
72
     * @return string The ID of this member.
73
     */
74 3
    public function getId()
75
    {
76 3
        return $this->id;
77
    }
78
79
    /**
80
     * @return string The (user)name of this member
81
     */
82 3
    public function getName()
83
    {
84 3
        return $this->name;
85
    }
86
87
    /**
88
     * @return string|null Hexadecimal colorcode used in some clients to display a colored username.
89
     */
90 3
    public function getColor()
91
    {
92 3
        return $this->color;
93
    }
94
95
    /**
96
     * @return MemberProfile The profile object for this member
97
     */
98 3
    public function getProfile()
99
    {
100 3
        return $this->profile;
101
    }
102
103
    /**
104
     * @return bool True if the user has been given the admin role, false otherwise.
105
     */
106 3
    public function isAdmin()
107
    {
108 3
        return $this->isAdmin;
109
    }
110
111
    /**
112
     * @return bool True if the user is a bot, false otherwise.
113
     */
114 3
    public function isBot()
115
    {
116 3
        return $this->isBot;
117
    }
118
119
    /**
120
     * @return bool True if the user has restrictions applied, false otherwise.
121
     */
122 3
    public function isRestricted()
123
    {
124 3
        return $this->isRestricted;
125
    }
126
127
    /**
128
     * @return bool True if the user has ultra restrictions applied, false otherwise.
129
     */
130 3
    public function isUltraRestricted()
131
    {
132 3
        return $this->isUltraRestricted;
133
    }
134
135
    /**
136
     * @return bool True if the user has been deactivated.
137
     */
138 3
    public function isDeleted()
139
    {
140 3
        return $this->deleted;
141
    }
142
143
    /**
144
     * @return bool True if the user has added files to the Slack instance, false otherwise.
145
     */
146 3
    public function hasFiles()
147
    {
148 3
        return $this->hasFiles;
149
    }
150
}
151