Completed
Push — master ( 2e6749...8bcd18 )
by Sam
02:24
created

StatisticsResponse::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 8
rs 9.4285
cc 1
eloc 5
nc 1
nop 3
1
<?php
2
3
namespace Jalle19\StatusManager\Message\Response;
4
5
use Jalle19\StatusManager\Message\AbstractMessage;
6
use Jalle19\StatusManager\Message\Request\StatisticsRequest;
7
8
/**
9
 * Class StatisticsResponse
10
 * @package   Jalle19\StatusManager\Message\Response
11
 * @copyright Copyright &copy; Sam Stenvall 2016-
12
 * @license   https://www.gnu.org/licenses/gpl.html The GNU General Public License v2.0
13
 */
14
abstract class StatisticsResponse extends AbstractMessage
15
{
16
17
	/**
18
	 * StatisticsResponse constructor.
19
	 *
20
	 * @param string            $type
21
	 * @param StatisticsRequest $request
22
	 * @param mixed             $response
23
	 */
24
	public function __construct($type, $request, $response)
25
	{
26
		$payload           = new \stdClass();
27
		$payload->request  = $request;
28
		$payload->response = $response;
29
30
		parent::__construct($type, $payload);
31
	}
32
33
}
34