From e93cac5ff1f0e38b2f9f5be3304d10b4cdddfaae Mon Sep 17 00:00:00 2001 From: Alorel Date: Sat, 24 Oct 2015 11:47:02 +0100 Subject: [PATCH] docs bootstrapped --- apigen.neon | 2 + coverage/AbstractHandler.php.html | 206 +-- coverage/Config/AbstractConfig.php.html | 2 +- coverage/Config/ErrorConfig.php.html | 102 +- coverage/Config/ExceptionConfig.php.html | 5 +- coverage/Config/dashboard.html | 5 +- coverage/Config/index.html | 5 +- coverage/Error.php.html | 5 +- coverage/ErrorHandler.php.html | 5 +- coverage/ExceptionHandler.php.html | 5 +- coverage/Output/ConsoleOutput.php.html | 5 +- coverage/Output/Dump.php.html | 5 +- coverage/Output/OutputFormatter.php.html | 191 +-- coverage/Output/Styles/AbstractStyle.php.html | 79 +- coverage/Output/Styles/Error.php.html | 41 +- coverage/Output/Styles/Info.php.html | 41 +- coverage/Output/Styles/Warning.php.html | 41 +- coverage/Output/Styles/dashboard.html | 5 +- coverage/Output/Styles/index.html | 5 +- coverage/Output/dashboard.html | 5 +- coverage/Output/index.html | 5 +- coverage/ShutdownHandler.php.html | 700 ++--------- coverage/dashboard.html | 89 +- coverage/index.html | 100 +- docs/404.html | 156 +-- docs/annotation-group-deprecated.html | 150 +-- docs/annotation-group-todo.html | 150 +-- ...AloFramework.Handlers.AbstractHandler.html | 622 ++++----- ...mework.Handlers.Config.AbstractConfig.html | 806 ++++++------ ...Framework.Handlers.Config.ErrorConfig.html | 434 +++---- ...ework.Handlers.Config.ExceptionConfig.html | 434 +++---- docs/class-AloFramework.Handlers.Error.html | 1015 ++++++++------- ...ss-AloFramework.Handlers.ErrorHandler.html | 1009 ++++++++------- ...loFramework.Handlers.ExceptionHandler.html | 953 +++++++------- ...amework.Handlers.Output.ConsoleOutput.html | 289 +++-- ...ass-AloFramework.Handlers.Output.Dump.html | 226 ++-- ...ework.Handlers.Output.OutputFormatter.html | 218 ++-- ....Handlers.Output.Styles.AbstractStyle.html | 658 +++++----- ...ramework.Handlers.Output.Styles.Error.html | 267 ++-- ...Framework.Handlers.Output.Styles.Info.html | 267 ++-- ...mework.Handlers.Output.Styles.Warning.html | 267 ++-- ...AloFramework.Handlers.ShutdownHandler.html | 533 ++++---- docs/class-ArrayAccess.html | 331 +++-- docs/class-ArrayObject.html | 1110 ++++++++--------- docs/class-Countable.html | 220 ++-- docs/class-Exception.html | 723 ++++++----- docs/class-IteratorAggregate.html | 222 ++-- docs/class-Serializable.html | 257 ++-- docs/class-Traversable.html | 185 ++- docs/index.html | 198 +-- ...amespace-AloFramework.Handlers.Config.html | 164 +-- ...e-AloFramework.Handlers.Output.Styles.html | 164 +-- ...amespace-AloFramework.Handlers.Output.html | 178 +-- docs/namespace-AloFramework.Handlers.html | 184 +-- docs/namespace-AloFramework.html | 169 +-- docs/namespace-PHP.html | 180 +-- docs/resources/bootstrap.min.css | 5 + docs/resources/collapsed.png | Bin 238 -> 249 bytes docs/resources/combined.js | 52 +- docs/resources/footer.png | Bin 7948 -> 0 bytes docs/resources/resize.png | Bin 216 -> 121 bytes docs/resources/style.css | 404 +++--- docs/tree.html | 160 +-- 63 files changed, 6863 insertions(+), 8151 deletions(-) create mode 100644 docs/resources/bootstrap.min.css delete mode 100644 docs/resources/footer.png diff --git a/apigen.neon b/apigen.neon index 04eab50..accb28a 100644 --- a/apigen.neon +++ b/apigen.neon @@ -7,6 +7,8 @@ extensions: [php] # Character set of source files charset: [utf-8] +templateTheme: bootstrap + # Title of generated documentation title: 'AloFramework Handlers 2.0 API' # Grouping of classes diff --git a/coverage/AbstractHandler.php.html b/coverage/AbstractHandler.php.html index a3d949a..2b2788d 100644 --- a/coverage/AbstractHandler.php.html +++ b/coverage/AbstractHandler.php.html @@ -336,102 +336,16 @@
63
         * @since  1.4 $cfg added. This will become the first parameter in the constructor in 2.0
