| @@ -42,7 +42,7 @@ | ||
| 42 | 42 | trait CommonFileHandlingTrait | 
| 43 | 43 |  { | 
| 44 | 44 | /** | 
| 45 | - * @param $fileName | |
| 45 | + * @param string $fileName | |
| 46 | 46 | * @param MediatorInterface $yem | 
| 47 | 47 | * @param string $mode | 
| 48 | 48 | * | 
| @@ -108,7 +108,7 @@ discard block | ||
| 108 | 108 |          do { | 
| 109 | 109 | $settings = preg_replace_callback( | 
| 110 | 110 | $regEx, | 
| 111 | -                function ($match) use ($settings, $dic) { | |
| 111 | +                function($match) use ($settings, $dic) { | |
| 112 | 112 |                      if (!empty($settings[$match['name']])) { | 
| 113 | 113 | return $settings[$match['name']]; | 
| 114 | 114 | } | 
| @@ -148,7 +148,7 @@ discard block | ||
| 148 | 148 | $rdi->setFlags($flags); | 
| 149 | 149 | /** @noinspection SpellCheckingInspection */ | 
| 150 | 150 | $rcfi = new RecursiveCallbackFilterIterator( | 
| 151 | -            $rdi, function (\SplFileInfo $current, $key, \RecursiveDirectoryIterator $rdi) { | |
| 151 | +            $rdi, function(\SplFileInfo $current, $key, \RecursiveDirectoryIterator $rdi) { | |
| 152 | 152 |              if ($rdi->hasChildren()) { | 
| 153 | 153 | return true; | 
| 154 | 154 | } | 
| @@ -227,12 +227,12 @@ discard block | ||
| 227 | 227 | $dic = $this->dic; | 
| 228 | 228 |          if ('none' !== $dic['Yapeal.Cache.fileSystemMode']) { | 
| 229 | 229 |              if (empty($dic['Yapeal.FileSystem.CachePreserver'])) { | 
| 230 | -                $dic['Yapeal.FileSystem.CachePreserver'] = function () use ($dic) { | |
| 230 | +                $dic['Yapeal.FileSystem.CachePreserver'] = function() use ($dic) { | |
| 231 | 231 | return new $dic['Yapeal.Cache.Handlers.preserve']($dic['Yapeal.Cache.dir']); | 
| 232 | 232 | }; | 
| 233 | 233 | } | 
| 234 | 234 |              if (empty($dic['Yapeal.FileSystem.CacheRetriever'])) { | 
| 235 | -                $dic['Yapeal.FileSystem.CacheRetriever'] = function () use ($dic) { | |
| 235 | +                $dic['Yapeal.FileSystem.CacheRetriever'] = function() use ($dic) { | |
| 236 | 236 | return new $dic['Yapeal.Cache.Handlers.retrieve']($dic['Yapeal.Cache.dir']); | 
| 237 | 237 | }; | 
| 238 | 238 | } | 
| @@ -309,7 +309,7 @@ discard block | ||
| 309 | 309 |          if (!empty($this->dic['Yapeal.Error.Logger'])) { | 
| 310 | 310 | return $this; | 
| 311 | 311 | } | 
| 312 | -        $this->dic['Yapeal.Error.Logger'] = function ($dic) { | |
| 312 | +        $this->dic['Yapeal.Error.Logger'] = function($dic) { | |
| 313 | 313 | /** | 
| 314 | 314 | * @type Logger $logger | 
| 315 | 315 | */ | 
| @@ -374,7 +374,7 @@ discard block | ||
| 374 | 374 | basename($subscriber, '.php') | 
| 375 | 375 | ); | 
| 376 | 376 |                  if (!array_key_exists($service, $dic)) { | 
| 377 | -                    $dic[$service] = function () use ($dic, $service) { | |
| 377 | +                    $dic[$service] = function() use ($dic, $service) { | |
| 378 | 378 |                          $class = '\\' . str_replace('.', '\\', $service); | 
| 379 | 379 | /** | 
| 380 | 380 | * @type \Yapeal\EveApi\EveApiToolsTrait $callable | 
| @@ -392,19 +392,19 @@ discard block | ||
| 392 | 392 | } | 
| 393 | 393 | } | 
| 394 | 394 |          if (empty($dic['Yapeal.EveApi.Creator'])) { | 
| 395 | -            $dic['Yapeal.EveApi.Creator'] = function () use ($dic) { | |
| 395 | +            $dic['Yapeal.EveApi.Creator'] = function() use ($dic) { | |
| 396 | 396 | $loader = new Twig_Loader_Filesystem($dic['Yapeal.EveApi.dir']); | 
| 397 | 397 | $twig = new Twig_Environment( | 
| 398 | 398 | $loader, ['debug' => true, 'strict_variables' => true, 'autoescape' => false] | 
| 399 | 399 | ); | 
| 400 | 400 | $filter = new Twig_SimpleFilter( | 
| 401 | -                    'ucFirst', function ($value) { | |
| 401 | +                    'ucFirst', function($value) { | |
| 402 | 402 | return ucfirst($value); | 
| 403 | 403 | } | 
| 404 | 404 | ); | 
| 405 | 405 | $twig->addFilter($filter); | 
| 406 | 406 | $filter = new Twig_SimpleFilter( | 
| 407 | -                    'lcFirst', function ($value) { | |
| 407 | +                    'lcFirst', function($value) { | |
| 408 | 408 | return lcfirst($value); | 
| 409 | 409 | } | 
| 410 | 410 | ); | 
| @@ -434,20 +434,20 @@ discard block | ||
| 434 | 434 | $dic = $this->dic; | 
| 435 | 435 |          if (empty($dic['Yapeal.Event.EveApiEvent'])) { | 
| 436 | 436 | $dic['Yapeal.Event.EveApi'] = $dic->factory( | 
| 437 | -                function ($dic) { | |
| 437 | +                function($dic) { | |
| 438 | 438 | return new $dic['Yapeal.Event.Factories.eveApi'](); | 
| 439 | 439 | } | 
| 440 | 440 | ); | 
| 441 | 441 | } | 
| 442 | 442 |          if (empty($this->dic['Yapeal.Event.LogEvent'])) { | 
| 443 | 443 | $this->dic['Yapeal.Event.LogEvent'] = $this->dic->factory( | 
| 444 | -                function ($dic) { | |
| 444 | +                function($dic) { | |
| 445 | 445 | return new $dic['Yapeal.Event.Factories.log']; | 
| 446 | 446 | } | 
| 447 | 447 | ); | 
| 448 | 448 | } | 
| 449 | 449 |          if (empty($dic['Yapeal.Event.Mediator'])) { | 
| 450 | -            $dic['Yapeal.Event.Mediator'] = function ($dic) { | |
| 450 | +            $dic['Yapeal.Event.Mediator'] = function($dic) { | |
| 451 | 451 | return new $dic['Yapeal.Event.mediator']($dic); | 
| 452 | 452 | }; | 
| 453 | 453 | } | 
| @@ -460,7 +460,7 @@ discard block | ||
| 460 | 460 |      { | 
| 461 | 461 | $dic = $this->dic; | 
| 462 | 462 |          if (empty($dic['Yapeal.Log.Logger'])) { | 
| 463 | -            $dic['Yapeal.Log.Logger'] = function () use ($dic) { | |
| 463 | +            $dic['Yapeal.Log.Logger'] = function() use ($dic) { | |
| 464 | 464 | $group = []; | 
| 465 | 465 | $lineFormatter = new LineFormatter; | 
| 466 | 466 | $lineFormatter->includeStacktraces(); | 
| @@ -507,7 +507,7 @@ discard block | ||
| 507 | 507 |      { | 
| 508 | 508 | $dic = $this->dic; | 
| 509 | 509 |          if (empty($dic['Yapeal.Network.Client'])) { | 
| 510 | -            $dic['Yapeal.Network.Client'] = function ($dic) { | |
| 510 | +            $dic['Yapeal.Network.Client'] = function($dic) { | |
| 511 | 511 | $appComment = $dic['Yapeal.Network.appComment']; | 
| 512 | 512 | $appName = $dic['Yapeal.Network.appName']; | 
| 513 | 513 | $appVersion = $dic['Yapeal.Network.appVersion']; | 
| @@ -576,7 +576,7 @@ discard block | ||
| 576 | 576 | }; | 
| 577 | 577 | } | 
| 578 | 578 |          if (empty($dic['Yapeal.Network.Retriever'])) { | 
| 579 | -            $dic['Yapeal.Network.Retriever'] = function ($dic) { | |
| 579 | +            $dic['Yapeal.Network.Retriever'] = function($dic) { | |
| 580 | 580 | return new GuzzleNetworkRetriever($dic['Yapeal.Network.Client']); | 
| 581 | 581 | }; | 
| 582 | 582 | } | 
| @@ -599,7 +599,7 @@ discard block | ||
| 599 | 599 |      { | 
| 600 | 600 | $dic = $this->dic; | 
| 601 | 601 |          if (empty($dic['Yapeal.Sql.CommonQueries'])) { | 
| 602 | -            $dic['Yapeal.Sql.CommonQueries'] = function ($dic) { | |
| 602 | +            $dic['Yapeal.Sql.CommonQueries'] = function($dic) { | |
| 603 | 603 | return new $dic['Yapeal.Sql.sharedSql']( | 
| 604 | 604 | $dic['Yapeal.Sql.database'], $dic['Yapeal.Sql.tablePrefix'] | 
| 605 | 605 | ); | 
| @@ -612,7 +612,7 @@ discard block | ||
| 612 | 612 | $mess = 'Unknown platform, was given ' . $dic['Yapeal.Sql.platform']; | 
| 613 | 613 | throw new YapealDatabaseException($mess); | 
| 614 | 614 | } | 
| 615 | -        $dic['Yapeal.Sql.Connection'] = function ($dic) { | |
| 615 | +        $dic['Yapeal.Sql.Connection'] = function($dic) { | |
| 616 | 616 | $dsn = $dic['Yapeal.Sql.platform'] . ':host=' . $dic['Yapeal.Sql.hostName'] . ';charset=utf8'; | 
| 617 | 617 |              if (!empty($dic['Yapeal.Sql.port'])) { | 
| 618 | 618 | $dsn .= ';port=' . $dic['Yapeal.Sql.port']; | 
| @@ -637,19 +637,19 @@ discard block | ||
| 637 | 637 | }; | 
| 638 | 638 |          if (empty($dic['Yapeal.Sql.Creator'])) { | 
| 639 | 639 | $dic['Yapeal.Sql.Creator'] = $dic->factory( | 
| 640 | -                function ($dic) { | |
| 640 | +                function($dic) { | |
| 641 | 641 | $loader = new Twig_Loader_Filesystem($dic['Yapeal.Sql.dir']); | 
| 642 | 642 | $twig = new Twig_Environment( | 
| 643 | 643 | $loader, ['debug' => true, 'strict_variables' => true, 'autoescape' => false] | 
| 644 | 644 | ); | 
| 645 | 645 | $filter = new Twig_SimpleFilter( | 
| 646 | -                        'ucFirst', function ($value) { | |
| 646 | +                        'ucFirst', function($value) { | |
| 647 | 647 | return ucfirst($value); | 
| 648 | 648 | } | 
| 649 | 649 | ); | 
| 650 | 650 | $twig->addFilter($filter); | 
| 651 | 651 | $filter = new Twig_SimpleFilter( | 
| 652 | -                        'lcFirst', function ($value) { | |
| 652 | +                        'lcFirst', function($value) { | |
| 653 | 653 | return lcfirst($value); | 
| 654 | 654 | } | 
| 655 | 655 | ); | 
| @@ -685,7 +685,7 @@ discard block | ||
| 685 | 685 |      { | 
| 686 | 686 |          if (empty($this->dic['Yapeal.Xml.Data'])) { | 
| 687 | 687 | $this->dic['Yapeal.Xml.Data'] = $this->dic->factory( | 
| 688 | -                function ($dic) { | |
| 688 | +                function($dic) { | |
| 689 | 689 | return new $dic['Yapeal.Xml.data'](); | 
| 690 | 690 | } | 
| 691 | 691 | ); | 
| @@ -703,19 +703,19 @@ discard block | ||
| 703 | 703 | $dic = $this->dic; | 
| 704 | 704 |          if (empty($dic['Yapeal.Xsd.Creator'])) { | 
| 705 | 705 | $dic['Yapeal.Xsd.Creator'] = $dic->factory( | 
| 706 | -                function ($dic) { | |
| 706 | +                function($dic) { | |
| 707 | 707 | $loader = new Twig_Loader_Filesystem($dic['Yapeal.Xsd.dir']); | 
| 708 | 708 | $twig = new Twig_Environment( | 
| 709 | 709 | $loader, ['debug' => true, 'strict_variables' => true, 'autoescape' => false] | 
| 710 | 710 | ); | 
| 711 | 711 | $filter = new Twig_SimpleFilter( | 
| 712 | -                        'ucFirst', function ($value) { | |
| 712 | +                        'ucFirst', function($value) { | |
| 713 | 713 | return ucfirst($value); | 
| 714 | 714 | } | 
| 715 | 715 | ); | 
| 716 | 716 | $twig->addFilter($filter); | 
| 717 | 717 | $filter = new Twig_SimpleFilter( | 
| 718 | -                        'lcFirst', function ($value) { | |
| 718 | +                        'lcFirst', function($value) { | |
| 719 | 719 | return lcfirst($value); | 
| 720 | 720 | } | 
| 721 | 721 | ); | 
| @@ -733,7 +733,7 @@ discard block | ||
| 733 | 733 | } | 
| 734 | 734 |          if (empty($dic['Yapeal.Xsd.Validator'])) { | 
| 735 | 735 | $dic['Yapeal.Xsd.Validator'] = $dic->factory( | 
| 736 | -                function ($dic) { | |
| 736 | +                function($dic) { | |
| 737 | 737 | return new $dic['Yapeal.Xsd.validate']($dic['Yapeal.Xsd.dir']); | 
| 738 | 738 | } | 
| 739 | 739 | ); | 
| @@ -763,7 +763,7 @@ discard block | ||
| 763 | 763 | $dic = $this->dic; | 
| 764 | 764 |          if (empty($dic['Yapeal.Xsl.Transformer'])) { | 
| 765 | 765 | $dic['Yapeal.Xsl.Transformer'] = $dic->factory( | 
| 766 | -                function ($dic) { | |
| 766 | +                function($dic) { | |
| 767 | 767 | return new $dic['Yapeal.Xsl.transform']($dic['Yapeal.Xsl.dir']); | 
| 768 | 768 | } | 
| 769 | 769 | ); | 
| @@ -1,36 +1,36 @@ | ||
| 1 | 1 | <?php | 
| 2 | 2 | /** | 
| 3 | - * Contains Logger class. | |
| 4 | - * | |
| 5 | - * PHP version 5.5 | |
| 6 | - * | |
| 7 | - * LICENSE: | |
| 8 | - * This file is part of Yet Another Php Eve Api Library also know as Yapeal | |
| 9 | - * which can be used to access the Eve Online API data and place it into a | |
| 10 | - * database. | |
| 11 | - * Copyright (C) 2015-2016 Michael Cummings | |
| 12 | - * | |
| 13 | - * This program is free software: you can redistribute it and/or modify it | |
| 14 | - * under the terms of the GNU Lesser General Public License as published by the | |
| 15 | - * Free Software Foundation, either version 3 of the License, or (at your | |
| 16 | - * option) any later version. | |
| 17 | - * | |
| 18 | - * This program is distributed in the hope that it will be useful, but WITHOUT | |
| 19 | - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
| 20 | - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License | |
| 21 | - * for more details. | |
| 22 | - * | |
| 23 | - * You should have received a copy of the GNU Lesser General Public License | |
| 24 | - * along with this program. If not, see | |
| 25 | - * <http://www.gnu.org/licenses/>. | |
| 26 | - * | |
| 27 | - * You should be able to find a copy of this license in the LICENSE.md file. A | |
| 28 | - * copy of the GNU GPL should also be available in the GNU-GPL.md file. | |
| 29 | - * | |
| 30 | - * @copyright 2015-2016 Michael Cummings | |
| 31 | - * @license http://www.gnu.org/copyleft/lesser.html GNU LGPL | |
| 32 | - * @author Michael Cummings <[email protected]> | |
| 33 | - */ | |
| 3 | + * Contains Logger class. | |
| 4 | + * | |
| 5 | + * PHP version 5.5 | |
| 6 | + * | |
| 7 | + * LICENSE: | |
| 8 | + * This file is part of Yet Another Php Eve Api Library also know as Yapeal | |
| 9 | + * which can be used to access the Eve Online API data and place it into a | |
| 10 | + * database. | |
| 11 | + * Copyright (C) 2015-2016 Michael Cummings | |
| 12 | + * | |
| 13 | + * This program is free software: you can redistribute it and/or modify it | |
| 14 | + * under the terms of the GNU Lesser General Public License as published by the | |
| 15 | + * Free Software Foundation, either version 3 of the License, or (at your | |
| 16 | + * option) any later version. | |
| 17 | + * | |
| 18 | + * This program is distributed in the hope that it will be useful, but WITHOUT | |
| 19 | + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
| 20 | + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License | |
| 21 | + * for more details. | |
| 22 | + * | |
| 23 | + * You should have received a copy of the GNU Lesser General Public License | |
| 24 | + * along with this program. If not, see | |
| 25 | + * <http://www.gnu.org/licenses/>. | |
| 26 | + * | |
| 27 | + * You should be able to find a copy of this license in the LICENSE.md file. A | |
| 28 | + * copy of the GNU GPL should also be available in the GNU-GPL.md file. | |
| 29 | + * | |
| 30 | + * @copyright 2015-2016 Michael Cummings | |
| 31 | + * @license http://www.gnu.org/copyleft/lesser.html GNU LGPL | |
| 32 | + * @author Michael Cummings <[email protected]> | |
| 33 | + */ | |
| 34 | 34 | namespace Yapeal\Log; | 
| 35 | 35 | |
| 36 | 36 | use Monolog\Logger as MLogger; |