mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-27 07:44:05 +02:00
ipl\Html: implement Countable
This commit is contained in:
parent
098cd0a57a
commit
51f5b6ad92
15
library/vendor/ipl/Html/Html.php
vendored
15
library/vendor/ipl/Html/Html.php
vendored
@ -2,10 +2,15 @@
|
||||
|
||||
namespace ipl\Html;
|
||||
|
||||
use Countable;
|
||||
use Exception;
|
||||
use Icinga\Exception\ProgrammingError;
|
||||
|
||||
class Html implements ValidHtml
|
||||
/**
|
||||
* Class Html
|
||||
* @package ipl\Html
|
||||
*/
|
||||
class Html implements ValidHtml, Countable
|
||||
{
|
||||
protected $contentSeparator = '';
|
||||
|
||||
@ -134,6 +139,14 @@ class Html implements ValidHtml
|
||||
return ! empty($this->content);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function count()
|
||||
{
|
||||
return count($this->content);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $separator
|
||||
* @return self
|
||||
|
Loading…
x
Reference in New Issue
Block a user