64
         */
65
        function __construct(LoggerInterface $logger = null, AbstractConfig $cfg = null) { - - -
66
- -             if (!$logger) { - - - -
67
- -                 $logger = new Log(); - - - -
68
- -             } - +
66
            if (!$logger) { +
67
                $logger = new Log(); +
68
            }
69
- - -
70
- -             $this->config = Alo::ifnull($cfg, new AbstractConfig()); - - - -
71
- -             $this->logger = $logger; - - - -
72
- -             $this->isCLI  = !$this->config->forceHTML && Alo::isCliRequest(); - +
70
            $this->config = Alo::ifnull($cfg, new AbstractConfig()); +
71
            $this->logger = $logger; +
72
            $this->isCLI  = !$this->config->forceHTML && Alo::isCliRequest();
73
- - -
74
- -             $this->initSymfony(); - - - -
75
- -         } - +
74
            $this->initSymfony(); +
75
        }
76
77
        /**
78
         * Initialises Symfony's components @@ -439,49 +353,11 @@
80
         * @return self
81
         */
82
        private function initSymfony() { - - -
83
- -             if ($this->isCLI) { - - - -
84
- -                 $this->console = new ConsoleOutput(); - - - -
85
- -             } - +
83
            if ($this->isCLI) { +
84
                $this->console = new ConsoleOutput(); +
85
            }
86
- - -
87
- -             return $this; - +
87
            return $this;
88
        }
89
90
        /** @@ -490,56 +366,9 @@
93
         * @return string
94
         */
95
        function __toString() { - - -
96
- -             return 'CSS injected: ' . (self::$cssInjected ? 'Yes' : 'No') . self::EOL . 'Logger: ' . - - - -
97
- -                    ($this->logger ? get_class($this->logger) : 'Not set') . self::EOL . 'Max stack trace size: ' . - - - -
98
- -                    ($this->config->traceDepth); - +
96
            return 'CSS injected: ' . (self::$cssInjected ? 'Yes' : 'No') . self::EOL . 'Logger: ' . +
97
                   ($this->logger ? get_class($this->logger) : 'Not set') . self::EOL . 'Max stack trace size: ' . +
98
                   ($this->config->traceDepth);
99
        }
100
101
        /** @@ -715,10 +544,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Config/AbstractConfig.php.html b/coverage/Config/AbstractConfig.php.html index 55b1bc8..737af2a 100644 --- a/coverage/Config/AbstractConfig.php.html +++ b/coverage/Config/AbstractConfig.php.html @@ -259,7 +259,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:36:16 BST 2015. + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Config/ErrorConfig.php.html b/coverage/Config/ErrorConfig.php.html index 111bd23..b7fd886 100644 --- a/coverage/Config/ErrorConfig.php.html +++ b/coverage/Config/ErrorConfig.php.html @@ -184,101 +184,20 @@
36
         * @param array $cfg Default configuration overrides
37
         */
38
        function __construct(array $cfg = []) { - - -
39
- -             self::setDefaultConfig(); - - - -
40
- -             parent::__construct(self::$defaults, $cfg); - - - -
41
- -         } - +
39
            self::setDefaultConfig(); +
40
            parent::__construct(self::$defaults, $cfg); +
41
        }
42
43
        /**
44
         * Sets the default configuration
45
         * @author Art <a.molcanovas@gmail.com>
46
         */
47
        private static function setDefaultConfig() { - - -
48
- -             if (!self::$defaults) { - - - -
49
- -                 self::$defaults = [self::CFG_ERROR_LEVEL        => error_reporting(), - - - -
50
- -                                    self::CFG_LOG_ERROR_LOCATION => true]; - - - -
51
- -             } - - - -
52
- -         } - +
48
            if (!self::$defaults) { +
49
                self::$defaults = [self::CFG_ERROR_LEVEL        => error_reporting(), +
50
                                   self::CFG_LOG_ERROR_LOCATION => true]; +
51
            } +
