mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-08 05:18:40 +00:00
Fix phpstorm inspections
This commit is contained in:
parent
634c1e33b7
commit
b723bcb3f7
|
|
@ -42,6 +42,8 @@ class MemCache implements CacheInterface
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
private $threshold = 10;
|
private $threshold = 10;
|
||||||
|
|
||||||
|
private $status;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor.
|
* Constructor.
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ class MemCached implements CacheInterface
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
private $threshold = 10;
|
private $threshold = 10;
|
||||||
|
private $status;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor.
|
* Constructor.
|
||||||
|
|
|
||||||
|
|
@ -60,6 +60,14 @@ abstract class BuilderAbstract
|
||||||
*/
|
*/
|
||||||
protected $prefix = '';
|
protected $prefix = '';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Raw.
|
||||||
|
*
|
||||||
|
* @var string
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
public $raw = '';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set prefix.
|
* Set prefix.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -347,7 +347,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
self::extend(__CLASS__);
|
self::extend(__CLASS__);
|
||||||
|
|
||||||
if ($obj === null ||
|
if ($obj === null ||
|
||||||
(is_object($obj) && strpos($className = get_class($obj), '\Null') !== false)
|
(strpos($className = get_class($obj), '\Null') !== false && is_object($obj))
|
||||||
) {
|
) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -181,14 +181,6 @@ class Builder extends BuilderAbstract
|
||||||
*/
|
*/
|
||||||
public $lock = false;
|
public $lock = false;
|
||||||
|
|
||||||
/**
|
|
||||||
* Raw query.
|
|
||||||
*
|
|
||||||
* @var string
|
|
||||||
* @since 1.0.0
|
|
||||||
*/
|
|
||||||
public $raw = '';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Comparison OPERATORS.
|
* Comparison OPERATORS.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,9 @@ declare(strict_types = 1);
|
||||||
namespace phpOMS\Utils\Crawler;
|
namespace phpOMS\Utils\Crawler;
|
||||||
|
|
||||||
use phpOMs\DataStorage\Database\Query\Builder as DatabaseQueryBuilder;
|
use phpOMs\DataStorage\Database\Query\Builder as DatabaseQueryBuilder;
|
||||||
|
use phpOMS\Localization\Localization;
|
||||||
|
use phpOMS\Message\Http\Rest;
|
||||||
|
use phpOMS\Uri\Http;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Array utils.
|
* Array utils.
|
||||||
|
|
|
||||||
|
|
@ -35,11 +35,9 @@ class IdentityMatrix extends Matrix
|
||||||
*/
|
*/
|
||||||
public function __construct(int $n)
|
public function __construct(int $n)
|
||||||
{
|
{
|
||||||
$this->n = $n;
|
parent::__construct($n, $n);
|
||||||
$this->m = $n;
|
|
||||||
|
|
||||||
for ($i = 0; $i < $n; $i++) {
|
for ($i = 0; $i < $n; $i++) {
|
||||||
$this->matrix[$i] = array_fill(0, $n, 0);
|
|
||||||
$this->matrix[$i][$i] = 1;
|
$this->matrix[$i][$i] = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,8 @@
|
||||||
declare(strict_types = 1);
|
declare(strict_types = 1);
|
||||||
namespace phpOMS\Math\Optimization\Graph;
|
namespace phpOMS\Math\Optimization\Graph;
|
||||||
|
|
||||||
|
use phpOMS\Stdlib\Graph\Graph;
|
||||||
|
|
||||||
class Dijkstra
|
class Dijkstra
|
||||||
{
|
{
|
||||||
public static function dijkstra(Graph $graph, $source, $target)
|
public static function dijkstra(Graph $graph, $source, $target)
|
||||||
|
|
|
||||||
|
|
@ -19,6 +19,7 @@ use phpOMS\ApplicationAbstract;
|
||||||
use phpOMS\Autoloader;
|
use phpOMS\Autoloader;
|
||||||
use phpOMS\DataStorage\Database\DatabaseType;
|
use phpOMS\DataStorage\Database\DatabaseType;
|
||||||
use phpOMS\Message\Http\Request;
|
use phpOMS\Message\Http\Request;
|
||||||
|
use phpOMS\Message\RequestAbstract;
|
||||||
use phpOMS\System\File\PathException;
|
use phpOMS\System\File\PathException;
|
||||||
use phpOMS\Module\Exception\InvalidModuleException;
|
use phpOMS\Module\Exception\InvalidModuleException;
|
||||||
|
|
||||||
|
|
@ -109,13 +110,13 @@ class ModuleManager
|
||||||
/**
|
/**
|
||||||
* Get language files.
|
* Get language files.
|
||||||
*
|
*
|
||||||
* @param Request $request Request
|
* @param RequestAbstract $request Request
|
||||||
*
|
*
|
||||||
* @return array
|
* @return array
|
||||||
*
|
*
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
public function getLanguageFiles(Request $request) : array
|
public function getLanguageFiles(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$files = $this->getUriLoad($request);
|
$files = $this->getUriLoad($request);
|
||||||
|
|
||||||
|
|
@ -132,13 +133,13 @@ class ModuleManager
|
||||||
/**
|
/**
|
||||||
* Get modules that run on this page.
|
* Get modules that run on this page.
|
||||||
*
|
*
|
||||||
* @param Request $request Request
|
* @param RequestAbstract $request Request
|
||||||
*
|
*
|
||||||
* @return array
|
* @return array
|
||||||
*
|
*
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
public function getUriLoad(Request $request) : array
|
public function getUriLoad(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
if (!isset($this->uriLoad)) {
|
if (!isset($this->uriLoad)) {
|
||||||
switch ($this->app->dbPool->get('select')->getType()) {
|
switch ($this->app->dbPool->get('select')->getType()) {
|
||||||
|
|
|
||||||
|
|
@ -280,9 +280,9 @@ class MultiMap implements \Countable
|
||||||
{
|
{
|
||||||
if ($this->keyType === KeyType::MULTIPLE && is_array($key)) {
|
if ($this->keyType === KeyType::MULTIPLE && is_array($key)) {
|
||||||
return $this->removeMultiple($key);
|
return $this->removeMultiple($key);
|
||||||
} else {
|
|
||||||
return $this->removeSingle($key);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return $this->removeSingle($key);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -290,11 +290,11 @@ class MultiMap implements \Countable
|
||||||
*
|
*
|
||||||
* @param mixed $key Key used to identify value
|
* @param mixed $key Key used to identify value
|
||||||
*
|
*
|
||||||
* @return void
|
* @return bool
|
||||||
*
|
*
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
private function removeMultiple($key) /* : void */
|
private function removeMultiple($key) : bool
|
||||||
{
|
{
|
||||||
if ($this->orderType !== OrderType::LOOSE) {
|
if ($this->orderType !== OrderType::LOOSE) {
|
||||||
return $this->remove(implode(':', $key));
|
return $this->remove(implode(':', $key));
|
||||||
|
|
|
||||||
|
|
@ -33,6 +33,14 @@ use phpOMS\System\File\Local\Directory as DirectoryLocal;
|
||||||
*/
|
*/
|
||||||
class Directory extends FileAbstract implements DirectoryInterface
|
class Directory extends FileAbstract implements DirectoryInterface
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* Directory nodes (files and directories).
|
||||||
|
*
|
||||||
|
* @var FileAbstract[]
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
private $nodes = [];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,6 @@ class LZW implements CompressionInterface
|
||||||
*/
|
*/
|
||||||
public function compress(string $source) : string
|
public function compress(string $source) : string
|
||||||
{
|
{
|
||||||
$wc = '';
|
|
||||||
$w = '';
|
$w = '';
|
||||||
$dictionary = [];
|
$dictionary = [];
|
||||||
$result = [];
|
$result = [];
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user