@@ -53,8 +53,7 @@ |
||
| 53 | 53 | * @class AbstractMigration |
| 54 | 54 | * @package Platine\Framework\Migration |
| 55 | 55 | */ |
| 56 | -abstract class AbstractMigration extends Schema |
|
| 57 | -{ |
|
| 56 | +abstract class AbstractMigration extends Schema { |
|
| 58 | 57 | /** |
| 59 | 58 | * Execute when do migrate |
| 60 | 59 | * @return void |
@@ -26,8 +26,8 @@ |
||
| 26 | 26 | protected string $name; |
| 27 | 27 | |
| 28 | 28 | /** |
| 29 | - * {@inheritdoc} |
|
| 30 | - */ |
|
| 29 | + * {@inheritdoc} |
|
| 30 | + */ |
|
| 31 | 31 | public function __construct(string $markup, &$tokens, Parser $parser) |
| 32 | 32 | { |
| 33 | 33 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
@@ -59,8 +59,7 @@ discard block |
||
| 59 | 59 | * @class SessionTag |
| 60 | 60 | * @package Platine\Framework\Template\Tag |
| 61 | 61 | */ |
| 62 | -class SessionTag extends AbstractTag |
|
| 63 | -{ |
|
| 62 | +class SessionTag extends AbstractTag { |
|
| 64 | 63 | /** |
| 65 | 64 | * The key of the session |
| 66 | 65 | * @var string |
@@ -70,8 +69,7 @@ discard block |
||
| 70 | 69 | /** |
| 71 | 70 | * {@inheritdoc} |
| 72 | 71 | */ |
| 73 | - public function __construct(string $markup, &$tokens, Parser $parser) |
|
| 74 | - { |
|
| 72 | + public function __construct(string $markup, &$tokens, Parser $parser) { |
|
| 75 | 73 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
| 76 | 74 | if ($lexer->match($markup)) { |
| 77 | 75 | $this->name = $lexer->getStringMatch(0); |
@@ -27,8 +27,8 @@ |
||
| 27 | 27 | protected string $value; |
| 28 | 28 | |
| 29 | 29 | /** |
| 30 | - * {@inheritdoc} |
|
| 31 | - */ |
|
| 30 | + * {@inheritdoc} |
|
| 31 | + */ |
|
| 32 | 32 | public function __construct(string $markup, &$tokens, Parser $parser) |
| 33 | 33 | { |
| 34 | 34 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
@@ -59,8 +59,7 @@ discard block |
||
| 59 | 59 | * @class LangTag |
| 60 | 60 | * @package Platine\Framework\Template\Tag |
| 61 | 61 | */ |
| 62 | -class LangTag extends AbstractTag |
|
| 63 | -{ |
|
| 62 | +class LangTag extends AbstractTag { |
|
| 64 | 63 | /** |
| 65 | 64 | * Value to debug |
| 66 | 65 | * @var string |
@@ -70,8 +69,7 @@ discard block |
||
| 70 | 69 | /** |
| 71 | 70 | * {@inheritdoc} |
| 72 | 71 | */ |
| 73 | - public function __construct(string $markup, &$tokens, Parser $parser) |
|
| 74 | - { |
|
| 72 | + public function __construct(string $markup, &$tokens, Parser $parser) { |
|
| 75 | 73 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
| 76 | 74 | if ($lexer->match($markup)) { |
| 77 | 75 | $this->value = $lexer->getStringMatch(0); |
@@ -25,8 +25,8 @@ |
||
| 25 | 25 | protected string $path; |
| 26 | 26 | |
| 27 | 27 | /** |
| 28 | - * {@inheritdoc} |
|
| 29 | - */ |
|
| 28 | + * {@inheritdoc} |
|
| 29 | + */ |
|
| 30 | 30 | public function __construct(string $markup, &$tokens, Parser $parser) |
| 31 | 31 | { |
| 32 | 32 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
@@ -59,8 +59,7 @@ discard block |
||
| 59 | 59 | * @class StaticTag |
| 60 | 60 | * @package Platine\Framework\Template\Tag |
| 61 | 61 | */ |
| 62 | -class StaticTag extends AbstractTag |
|
| 63 | -{ |
|
| 62 | +class StaticTag extends AbstractTag { |
|
| 64 | 63 | /** |
| 65 | 64 | * The static path |
| 66 | 65 | * @var string |
@@ -70,8 +69,7 @@ discard block |
||
| 70 | 69 | /** |
| 71 | 70 | * {@inheritdoc} |
| 72 | 71 | */ |
| 73 | - public function __construct(string $markup, &$tokens, Parser $parser) |
|
| 74 | - { |
|
| 72 | + public function __construct(string $markup, &$tokens, Parser $parser) { |
|
| 75 | 73 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
| 76 | 74 | if ($lexer->match($markup)) { |
| 77 | 75 | $this->path = $lexer->getStringMatch(0); |
@@ -26,8 +26,8 @@ |
||
| 26 | 26 | protected string $name; |
| 27 | 27 | |
| 28 | 28 | /** |
| 29 | - * {@inheritdoc} |
|
| 30 | - */ |
|
| 29 | + * {@inheritdoc} |
|
| 30 | + */ |
|
| 31 | 31 | public function __construct(string $markup, &$tokens, Parser $parser) |
| 32 | 32 | { |
| 33 | 33 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
@@ -59,8 +59,7 @@ discard block |
||
| 59 | 59 | * @class SessionFlashTag |
| 60 | 60 | * @package Platine\Framework\Template\Tag |
| 61 | 61 | */ |
| 62 | -class SessionFlashTag extends AbstractTag |
|
| 63 | -{ |
|
| 62 | +class SessionFlashTag extends AbstractTag { |
|
| 64 | 63 | /** |
| 65 | 64 | * The key of the session |
| 66 | 65 | * @var string |
@@ -70,8 +69,7 @@ discard block |
||
| 70 | 69 | /** |
| 71 | 70 | * {@inheritdoc} |
| 72 | 71 | */ |
| 73 | - public function __construct(string $markup, &$tokens, Parser $parser) |
|
| 74 | - { |
|
| 72 | + public function __construct(string $markup, &$tokens, Parser $parser) { |
|
| 75 | 73 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
| 76 | 74 | if ($lexer->match($markup)) { |
| 77 | 75 | $this->name = $lexer->getStringMatch(0); |
@@ -26,8 +26,8 @@ |
||
| 26 | 26 | protected string $name; |
| 27 | 27 | |
| 28 | 28 | /** |
| 29 | - * {@inheritdoc} |
|
| 30 | - */ |
|
| 29 | + * {@inheritdoc} |
|
| 30 | + */ |
|
| 31 | 31 | public function __construct(string $markup, &$tokens, Parser $parser) |
| 32 | 32 | { |
| 33 | 33 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
@@ -59,8 +59,7 @@ discard block |
||
| 59 | 59 | * @class RouteUrlTag |
| 60 | 60 | * @package Platine\Framework\Template\Tag |
| 61 | 61 | */ |
| 62 | -class RouteUrlTag extends AbstractTag |
|
| 63 | -{ |
|
| 62 | +class RouteUrlTag extends AbstractTag { |
|
| 64 | 63 | /** |
| 65 | 64 | * The name of the route |
| 66 | 65 | * @var string |
@@ -70,8 +69,7 @@ discard block |
||
| 70 | 69 | /** |
| 71 | 70 | * {@inheritdoc} |
| 72 | 71 | */ |
| 73 | - public function __construct(string $markup, &$tokens, Parser $parser) |
|
| 74 | - { |
|
| 72 | + public function __construct(string $markup, &$tokens, Parser $parser) { |
|
| 75 | 73 | $lexer = new Lexer('/' . Token::QUOTED_FRAGMENT . '/'); |
| 76 | 74 | if ($lexer->match($markup)) { |
| 77 | 75 | $this->name = $lexer->getStringMatch(0); |
@@ -212,10 +212,10 @@ |
||
| 212 | 212 | return $this; |
| 213 | 213 | } |
| 214 | 214 | |
| 215 | - /** |
|
| 216 | - * Return the application root path |
|
| 217 | - * @return string |
|
| 218 | - */ |
|
| 215 | + /** |
|
| 216 | + * Return the application root path |
|
| 217 | + * @return string |
|
| 218 | + */ |
|
| 219 | 219 | public function getAppPath(): string |
| 220 | 220 | { |
| 221 | 221 | return $this->appPath; |
@@ -65,8 +65,7 @@ discard block |
||
| 65 | 65 | * @class Application |
| 66 | 66 | * @package Platine\Framework\App |
| 67 | 67 | */ |
| 68 | -class Application extends Container |
|
| 69 | -{ |
|
| 68 | +class Application extends Container { |
|
| 70 | 69 | /** |
| 71 | 70 | * The application version |
| 72 | 71 | */ |
@@ -148,8 +147,7 @@ discard block |
||
| 148 | 147 | * Create new instance |
| 149 | 148 | * @param string $basePath |
| 150 | 149 | */ |
| 151 | - public function __construct(string $basePath = '') |
|
| 152 | - { |
|
| 150 | + public function __construct(string $basePath = '') { |
|
| 153 | 151 | parent::__construct(); |
| 154 | 152 | |
| 155 | 153 | $this->basePath = $basePath; |
@@ -244,8 +242,7 @@ discard block |
||
| 244 | 242 | * @param string $env |
| 245 | 243 | * @return $this |
| 246 | 244 | */ |
| 247 | - public function setEnvironment(string $env) |
|
| 248 | - { |
|
| 245 | + public function setEnvironment(string $env) { |
|
| 249 | 246 | $this->env = $env; |
| 250 | 247 | |
| 251 | 248 | return $this; |
@@ -87,7 +87,7 @@ |
||
| 87 | 87 | $config = $app->get(Config::class); |
| 88 | 88 | |
| 89 | 89 | $pagination->setItemsPerPage($config->get('pagination.item_per_page', 10)) |
| 90 | - ->setMaxPages($config->get('pagination.max_pages', 5)); |
|
| 90 | + ->setMaxPages($config->get('pagination.max_pages', 5)); |
|
| 91 | 91 | |
| 92 | 92 | return $pagination; |
| 93 | 93 | }); |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | */ |
| 70 | 70 | public function register(): void |
| 71 | 71 | { |
| 72 | - $this->app->bind(UrlGeneratorInterface::class, function (ContainerInterface $app) { |
|
| 72 | + $this->app->bind(UrlGeneratorInterface::class, function(ContainerInterface $app) { |
|
| 73 | 73 | return new ServerRequestUrlGenerator( |
| 74 | 74 | $app->get(ServerRequestInterface::class), |
| 75 | 75 | 'page' |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | |
| 79 | 79 | $this->app->bind(RendererInterface::class, BootstrapRenderer::class); |
| 80 | 80 | |
| 81 | - $this->app->bind(Pagination::class, function (ContainerInterface $app) { |
|
| 81 | + $this->app->bind(Pagination::class, function(ContainerInterface $app) { |
|
| 82 | 82 | $pagination = new Pagination( |
| 83 | 83 | $app->get(UrlGeneratorInterface::class), |
| 84 | 84 | $app->get(RendererInterface::class) |
@@ -61,8 +61,7 @@ |
||
| 61 | 61 | * @class PaginationServiceProvider |
| 62 | 62 | * @package Platine\Framework\Service\Provider |
| 63 | 63 | */ |
| 64 | -class PaginationServiceProvider extends ServiceProvider |
|
| 65 | -{ |
|
| 64 | +class PaginationServiceProvider extends ServiceProvider { |
|
| 66 | 65 | /** |
| 67 | 66 | * {@inheritdoc} |
| 68 | 67 | */ |
@@ -71,7 +71,7 @@ |
||
| 71 | 71 | 'updated_at' => '?date', |
| 72 | 72 | ]); |
| 73 | 73 | |
| 74 | - $mapper->filter('status', function (Query $q, $status) { |
|
| 74 | + $mapper->filter('status', function(Query $q, $status) { |
|
| 75 | 75 | $q->where('status')->is($status); |
| 76 | 76 | }); |
| 77 | 77 | } |
@@ -57,8 +57,7 @@ discard block |
||
| 57 | 57 | * @package Platine\Framework\Auth\Entity |
| 58 | 58 | * @extends Entity<User> |
| 59 | 59 | */ |
| 60 | -class User extends Entity implements IdentityInterface |
|
| 61 | -{ |
|
| 60 | +class User extends Entity implements IdentityInterface { |
|
| 62 | 61 | /** |
| 63 | 62 | * |
| 64 | 63 | * @param EntityMapperInterface<User> $mapper |
@@ -109,8 +108,7 @@ discard block |
||
| 109 | 108 | /** |
| 110 | 109 | * {@inheritdoc} |
| 111 | 110 | */ |
| 112 | - public function getId() |
|
| 113 | - { |
|
| 111 | + public function getId() { |
|
| 114 | 112 | return $this->mapper()->getColumn('id'); |
| 115 | 113 | } |
| 116 | 114 | |