52
        }
53
    } @@ -292,10 +211,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Config/ExceptionConfig.php.html b/coverage/Config/ExceptionConfig.php.html index 4f53f4a..873884b 100644 --- a/coverage/Config/ExceptionConfig.php.html +++ b/coverage/Config/ExceptionConfig.php.html @@ -211,10 +211,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Config/dashboard.html b/coverage/Config/dashboard.html index cc0caa5..681a5f2 100644 --- a/coverage/Config/dashboard.html +++ b/coverage/Config/dashboard.html @@ -137,10 +137,7 @@

Project Risks

diff --git a/coverage/Config/index.html b/coverage/Config/index.html index df3aa41..c56cf2c 100644 --- a/coverage/Config/index.html +++ b/coverage/Config/index.html @@ -165,10 +165,7 @@

Legend

High: 90% to 100%

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Error.php.html b/coverage/Error.php.html index d5d0d4e..0149fd7 100644 --- a/coverage/Error.php.html +++ b/coverage/Error.php.html @@ -500,10 +500,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/ErrorHandler.php.html b/coverage/ErrorHandler.php.html index cb6cf8f..d58de99 100644 --- a/coverage/ErrorHandler.php.html +++ b/coverage/ErrorHandler.php.html @@ -628,10 +628,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/ExceptionHandler.php.html b/coverage/ExceptionHandler.php.html index 87e0115..3f0774d 100644 --- a/coverage/ExceptionHandler.php.html +++ b/coverage/ExceptionHandler.php.html @@ -590,10 +590,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/ConsoleOutput.php.html b/coverage/Output/ConsoleOutput.php.html index 6d11eba..28a5c47 100644 --- a/coverage/Output/ConsoleOutput.php.html +++ b/coverage/Output/ConsoleOutput.php.html @@ -193,10 +193,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Dump.php.html b/coverage/Output/Dump.php.html index d83cb94..7171670 100644 --- a/coverage/Output/Dump.php.html +++ b/coverage/Output/Dump.php.html @@ -165,10 +165,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/OutputFormatter.php.html b/coverage/Output/OutputFormatter.php.html index a95e8ac..0100179 100644 --- a/coverage/Output/OutputFormatter.php.html +++ b/coverage/Output/OutputFormatter.php.html @@ -184,185 +184,29 @@
36
         * @author Art <a.molcanovas@gmail.com>
37
         */
38
        function __construct() { - - -
39
- -             parent::__construct(); - - - -
40
- -             self::initStyles(); - +
39
            parent::__construct(); +
40
            self::initStyles();
41
- - -
42
- -             foreach (self::$styles as $code => $class) { - - - -
43
- -                 $this->setStyle($code, $class); - - - -
44
- -             } - - - -
45
- -         } - +
42
            foreach (self::$styles as $code => $class) { +
43
                $this->setStyle($code, $class); +
44
            } +
45
        }
46
47
        /**
48
         * Initialises the style objects
49
         * @author Art <a.molcanovas@gmail.com>
50
         */
51
        private static function initStyles() { - - -
52
- -             if (empty(self::$styles)) { - - - -
53
- -                 foreach (self::$styleColours as $colourCode => $class) { - - - -
54
- -                     self::$styles[$colourCode] = new $class(); - +
52
            if (empty(self::$styles)) { +
53
                foreach (self::$styleColours as $colourCode => $class) { +
54
                    self::$styles[$colourCode] = new $class();
55
- - -
56
- -                     foreach (self::$styleVariants as $varCode => $var) { - - - -
57
- -                         self::$styles[$colourCode . $varCode] = new $class($var); - - - -
58
- -                     } - - - -
59
- -                 } - - - -
60
- -             } - - - -
61
- -         } - +
56
                    foreach (self::$styleVariants as $varCode => $var) { +
57
                        self::$styles[$colourCode . $varCode] = new $class($var); +
58
                    } +
59
                } +
60
            } +
61
        }
62
    } @@ -376,10 +220,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Styles/AbstractStyle.php.html b/coverage/Output/Styles/AbstractStyle.php.html index e9d16eb..9c2fe3e 100644 --- a/coverage/Output/Styles/AbstractStyle.php.html +++ b/coverage/Output/Styles/AbstractStyle.php.html @@ -286,57 +286,11 @@
32
         * @param string|array $setOption Optionally set a formatter style option or array of options
