Completed
Push — master ( 5a4a4b...5fab5f )
by Camilo
04:08 queued 01:36
created

GetUserProfilePhotos   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 30
ccs 2
cts 2
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A bindToObjectType() 0 4 1
1
<?php
0 ignored issues
show
Coding Style Compatibility introduced by
For compatibility and reusability of your code, PSR1 recommends that a file should introduce either new symbols (like classes, functions, etc.) or have side-effects (like outputting something, or including other files), but not both at the same time. The first symbol is defined on line 14 and the first side effect is on line 3.

The PSR-1: Basic Coding Standard recommends that a file should either introduce new symbols, that is classes, functions, constants or similar, or have side effects. Side effects are anything that executes logic, like for example printing output, changing ini settings or writing to a file.

The idea behind this recommendation is that merely auto-loading a class should not change the state of an application. It also promotes a cleaner style of programming and makes your code less prone to errors, because the logic is not spread out all over the place.

To learn more about the PSR-1, please see the PHP-FIG site on the PSR-1.

Loading history...
2
3
declare(strict_types = 1);
4
5
namespace unreal4u\Telegram\Methods;
6
7
use unreal4u\InternalFunctionality\AbstractMethodFunctions;
8
9
/**
10
 * Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.
11
 *
12
 * @see https://core.telegram.org/bots/api#getuserprofilephotos
13
 */
14
class GetUserProfilePhotos extends AbstractMethodFunctions
15
{
16
    /**
17
     * Unique identifier of the target user
18
     * @var int
19
     */
20
    public $user_id = 0;
21
22
    /**
23
     * Optional. Sequential number of the first photo to be returned. By default, all photos are returned.
24
     * @var int
25
     */
26
    public $offset = 0;
27
28
    /**
29
     * Optional. Limits the number of photos to be retrieved. Values between 1—100 are accepted. Defaults to 100.
30
     * @var int
31
     */
32
    public $limit = 100;
33
34
    /**
35
     * This call will return an array with updates, so call up a custom type to do this
36
     *
37
     * @return string
38
     */
39 2
    public static function bindToObjectType(): string
40
    {
41 2
        return 'UserProfilePhotos';
42
    }
43
}
44