mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 02:31:40 +09:00
Clean up missing or inconsistent types in remainder of parser classes
This commit is contained in:
parent
141ee7f7e1
commit
c01ba1d3cf
4 changed files with 20 additions and 20 deletions
|
|
@ -99,7 +99,7 @@ class Query extends VariableBase
|
|||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getQueryParams()
|
||||
public function getQueryParams(): array
|
||||
{
|
||||
return $this->_params;
|
||||
}
|
||||
|
|
@ -596,7 +596,7 @@ class Query extends VariableBase
|
|||
/**
|
||||
* Generate a ORDER BY clause from navigation settings.
|
||||
*
|
||||
* @param object $navigation
|
||||
* @param Navigation $navigation
|
||||
* @return string
|
||||
*/
|
||||
protected function _arrangeOrderBy(Navigation $navigation): string
|
||||
|
|
@ -643,7 +643,7 @@ class Query extends VariableBase
|
|||
/**
|
||||
* Generate a LIMIT/OFFSET clause from navigation settings.
|
||||
*
|
||||
* @param object $navigation
|
||||
* @param Navigation $navigation
|
||||
* @return string
|
||||
*/
|
||||
protected function _arrangeLimitOffset(Navigation $navigation): string
|
||||
|
|
@ -688,7 +688,7 @@ class Query extends VariableBase
|
|||
/**
|
||||
* Generate each condition in a WHERE clause.
|
||||
*
|
||||
* @param object $condition
|
||||
* @param VariableBase $condition
|
||||
* @return string
|
||||
*/
|
||||
protected function _parseCondition(VariableBase $condition): string
|
||||
|
|
@ -736,7 +736,7 @@ class Query extends VariableBase
|
|||
* @param bool $allow_empty_string
|
||||
* @return bool
|
||||
*/
|
||||
public static function isValidVariable($var, $allow_empty_string = true): bool
|
||||
public static function isValidVariable($var, bool $allow_empty_string = true): bool
|
||||
{
|
||||
if ($var === null || ($var === '' && !$allow_empty_string))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -284,7 +284,7 @@ class VariableBase
|
|||
* @param array $args
|
||||
* @return array
|
||||
*/
|
||||
public function getValue(array $args)
|
||||
public function getValue(array $args): array
|
||||
{
|
||||
if ($this->var && Query::isValidVariable($args[$this->var] ?? null, $this instanceof ColumnWrite))
|
||||
{
|
||||
|
|
@ -324,7 +324,7 @@ class VariableBase
|
|||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getDefaultValue()
|
||||
public function getDefaultValue(): array
|
||||
{
|
||||
// Get the current column name.
|
||||
$column = $this instanceof ColumnWrite ? $this->name : ($this->column ?? null);
|
||||
|
|
@ -390,7 +390,7 @@ class VariableBase
|
|||
* @param mixed $value
|
||||
* @return void
|
||||
*/
|
||||
public function filterValue($value)
|
||||
public function filterValue($value): void
|
||||
{
|
||||
// Don't apply a filter if there is no variable.
|
||||
$column = $this instanceof ColumnWrite ? $this->name : $this->column;
|
||||
|
|
@ -465,7 +465,7 @@ class VariableBase
|
|||
* @param string $value
|
||||
* @return array
|
||||
*/
|
||||
protected function _parseSearchKeywords($column, $value)
|
||||
protected function _parseSearchKeywords(string $column, string $value): array
|
||||
{
|
||||
// Initialze the return values.
|
||||
$where = '';
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue