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.

AbstractProtocol::send()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * This file is part of the O2System Framework package.
4
 *
5
 * For the full copyright and license information, please view the LICENSE
6
 * file that was distributed with this source code.
7
 *
8
 * @author         Steeve Andrian Salim
9
 * @copyright      Copyright (c) Steeve Andrian Salim
10
 */
11
12
// ------------------------------------------------------------------------
13
14
namespace O2System\Email\Protocols\Abstracts;
15
16
// ------------------------------------------------------------------------
17
18
use O2System\Email\Message;
19
use O2System\Email\Spool;
20
use O2System\Spl\Traits\Collectors\ErrorCollectorTrait;
21
22
/**
23
 * Class AbstractProtocol
24
 *
25
 * @package O2System\Email\Abstracts
26
 */
27
abstract class AbstractProtocol
28
{
29
    use ErrorCollectorTrait;
30
31
    /**
32
     * AbstractProtocol::$spool
33
     *
34
     * @var Spool
35
     */
36
    protected $spool;
37
38
    /**
39
     * AbstractProtocol::$message
40
     *
41
     * @var Message
42
     */
43
    protected $message;
44
45
    // ------------------------------------------------------------------------
46
47
    /**
48
     * AbstractProtocol constructor.
49
     *
50
     * @param \O2System\Email\Spool $spool
51
     */
52
    public function __construct(Spool $spool)
53
    {
54
        $this->spool = $spool;
55
    }
56
57
    /**
58
     * AbstractProtocol::send
59
     *
60
     * Send the message.
61
     *
62
     * @param Message $message
63
     *
64
     * @return bool
65
     */
66
    public function send(Message $message)
67
    {
68
        return $this->sending($message);
69
    }
70
71
    // ------------------------------------------------------------------------
72
73
    /**
74
     * AbstractProtocol::sending
75
     *
76
     * Protocol message sending process.
77
     *
78
     * @param Message $message
79
     *
80
     * @return bool
81
     */
82
    abstract protected function sending(Message $message);
83
}