33
         */
34
        function __construct($setOption = null) { - - -
35
- -             $this->symfony = new OutputFormatterStyle(); - - - -
36
- -             $this->cfg     = new AbstractConfig(); - - - -
37
- -             $this->setBackground($this->cfg->bgCli); - +
35
            $this->symfony = new OutputFormatterStyle(); +
36
            $this->cfg     = new AbstractConfig(); +
37
            $this->setBackground($this->cfg->bgCli);
38
- - -
39
- -             if ($setOption) { - +
39
            if ($setOption) {
40
                // nothing to test
41
                // @codeCoverageIgnoreStart
42
                if (is_array($setOption)) { @@ -345,24 +299,8 @@
45
                    $this->setOption($setOption);
46
                }
47
                // @codeCoverageIgnoreEnd - - -
48
- -             } - - - -
49
- -         } - +
48
            } +
49
        }
50
51
        /**
52
         * Sets the background colour @@ -450,10 +388,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Styles/Error.php.html b/coverage/Output/Styles/Error.php.html index 5419cbe..edc485f 100644 --- a/coverage/Output/Styles/Error.php.html +++ b/coverage/Output/Styles/Error.php.html @@ -143,39 +143,9 @@
15
         * @param string|array $setOption Optionally set a formatter style option or array of options
16
         */
17
        function __construct($setOption = null) { - - -
18
- -             parent::__construct($setOption); - - - -
19
- -             $this->setForeground($this->cfg->fgErr); - - - -
20
- -         } - +
18
            parent::__construct($setOption); +
19
            $this->setForeground($this->cfg->fgErr); +
20
        }
21
    } @@ -189,10 +159,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Styles/Info.php.html b/coverage/Output/Styles/Info.php.html index 59f76a8..596f03d 100644 --- a/coverage/Output/Styles/Info.php.html +++ b/coverage/Output/Styles/Info.php.html @@ -143,39 +143,9 @@
15
         * @param string|array $setOption Optionally set a formatter style option or array of options
16
         */
17
        function __construct($setOption = null) { - - -
18
- -             parent::__construct($setOption); - - - -
19
- -             $this->setForeground($this->cfg->fgInfo); - - - -
20
- -         } - +
18
            parent::__construct($setOption); +
19
            $this->setForeground($this->cfg->fgInfo); +
20
        }
21
    } @@ -189,10 +159,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Styles/Warning.php.html b/coverage/Output/Styles/Warning.php.html index f8f8500..d9ddbdb 100644 --- a/coverage/Output/Styles/Warning.php.html +++ b/coverage/Output/Styles/Warning.php.html @@ -143,39 +143,9 @@
15
         * @param string|array $setOption Optionally set a formatter style option or array of options
16
         */
17
        function __construct($setOption = null) { - - -
18
- -             parent::__construct($setOption); - - - -
19
- -             $this->setForeground($this->cfg->fgWarn); - - - -
20
- -         } - +
18
            parent::__construct($setOption); +
19
            $this->setForeground($this->cfg->fgWarn); +
20
        }
21
    } @@ -189,10 +159,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/Styles/dashboard.html b/coverage/Output/Styles/dashboard.html index f307360..966153e 100644 --- a/coverage/Output/Styles/dashboard.html +++ b/coverage/Output/Styles/dashboard.html @@ -138,10 +138,7 @@

Project Risks

diff --git a/coverage/Output/Styles/index.html b/coverage/Output/Styles/index.html index 2f9321f..6c3a0f1 100644 --- a/coverage/Output/Styles/index.html +++ b/coverage/Output/Styles/index.html @@ -194,10 +194,7 @@

Legend

High: 90% to 100%

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/Output/dashboard.html b/coverage/Output/dashboard.html index 2965fce..a9ef4cb 100644 --- a/coverage/Output/dashboard.html +++ b/coverage/Output/dashboard.html @@ -137,10 +137,7 @@

Project Risks

diff --git a/coverage/Output/index.html b/coverage/Output/index.html index c78ca2f..59b075a 100644 --- a/coverage/Output/index.html +++ b/coverage/Output/index.html @@ -193,10 +193,7 @@

Legend

