Implement php 7.4 type hints

This commit is contained in:
Dennis Eichhorn 2019-08-15 21:55:12 +02:00
parent 0566f3b7b1
commit 3bf404fdf4
3 changed files with 8 additions and 8 deletions

View File

@ -66,7 +66,7 @@ class Controller extends ModuleAbstract implements WebInterface
* @var string[] * @var string[]
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $providing = []; protected static array $providing = [];
/** /**
* Dependencies. * Dependencies.
@ -74,5 +74,5 @@ class Controller extends ModuleAbstract implements WebInterface
* @var string[] * @var string[]
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $dependencies = []; protected static array $dependencies = [];
} }

View File

@ -70,7 +70,7 @@ class EditorDoc implements ArrayableInterface, \JsonSerializable
/** /**
* Created. * Created.
* *
* @var \DateTime * @var null|\DateTime
* @since 1.0.0 * @since 1.0.0
*/ */
private $createdAt = null; private $createdAt = null;

View File

@ -26,7 +26,7 @@ final class EditorDocMapper extends DataMapperAbstract
* @var array<string, array<string, bool|string>> * @var array<string, array<string, bool|string>>
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $columns = [ protected static array $columns = [
'editor_doc_id' => ['name' => 'editor_doc_id', 'type' => 'int', 'internal' => 'id'], 'editor_doc_id' => ['name' => 'editor_doc_id', 'type' => 'int', 'internal' => 'id'],
'editor_doc_created_by' => ['name' => 'editor_doc_created_by', 'type' => 'int', 'internal' => 'createdBy'], 'editor_doc_created_by' => ['name' => 'editor_doc_created_by', 'type' => 'int', 'internal' => 'createdBy'],
'editor_doc_title' => ['name' => 'editor_doc_title', 'type' => 'string', 'internal' => 'title'], 'editor_doc_title' => ['name' => 'editor_doc_title', 'type' => 'string', 'internal' => 'title'],
@ -42,7 +42,7 @@ final class EditorDocMapper extends DataMapperAbstract
* @var array<string, array<string, string>> * @var array<string, array<string, string>>
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $belongsTo = [ protected static array $belongsTo = [
'createdBy' => [ 'createdBy' => [
'mapper' => AccountMapper::class, 'mapper' => AccountMapper::class,
'src' => 'editor_doc_created_by', 'src' => 'editor_doc_created_by',
@ -55,7 +55,7 @@ final class EditorDocMapper extends DataMapperAbstract
* @var string * @var string
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $table = 'editor_doc'; protected static string $table = 'editor_doc';
/** /**
* Primary field name. * Primary field name.
@ -63,7 +63,7 @@ final class EditorDocMapper extends DataMapperAbstract
* @var string * @var string
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $primaryField = 'editor_doc_id'; protected static string $primaryField = 'editor_doc_id';
/** /**
* Created at. * Created at.
@ -71,5 +71,5 @@ final class EditorDocMapper extends DataMapperAbstract
* @var string * @var string
* @since 1.0.0 * @since 1.0.0
*/ */
protected static $createdAt = 'editor_doc_created_at'; protected static string $createdAt = 'editor_doc_created_at';
} }