mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-27 07:44:04 +02:00
PhpDoc: Fix incorrect @param
and @return
type hints
This commit is contained in:
parent
8d55385e38
commit
ee9d139a3a
@ -295,7 +295,7 @@ class ResourceConfigForm extends ConfigForm
|
||||
*
|
||||
* @param Form $form
|
||||
*
|
||||
* @return Inspection
|
||||
* @return ?Inspection
|
||||
*/
|
||||
public static function inspectResource(Form $form)
|
||||
{
|
||||
|
@ -321,7 +321,7 @@ abstract class RepositoryForm extends Form
|
||||
/**
|
||||
* Apply the requested mode on the repository
|
||||
*
|
||||
* @return bool
|
||||
* @return ?bool
|
||||
*/
|
||||
public function onSuccess()
|
||||
{
|
||||
|
@ -78,7 +78,6 @@ class Benchmark
|
||||
* you prefer to show either time or memory or both in your output
|
||||
*
|
||||
* @param ?int $what Whether to get time and/or memory summary
|
||||
* @return string
|
||||
*/
|
||||
public static function dump($what = null)
|
||||
{
|
||||
|
@ -260,7 +260,7 @@ class Platform
|
||||
/**
|
||||
* Return the username PHP is running as
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
public static function getPhpUser()
|
||||
{
|
||||
|
@ -98,7 +98,7 @@ class BarGraph extends Styleable implements Drawable
|
||||
* @param array $point The
|
||||
* @param string $fill The fill color to use
|
||||
* @param $strokeWidth
|
||||
* @param null $index
|
||||
* @param ?int $index
|
||||
*
|
||||
* @return Rect
|
||||
*/
|
||||
|
@ -151,7 +151,7 @@ class DateFormatter
|
||||
* @param bool $timeOnly
|
||||
* @param bool $requireTime
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
public static function timeAgo($time, $timeOnly = false, $requireTime = false)
|
||||
{
|
||||
@ -190,7 +190,7 @@ class DateFormatter
|
||||
* @param bool $timeOnly
|
||||
* @param bool $requireTime
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
public static function timeSince($time, $timeOnly = false, $requireTime = false)
|
||||
{
|
||||
@ -228,7 +228,7 @@ class DateFormatter
|
||||
* @param bool $timeOnly
|
||||
* @param bool $requireTime
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
public static function timeUntil($time, $timeOnly = false, $requireTime = false)
|
||||
{
|
||||
|
@ -94,7 +94,7 @@ class Discovery
|
||||
/**
|
||||
* Discover LDAP servers on the given domain
|
||||
*
|
||||
* @param string $domain The object containing the form elements
|
||||
* @param ?string $domain The object containing the form elements
|
||||
*
|
||||
* @return Discovery True when the discovery was successful, false when the configuration was guessed
|
||||
*/
|
||||
|
@ -200,8 +200,6 @@ abstract class IniRepository extends Repository implements Extensible, Updatable
|
||||
*
|
||||
* @param string $table
|
||||
* @param ConfigObject $old
|
||||
*
|
||||
* @return ConfigObject
|
||||
*/
|
||||
public function onDelete($table, ConfigObject $old)
|
||||
{
|
||||
@ -217,7 +215,7 @@ abstract class IniRepository extends Repository implements Extensible, Updatable
|
||||
* @param string $table The table name for which to return a trigger method
|
||||
* @param string $event The name of the event type
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
protected function getTrigger($table, $event)
|
||||
{
|
||||
|
@ -55,7 +55,7 @@ abstract class LdapRepository extends Repository
|
||||
/**
|
||||
* Return the given attribute name normed to known LDAP enviroments, if possible
|
||||
*
|
||||
* @param string $name
|
||||
* @param ?string $name
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
|
@ -783,7 +783,7 @@ abstract class Repository implements Selectable
|
||||
* @param RepositoryQuery $query An optional query to pass as context
|
||||
* (unused by the base implementation)
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*
|
||||
* @throws ProgrammingError In case a conversion rule is found but not any conversion method
|
||||
*/
|
||||
@ -930,7 +930,7 @@ abstract class Repository implements Selectable
|
||||
*
|
||||
* @param string|null $value
|
||||
*
|
||||
* @return int
|
||||
* @return ?int
|
||||
*
|
||||
* @see https://tools.ietf.org/html/rfc4517#section-3.3.13
|
||||
*/
|
||||
|
@ -156,7 +156,7 @@ class Controller extends ModuleActionController
|
||||
/**
|
||||
* Get the page size configured via user preferences or return the default value
|
||||
*
|
||||
* @param int $default
|
||||
* @param ?int $default
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
|
@ -17,7 +17,7 @@ class FormDescriptions extends Zend_Form_Decorator_Abstract
|
||||
*
|
||||
* @param string $content The html rendered so far
|
||||
*
|
||||
* @return string The updated html
|
||||
* @return ?string The updated html
|
||||
*/
|
||||
public function render($content = '')
|
||||
{
|
||||
|
@ -41,7 +41,7 @@ class FormHints extends Zend_Form_Decorator_Abstract
|
||||
*
|
||||
* @param string $content The html rendered so far
|
||||
*
|
||||
* @return string The updated html
|
||||
* @return ?string The updated html
|
||||
*/
|
||||
public function render($content = '')
|
||||
{
|
||||
|
@ -18,7 +18,7 @@ class FormNotifications extends Zend_Form_Decorator_Abstract
|
||||
*
|
||||
* @param string $content The html rendered so far
|
||||
*
|
||||
* @return string The updated html
|
||||
* @return ?string The updated html
|
||||
*/
|
||||
public function render($content = '')
|
||||
{
|
||||
|
@ -72,7 +72,7 @@ class Help extends Zend_Form_Decorator_Abstract
|
||||
*
|
||||
* @param string $content The html rendered so far
|
||||
*
|
||||
* @return string The updated html
|
||||
* @return ?string The updated html
|
||||
*/
|
||||
public function render($content = '')
|
||||
{
|
||||
|
@ -27,7 +27,7 @@ class Spinner extends Zend_Form_Decorator_Abstract
|
||||
*
|
||||
* @param string $content The html rendered so far
|
||||
*
|
||||
* @return string The updated html
|
||||
* @return ?string The updated html
|
||||
*/
|
||||
public function render($content = '')
|
||||
{
|
||||
|
@ -346,7 +346,7 @@ class Navigation implements ArrayAccess, Countable, IteratorAggregate
|
||||
*
|
||||
* @param string $name
|
||||
*
|
||||
* @return NavigationItem
|
||||
* @return ?NavigationItem
|
||||
*/
|
||||
public function findItem($name)
|
||||
{
|
||||
|
@ -243,7 +243,7 @@ class Url
|
||||
*
|
||||
* @param string $url The url to apply the new filter to
|
||||
* @param Filter $filter The base filter
|
||||
* @param Filter $optional The optional filter
|
||||
* @param ?Filter $optional The optional filter
|
||||
*
|
||||
* @return static The altered URL containing the new filter
|
||||
* @throws ProgrammingError
|
||||
|
@ -11,7 +11,7 @@ class IcingawebController extends DocController
|
||||
/**
|
||||
* Get the path to Icinga Web 2's documentation
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*
|
||||
* @throws \Icinga\Exception\Http\HttpNotFoundException If Icinga Web 2's documentation is not available
|
||||
*/
|
||||
|
@ -79,7 +79,7 @@ class SearchController extends DocController
|
||||
/**
|
||||
* Get the path to Icinga Web 2's documentation
|
||||
*
|
||||
* @return string
|
||||
* @return ?string
|
||||
*/
|
||||
protected function getWebPath()
|
||||
{
|
||||
|
@ -223,7 +223,7 @@ class EventController extends Controller
|
||||
*
|
||||
* @param string $eventType
|
||||
*
|
||||
* @return string[]
|
||||
* @return ?string[]
|
||||
*/
|
||||
protected function getIconAndLabel($eventType)
|
||||
{
|
||||
@ -263,7 +263,7 @@ class EventController extends Controller
|
||||
* @param string $type
|
||||
* @param int $id
|
||||
*
|
||||
* @return Queryable
|
||||
* @return ?Queryable
|
||||
*/
|
||||
protected function query($type, $id)
|
||||
{
|
||||
@ -358,7 +358,7 @@ class EventController extends Controller
|
||||
* @param string $type
|
||||
* @param \stdClass $event
|
||||
*
|
||||
* @return string[][]
|
||||
* @return ?string[][]
|
||||
*/
|
||||
protected function getDetails($type, $event)
|
||||
{
|
||||
|
@ -64,8 +64,6 @@ class IcingaApiCommandRenderer implements IcingaCommandRendererInterface
|
||||
*
|
||||
* @param array $data
|
||||
* @param MonitoredObject $object
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
protected function applyFilter(array &$data, MonitoredObject $object)
|
||||
{
|
||||
|
@ -101,7 +101,7 @@ class TimeRange implements Iterator
|
||||
*
|
||||
* @param DateTime $dateTime The date and time for which to search the timeframe
|
||||
* @param bool $asTimestamp Whether the start of the timeframe should be returned as timestamp
|
||||
* @return stdClass|int An object with a ´start´ and ´end´ property or a timestamp
|
||||
* @return stdClass|int|null An object with a ´start´ and ´end´ property or a timestamp
|
||||
*/
|
||||
public function findTimeframe(DateTime $dateTime, $asTimestamp = false)
|
||||
{
|
||||
|
@ -25,7 +25,7 @@ abstract class Step
|
||||
/**
|
||||
* Return a textual summary of all configuration changes made
|
||||
*
|
||||
* @return array
|
||||
* @return ?array
|
||||
*/
|
||||
abstract public function getReport();
|
||||
}
|
||||
|
@ -558,7 +558,7 @@ class DbTool
|
||||
* @param string $username The login name for which to check the privileges,
|
||||
* if NULL the current login is used
|
||||
*
|
||||
* @return bool
|
||||
* @return ?bool
|
||||
*/
|
||||
public function checkPrivileges(array $privileges, array $context = null, $username = null)
|
||||
{
|
||||
@ -574,7 +574,7 @@ class DbTool
|
||||
*
|
||||
* @param array $privileges The privileges that should be grantable
|
||||
*
|
||||
* @return bool
|
||||
* @return ?bool
|
||||
*/
|
||||
public function isGrantable($privileges)
|
||||
{
|
||||
@ -680,7 +680,7 @@ class DbTool
|
||||
*
|
||||
* @param string $username The username to search
|
||||
*
|
||||
* @return bool
|
||||
* @return ?bool
|
||||
*/
|
||||
public function hasLogin($username)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user