High: 90% to 100%

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/ShutdownHandler.php.html b/coverage/ShutdownHandler.php.html index c850084..4aebccd 100644 --- a/coverage/ShutdownHandler.php.html +++ b/coverage/ShutdownHandler.php.html @@ -41,264 +41,166 @@ - Total - -
-
- 100.00% covered (success) + Total +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+
+
+ 100.00% covered (success)
- -
100.00%
- - -
4 / 4
- - CRAP - -
-
- 100.00% covered (success) +
100.00%
+
4 / 4
+ CRAP +
+
+ 100.00% covered (success)
- -
100.00%
- - -
9 / 9
- +
100.00%
+
9 / 9
- ShutdownHandler - -
-
- 100.00% covered (success) + ShutdownHandler +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+
+
+ 100.00% covered (success)
- -
100.00%
- - -
5 / 5
- - 12 - -
-
- 100.00% covered (success) +
100.00%
+
5 / 5
+ 12 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
9 / 9
- +
100.00%
+
9 / 9
-  isRegistered - -
-
- 100.00% covered (success) +  isRegistered +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - 1 - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- +
100.00%
+
1 / 1
-  getLastRegisteredHandler - - -
-
- 100.00% covered (success) +  getLastRegisteredHandler +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - 1 - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- +
100.00%
+
1 / 1
-  register - -
-
- 100.00% covered (success) +  register +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - 1 - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
6 / 6
- +
100.00%
+
6 / 6
-  handle - -
-
- 100.00% covered (success) +  handle +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - 8 - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+ 8 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
0 / 0
- +
100.00%
+
0 / 0
-  __toString - -
-
- 100.00% covered (success) +  __toString +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- - 1 - -
-
- 100.00% covered (success) +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- +
100.00%
+
1 / 1
@@ -343,23 +245,8 @@          * @return bool          */         static function isRegistered() { - - - - -             return self::$registered; - - - - - -         } - +             return self::$registered; +         }         /**          * Returns the last registered handler @@ -368,24 +255,8 @@          * @since  1.3          */         static function getLastRegisteredHandler() { - - - - -             return self::$lastRegisteredHandler; - - - - - -         } - +             return self::$lastRegisteredHandler; +         }         /**          * Registers the shutdown handler @@ -398,348 +269,50 @@          * @return self          */         static function register(LoggerInterface $logger = null, $cfg = null) { - - - - -             self::$registered = true; - - - - - -             $class            = get_called_class(); - - - - - -             $handler          = new $class($logger, $cfg); - +             self::$registered = true; +             $class            = get_called_class(); +             $handler          = new $class($logger, $cfg); - - - - -             register_shutdown_function([$handler, 'handle']); - - - - - -             self::$lastRegisteredHandler = &$handler; - +             register_shutdown_function([$handler, 'handle']); +             self::$lastRegisteredHandler = &$handler; - - - - -             return $handler; - - - - - -         } - +             return $handler; +         }         /**          * The shutdown handler          *          * @author Art <a.molcanovas@gmail.com>          * @since  1.2.1 Should now report fatal errors if no errors had been raised beforehand. - - - - -          * @codeCoverageIgnore - - - - - - -          */ - - - - - -         function handle() { - - - - - -             if (ErrorHandler::isRegistered()) { - - - - - -                 $e = new Error(error_get_last()); - - - - - - - - - - - -                 if (Error::shouldBeReported($e->getType())) { - - - - - -                     $r = ErrorHandler::getLastReportedError(); - - - - - -                     $h = ErrorHandler::getLastRegisteredHandler(); - - - - - - - - - - - -                     if (!$e->isEmpty() && $h && ($r ? !$r->isEmpty() && !$r->equals($e) : true)) { - - - - - -                         $h->handle($e->getType(), - - - - - -                                    Alo::ifnull($e->getMessage(), '<<unknown error>>'), - - - - - -                                    Alo::ifnull($e->getFile(), '<<unknown file>>'), - - - - - -                                    Alo::ifnull($e->getLine(), '<<unknown line>>')); - - - - - -                     } - - - - - -                 } - - - - - -             } - - - - - -         } - - - - - - - - - - - -         /** - - - - - -          * Returns a string representation of the object - - - - - - -          * @author Art <a.molcanovas@gmail.com> - - - - - - -          * @return string - - - - - - -          */ - - - - - -         function __toString() { - - - - - -             return parent::__toString() . self::EOL . 'Registered: Yes'; - - - - - -         } - - - - - -     } - +          * @codeCoverageIgnore +          */ +         function handle() { +             if (ErrorHandler::isRegistered()) { +                 $e = new Error(error_get_last()); + +                 if (Error::shouldBeReported($e->getType())) { +                     $r = ErrorHandler::getLastReportedError(); +                     $h = ErrorHandler::getLastRegisteredHandler(); + +                     if (!$e->isEmpty() && $h && ($r ? !$r->isEmpty() && !$r->equals($e) : true)) { +                         $h->handle($e->getType(), +                                    Alo::ifnull($e->getMessage(), '<<unknown error>>'), +                                    Alo::ifnull($e->getFile(), '<<unknown file>>'), +                                    Alo::ifnull($e->getLine(), '<<unknown line>>')); +                     } +                 } +             } +         } + +         /** +          * Returns a string representation of the object +          * @author Art <a.molcanovas@gmail.com> +          * @return string +          */ +         function __toString() { +             return parent::__toString() . self::EOL . 'Registered: Yes'; +         } +     } @@ -752,10 +325,7 @@

