Request::doGetRequestData()
last analyzed

Size

Total Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 1 Features 0
Metric Value
c 1
b 1
f 0
dl 0
loc 1
nc 1
1
<?php
2
3
namespace PEIP\ABS\Request;
4
5
/*
6
 * This file is part of the PEIP package.
7
 * (c) 2009-2016 Timo Michna <timomichna/yahoo.de>
8
 *
9
 * For the full copyright and license information, please view the LICENSE
10
 * file that was distributed with this source code.
11
 */
12
13
/*
14
 * PEIP\ABS\Request\Request
15
 *
16
 * @author Timo Michna <timomichna/yahoo.de>
17
 * @package PEIP
18
 * @subpackage request
19
 * @extends \PEIP\Data\ParameterHolder
20
 * @implements \PEIP\INF\Data\ParameterHolder, \PEIP\INF\Command\Command, \PEIP\INF\Request\Request
21
 */
22
23
24
25
abstract class Request extends \PEIP\Data\ParameterHolder implements
26
        \PEIP\INF\Command\Command,
27
        \PEIP\INF\Request\Request
28
{
29
    protected $connection;
30
31
    /**
32
     * @param $connection
33
     *
34
     * @return
35
     */
36
    public function setConnection($connection)
37
    {
38
        $this->connection = $connection;
39
    }
40
41
    /**
42
     * @return
43
     */
44
    public function execute()
45
    {
46
        return $this->send();
47
    }
48
49
    /**
50
     * @return
51
     */
52
    public function send()
53
    {
54
        return $this->connection->sendRequest($this);
55
    }
56
57
    /**
58
     * @return
59
     */
60
    public function getRequestData()
61
    {
62
        return $this->doGetRequestData();
63
    }
64
65
    /**
66
     * @return
67
     */
68
    abstract protected function doGetRequestData();
69
}
70