N°3526 - Clean up pass on UIBlocks

- Move UIBlock::ENUM_BLOCK_FILES_TYPE_XXX to iUIBlock
- Add PHPDoc
- Remove Object return type hint on overloadable methods
- Add scalar return type hint
- Add type hint on parameters
This commit is contained in:
Molkobain
2021-11-14 21:22:04 +01:00
parent a9b30e160f
commit 3598da8808
45 changed files with 353 additions and 257 deletions

View File

@@ -32,9 +32,9 @@ class MedallionIcon extends UIBlock
*
* @param string $sImageUrl
* @param string $sIconClass
* @param null $sId
* @param string|null $sId
*/
public function __construct($sImageUrl = '', $sIconClass = '', $sId = null)
public function __construct(string $sImageUrl = '', string $sIconClass = '', ?string $sId = null)
{
parent::__construct($sId);
$this->sImageUrl = $sImageUrl;
@@ -44,7 +44,7 @@ class MedallionIcon extends UIBlock
/**
* @return string
*/
public function GetImageUrl()
public function GetImageUrl(): string
{
return $this->sImageUrl;
}
@@ -63,7 +63,7 @@ class MedallionIcon extends UIBlock
/**
* @return string
*/
public function GetIconClass()
public function GetIconClass(): string
{
return $this->sIconClass;
}