Legend

Dead Code

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/coverage/dashboard.html b/coverage/dashboard.html index e8f5697..9edf7c8 100644 --- a/coverage/dashboard.html +++ b/coverage/dashboard.html @@ -136,10 +136,7 @@

Project Risks

@@ -160,7 +157,7 @@

Project Risks

.yAxis.tickFormat(d3.format('d')); d3.select('#classCoverageDistribution svg') - .datum(getCoverageDistributionData([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14], "Class Coverage")) + .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,0,0,0,14], "Class Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -178,7 +175,7 @@

Project Risks

.yAxis.tickFormat(d3.format('d')); d3.select('#methodCoverageDistribution svg') - .datum(getCoverageDistributionData([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 56], "Method Coverage")) + .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,0,0,0,56], "Method Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -228,20 +225,7 @@

Project Risks

chart.yAxis.axisLabel('Cyclomatic Complexity'); d3.select('#classComplexity svg') - .datum(getComplexityData([[100, 34, "AbstractHandler<\/a>"], - [100, 3, "AbstractConfig<\/a>"], - [100, 3, "ErrorConfig<\/a>"], - [100, 3, "ExceptionConfig<\/a>"], - [100, 1, "Error<\/a>"], - [100, 34, "ErrorHandler<\/a>"], - [100, 19, "ExceptionHandler<\/a>"], - [100, 2, "ConsoleOutput<\/a>"], - [100, 2, "Dump<\/a>"], - [100, 6, "OutputFormatter<\/a>"], - [100, 9, "AbstractStyle<\/a>"], - [100, 1, "Info<\/a>"], - [100, 1, "Warning<\/a>"], - [100, 12, "ShutdownHandler<\/a>"]], 'Class Complexity')) + .datum(getComplexityData([[100,34,"AbstractHandler<\/a>"],[100,3,"AbstractConfig<\/a>"],[100,3,"ErrorConfig<\/a>"],[100,3,"ExceptionConfig<\/a>"],[100,1,"Error<\/a>"],[100,34,"ErrorHandler<\/a>"],[100,19,"ExceptionHandler<\/a>"],[100,2,"ConsoleOutput<\/a>"],[100,2,"Dump<\/a>"],[100,6,"OutputFormatter<\/a>"],[100,9,"AbstractStyle<\/a>"],[100,1,"Info<\/a>"],[100,1,"Warning<\/a>"],[100,12,"ShutdownHandler<\/a>"]], 'Class Complexity')) .transition() .duration(500) .call(chart); @@ -265,70 +249,7 @@

Project Risks

