Skip to content

Commit 96ba7d3

Browse files
committed
Update
1 parent a0bd00d commit 96ba7d3

16 files changed

+144
-114
lines changed

src/AbstractAuthController.php

+8-7
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,21 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

1719
use FloatPHP\Interfaces\Kernel\AuthenticationInterface;
18-
Use FloatPHP\Classes\Security\Password;
19-
use FloatPHP\Classes\Http\Session;
20-
use FloatPHP\Classes\Http\Request;
21-
use FloatPHP\Classes\Filesystem\Arrayify;
20+
use FloatPHP\Classes\{
21+
Security\Password, Http\Session, Http\Request, Filesystem\Arrayify
22+
};
2223

2324
abstract class AbstractAuthController extends BaseController
2425
{

src/ApiController.php

+8-6
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,20 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

17-
use FloatPHP\Classes\Http\Server;
18-
use FloatPHP\Classes\Filesystem\Stringify;
19-
use FloatPHP\Classes\Security\Encryption;
19+
use FloatPHP\Classes\{
20+
Http\Server, Security\Encryption, Filesystem\Stringify
21+
};
2022

2123
class ApiController extends BaseController
2224
{

src/BackendController.php

+8-5
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,20 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

17-
use FloatPHP\Classes\Http\Session;
18-
use FloatPHP\Classes\Http\Cookie;
19+
use FloatPHP\Classes\{
20+
Http\Session, Http\Cookie
21+
};
1922
use FloatPHP\Helpers\Framework\Permission;
2023

2124
class BackendController extends BaseController

src/Base.php

+12-14
Original file line numberDiff line numberDiff line change
@@ -5,28 +5,26 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

1515
declare(strict_types=1);
1616

1717
namespace FloatPHP\Kernel;
1818

19-
use FloatPHP\Helpers\Filesystem\Cache;
20-
use FloatPHP\Helpers\Filesystem\Transient;
21-
use FloatPHP\Classes\Filesystem\Arrayify;
22-
use FloatPHP\Classes\Filesystem\Stringify;
23-
use FloatPHP\Classes\Filesystem\Translation;
24-
use FloatPHP\Classes\Html\Hook;
25-
use FloatPHP\Classes\Html\Shortcode;
26-
use FloatPHP\Classes\Http\Session;
27-
use FloatPHP\Classes\Http\Server;
28-
use FloatPHP\Classes\Http\Request;
29-
use FloatPHP\Classes\Security\Tokenizer;
19+
use FloatPHP\Classes\{
20+
Filesystem\Arrayify, Filesystem\Stringify, Filesystem\Translation,
21+
Html\Hook, Html\Shortcode,
22+
Http\Session, Http\Server, Http\Request,
23+
Security\Tokenizer
24+
};
25+
use FloatPHP\Helpers\Filesystem\{
26+
Cache, Transient
27+
};
3028

3129
class Base
3230
{

src/BaseController.php

+9-8
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,22 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

19+
use FloatPHP\Classes\{
20+
Filesystem\Stringify,
21+
Http\Session, Http\Server, Http\Request, Http\Response
22+
};
1723
use FloatPHP\Helpers\Filesystem\Transient;
18-
use FloatPHP\Classes\Http\Server;
19-
use FloatPHP\Classes\Http\Request;
20-
use FloatPHP\Classes\Http\Response;
21-
use FloatPHP\Classes\Http\Session;
22-
use FloatPHP\Classes\Filesystem\Stringify;
2324

2425
class BaseController extends View
2526
{

src/Core.php

+9-6
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,21 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

17-
use FloatPHP\Classes\Http\Session;
18-
use FloatPHP\Classes\Http\Router;
19-
use FloatPHP\Classes\Server\Date;
19+
use FloatPHP\Classes\{
20+
Http\Session, Http\Router,
21+
Server\Date
22+
};
2023
use FloatPHP\Helpers\Framework\Configurator;
2124

2225
final class Core

src/ErrorController.php

+5-3
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

1719
use FloatPHP\Classes\Http\Response;

src/FrontController.php

+5-3
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

1719
class FrontController extends BaseController {}

src/Middleware.php

+20-18
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,21 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

17-
use FloatPHP\Classes\Http\Response;
18-
use FloatPHP\Classes\Filesystem\TypeCheck;
19-
use FloatPHP\Classes\Filesystem\Stringify;
20-
use FloatPHP\Classes\Filesystem\Arrayify;
19+
use FloatPHP\Classes\{
20+
Filesystem\TypeCheck, Filesystem\Stringify, Filesystem\Arrayify,
21+
Http\Response
22+
};
2123
use FloatPHP\Interfaces\Classes\RouterInterface;
2224

2325
final class Middleware
@@ -30,32 +32,32 @@ final class Middleware
3032
private $match;
3133

3234
/**
33-
* Middleware system
34-
* $router->addMatchTypes(['name'=>'regex']);
35+
* Middleware system.
3536
*
3637
* @param RouterInterface $router
38+
* @see $router->addMatchTypes(['name'=>'regex']);
3739
*/
3840
public function __construct(RouterInterface $router)
3941
{
4042
// Init configuration
4143
$this->initConfig();
4244

43-
// prepare router from config
45+
// Prepare router from config
4446
$router->setBasePath($this->getBaseRoute());
4547

46-
// set global router
48+
// Set global router
4749
$router->addRoutes($this->getRoutes());
4850

49-
// set modules router
51+
// Set modules router
5052
$module = new Module();
5153
$router->addRoutes($module->getModulesRoutes());
5254

53-
// match request
55+
// Match request
5456
$this->match = $router->match();
5557
}
5658

5759
/**
58-
* Dispatch request & provide response
60+
* Dispatch request & provide response.
5961
*
6062
* @access public
6163
* @param void
@@ -82,7 +84,7 @@ public function dispatch()
8284
}
8385

8486
/**
85-
* If controller is a function
87+
* Whether controller is a function.
8688
*
8789
* @access private
8890
* @param void
@@ -97,7 +99,7 @@ private function isCallable() : bool
9799
}
98100

99101
/**
100-
* If controller is a class
102+
* Whether controller is a class.
101103
*
102104
* @access private
103105
* @param void
@@ -112,7 +114,7 @@ private function isClassMethod() : bool
112114
}
113115

114116
/**
115-
* Execute callable
117+
* Execute callable.
116118
*
117119
* @access private
118120
* @param void
@@ -486,7 +488,7 @@ private function parsePermissions()
486488
}
487489

488490
/**
489-
* Parse request var
491+
* Parse request var.
490492
*
491493
* @access private
492494
* @param void

src/Model.php

+5-3
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

1719
class Model extends Orm

src/Module.php

+11-7
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,23 @@
55
* @subpackage : Kernel Component
66
* @version : 1.0.0
77
* @category : PHP framework
8-
* @copyright : (c) 2017 - 2021 JIHAD SINNAOUR <[email protected]>
8+
* @copyright : (c) 2017 - 2022 Jihad Sinnaour <[email protected]>
99
* @link : https://www.floatphp.com
10-
* @license : MIT License
10+
* @license : MIT
1111
*
12-
* This file if a part of FloatPHP Framework
12+
* This file if a part of FloatPHP Framework.
1313
*/
1414

15+
declare(strict_types=1);
16+
1517
namespace FloatPHP\Kernel;
1618

17-
use FloatPHP\Classes\Filesystem\File;
18-
use FloatPHP\Classes\Filesystem\Json;
19-
use FloatPHP\Helpers\Framework\Configurator;
20-
use FloatPHP\Helpers\Framework\Validator;
19+
use FloatPHP\Classes\Filesystem\{
20+
File, Json
21+
};
22+
use FloatPHP\Helpers\Framework\{
23+
Configurator, Validator
24+
};
2125

2226
class Module extends BaseController
2327
{

0 commit comments

Comments
 (0)