mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2025-01-15 08:11:14 +01:00
27 lines
553 B
PHP
27 lines
553 B
PHP
|
<?php
|
||
|
|
||
|
declare(strict_types=1);
|
||
|
|
||
|
namespace Xentral\Components\I18n\Dataaccess;
|
||
|
|
||
|
/**
|
||
|
* Provides countable functions to the data provider.
|
||
|
*
|
||
|
* @see \Countable
|
||
|
* @see DataProvider
|
||
|
* @see DataProviderInterface
|
||
|
* @author Roland Rusch, easy-smart solution GmbH <roland.rusch@easy-smart.ch>
|
||
|
*/
|
||
|
trait CountableTrait
|
||
|
{
|
||
|
/**
|
||
|
* Counts the number of records in the private $data array.
|
||
|
*
|
||
|
* @return int Number of records
|
||
|
*/
|
||
|
public function count(): int
|
||
|
{
|
||
|
return count($this->DataProvider_DATA);
|
||
|
}
|
||
|
}
|