chart.yAxis.axisLabel('Method Complexity'); d3.select('#methodComplexity svg') - .datum(getComplexityData([[100, 3, - "
AbstractHandler::__construct<\/a>"], - [100, 2, "AbstractHandler::initSymfony<\/a>"], - [100, 3, "AbstractHandler::__toString<\/a>"], - [100, 4, "AbstractHandler::injectCSS<\/a>"], - [100, 2, "AbstractHandler::getTrace<\/a>"], - [100, 6, "AbstractHandler::traceCLI<\/a>"], - [100, 7, "AbstractHandler::formatTraceLine<\/a>"], - [100, 7, "AbstractHandler::traceHTML<\/a>"], - [100, 1, "AbstractConfig::__construct<\/a>"], - [100, 2, "AbstractConfig::setDefaults<\/a>"], - [100, 1, "ErrorConfig::__construct<\/a>"], - [100, 2, "ErrorConfig::setDefaultConfig<\/a>"], - [100, 1, "ExceptionConfig::__construct<\/a>"], - [100, 2, - "ExceptionConfig::setDefaultConfig<\/a>"], - [100, 1, "Error::__construct<\/a>"], - [100, 1, "ErrorHandler::__construct<\/a>"], - [100, 1, "ErrorHandler::isRegistered<\/a>"], - [100, 1, "ErrorHandler::getLastRegisteredHandler<\/a>"], - [100, 1, "ErrorHandler::getLastReportedError<\/a>"], - [100, 1, "ErrorHandler::register<\/a>"], - [100, 1, "ErrorHandler::getErrorReporting<\/a>"], - [100, 12, "ErrorHandler::handle<\/a>"], - [100, 1, "ErrorHandler::handleCLI<\/a>"], - [100, 1, "ErrorHandler::handleHTML<\/a>"], - [100, 11, "ErrorHandler::log<\/a>"], - [100, 3, "ErrorHandler::__toString<\/a>"], - [100, 1, "ExceptionHandler::__construct<\/a>"], [100, 1, - "ExceptionHandler::getLastRegisteredHandler<\/a>"], - [100, 1, - "ExceptionHandler::getLastReportedException<\/a>"], - [100, 1, "ExceptionHandler::isRegistered<\/a>"], - [100, 1, "ExceptionHandler::register<\/a>"], - [100, 2, "ExceptionHandler::handle<\/a>"], - [100, 1, "ExceptionHandler::handleCLI<\/a>"], [100, 4, - "ExceptionHandler::echoPreviousExceptions<\/a>"], - [100, 1, "ExceptionHandler::handleHTML<\/a>"], - [100, 3, "ExceptionHandler::log<\/a>"], - [100, 3, "ExceptionHandler::__toString<\/a>"], - [100, 1, "ConsoleOutput::__construct<\/a>"], - [100, 1, "ConsoleOutput::write<\/a>"], - [100, 2, "Dump::html<\/a>"], - [100, 2, "OutputFormatter::__construct<\/a>"], - [100, 4, "OutputFormatter::initStyles<\/a>"], - [100, 3, - "AbstractStyle::__construct<\/a>"], - [100, 1, - "AbstractStyle::setBackground<\/a>"], - [100, 1, "AbstractStyle::setOptions<\/a>"], - [100, 1, "AbstractStyle::setOption<\/a>"], - [100, 1, - "AbstractStyle::setForeground<\/a>"], - [100, 1, - "AbstractStyle::unsetOption<\/a>"], - [100, 1, "AbstractStyle::apply<\/a>"], - [100, 1, "Info::__construct<\/a>"], - [100, 1, "Warning::__construct<\/a>"], - [100, 1, "ShutdownHandler::isRegistered<\/a>"], [100, 1, - "ShutdownHandler::getLastRegisteredHandler<\/a>"], - [100, 1, "ShutdownHandler::register<\/a>"], - [100, 8, "ShutdownHandler::handle<\/a>"], - [100, 1, "ShutdownHandler::__toString<\/a>"]], - 'Method Complexity')) + .datum(getComplexityData([[100,3,"AbstractHandler::__construct<\/a>"],[100,2,"AbstractHandler::initSymfony<\/a>"],[100,3,"AbstractHandler::__toString<\/a>"],[100,4,"AbstractHandler::injectCSS<\/a>"],[100,2,"AbstractHandler::getTrace<\/a>"],[100,6,"AbstractHandler::traceCLI<\/a>"],[100,7,"AbstractHandler::formatTraceLine<\/a>"],[100,7,"AbstractHandler::traceHTML<\/a>"],[100,1,"AbstractConfig::__construct<\/a>"],[100,2,"AbstractConfig::setDefaults<\/a>"],[100,1,"ErrorConfig::__construct<\/a>"],[100,2,"ErrorConfig::setDefaultConfig<\/a>"],[100,1,"ExceptionConfig::__construct<\/a>"],[100,2,"ExceptionConfig::setDefaultConfig<\/a>"],[100,1,"Error::__construct<\/a>"],[100,1,"ErrorHandler::__construct<\/a>"],[100,1,"ErrorHandler::isRegistered<\/a>"],[100,1,"ErrorHandler::getLastRegisteredHandler<\/a>"],[100,1,"ErrorHandler::getLastReportedError<\/a>"],[100,1,"ErrorHandler::register<\/a>"],[100,1,"ErrorHandler::getErrorReporting<\/a>"],[100,12,"ErrorHandler::handle<\/a>"],[100,1,"ErrorHandler::handleCLI<\/a>"],[100,1,"ErrorHandler::handleHTML<\/a>"],[100,11,"ErrorHandler::log<\/a>"],[100,3,"ErrorHandler::__toString<\/a>"],[100,1,"ExceptionHandler::__construct<\/a>"],[100,1,"ExceptionHandler::getLastRegisteredHandler<\/a>"],[100,1,"ExceptionHandler::getLastReportedException<\/a>"],[100,1,"ExceptionHandler::isRegistered<\/a>"],[100,1,"ExceptionHandler::register<\/a>"],[100,2,"ExceptionHandler::handle<\/a>"],[100,1,"ExceptionHandler::handleCLI<\/a>"],[100,4,"ExceptionHandler::echoPreviousExceptions<\/a>"],[100,1,"ExceptionHandler::handleHTML<\/a>"],[100,3,"ExceptionHandler::log<\/a>"],[100,3,"ExceptionHandler::__toString<\/a>"],[100,1,"ConsoleOutput::__construct<\/a>"],[100,1,"ConsoleOutput::write<\/a>"],[100,2,"Dump::html<\/a>"],[100,2,"OutputFormatter::__construct<\/a>"],[100,4,"OutputFormatter::initStyles<\/a>"],[100,3,"AbstractStyle::__construct<\/a>"],[100,1,"AbstractStyle::setBackground<\/a>"],[100,1,"AbstractStyle::setOptions<\/a>"],[100,1,"AbstractStyle::setOption<\/a>"],[100,1,"AbstractStyle::setForeground<\/a>"],[100,1,"AbstractStyle::unsetOption<\/a>"],[100,1,"AbstractStyle::apply<\/a>"],[100,1,"Info::__construct<\/a>"],[100,1,"Warning::__construct<\/a>"],[100,1,"ShutdownHandler::isRegistered<\/a>"],[100,1,"ShutdownHandler::getLastRegisteredHandler<\/a>"],[100,1,"ShutdownHandler::register<\/a>"],[100,8,"ShutdownHandler::handle<\/a>"],[100,1,"ShutdownHandler::__toString<\/a>"]], 'Method Complexity')) .transition() .duration(500) .call(chart); diff --git a/coverage/index.html b/coverage/index.html index 9d3c5b9..e570ba7 100644 --- a/coverage/index.html +++ b/coverage/index.html @@ -41,47 +41,31 @@ - Total - -
-
- 100.00% covered (success) + Total +
+
+ 100.00% covered (success)
- -
100.00%
- - -
182 / 182
- +
100.00%
+
182 / 182
-
- 100.00% covered (success) +
+ 100.00% covered (success)
- -
100.00%
- - -
49 / 49
- +
100.00%
+
49 / 49
-
- 100.00% covered (success) +
+ 100.00% covered (success)
- -
100.00%
- - -
15 / 15
- +
100.00%
+
15 / 15
@@ -253,50 +237,31 @@ -
ShutdownHandler.php - - -
-
- 100.00% covered (success) + ShutdownHandler.php +
+
+ 100.00% covered (success)
- -
100.00%
- - -
9 / 9
- - -
-
- 100.00% covered (success) +
100.00%
+
9 / 9
+
+
+ 100.00% covered (success)
- -
100.00%
- - -
4 / 4
- - -
-
- 100.00% covered (success) +
100.00%
+
4 / 4
+
+
+ 100.00% covered (success)
- -
100.00%
- - -
1 / 1
- +
100.00%
+
1 / 1
@@ -311,10 +276,7 @@

Legend

High: 90% to 100%

- Generated by PHP_CodeCoverage - 3.0.1 using PHP 5.6.14 and PHPUnit - 5.0.8 at Sat Oct 24 11:36:16 BST 2015. - + Generated by PHP_CodeCoverage 3.0.1 using PHP 5.6.14 and PHPUnit 5.0.8 at Sat Oct 24 11:46:27 BST 2015.

diff --git a/docs/404.html b/docs/404.html index 9846bea..aacda4b 100644 --- a/docs/404.html +++ b/docs/404.html @@ -6,58 +6,93 @@ Page not found | AloFramework Handlers 2.0 API - + + -
-