PagingResultDto::importDatabase()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 5
nc 1
nop 2
1
<?php
2
namespace Ridibooks\Platform\Common\Dto;
3
4
class PagingResultDto
5
{
6
	/**
7
	 * @var array
8
	 */
9
	public $items;
10
11
	/**
12
	 * @var int
13
	 */
14
	public $total_count;
15
16
	public static function importDatabase($items, $total_count)
17
	{
18
		$dto = new self;
19
		$dto->items = $items;
20
		$dto->total_count = $total_count;
21
22
		return $dto;
23
	}
24
}
25