Update file header, and fix some style issues
This commit is contained in:
parent
733c481a4c
commit
2adb02daaa
30
RoboFile.php
30
RoboFile.php
@ -44,9 +44,9 @@ class RoboFile extends \Robo\Tasks {
|
||||
$this->prepare();
|
||||
$this->lint();
|
||||
$this->phploc(TRUE);
|
||||
$this->phpcs(TRUE);
|
||||
$this->dependencyReport();
|
||||
$this->phpcpdReport();
|
||||
$this->phpcsReport();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -143,15 +143,24 @@ class RoboFile extends \Robo\Tasks {
|
||||
|
||||
/**
|
||||
* Run the phpcs tool
|
||||
*
|
||||
* @param bool $report - if true, generates reports instead of direct output
|
||||
*/
|
||||
public function phpcs()
|
||||
public function phpcs($report = FALSE)
|
||||
{
|
||||
$cmd_parts = [
|
||||
$report_cmd_parts = [
|
||||
'vendor/bin/phpcs',
|
||||
'--standard=./build/phpcs.xml',
|
||||
'--report=summary'
|
||||
'--report-checkstyle=./build/logs/phpcs.xml',
|
||||
];
|
||||
|
||||
$normal_cmd_parts = [
|
||||
'vendor/bin/phpcs',
|
||||
'--standard=./build/phpcs.xml',
|
||||
];
|
||||
|
||||
$cmd_parts = ($report) ? $report_cmd_parts : $normal_cmd_parts;
|
||||
|
||||
$this->_run($cmd_parts);
|
||||
}
|
||||
|
||||
@ -284,19 +293,6 @@ class RoboFile extends \Robo\Tasks {
|
||||
$this->_run($cmd_parts);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate code style report
|
||||
*/
|
||||
protected function phpcsReport()
|
||||
{
|
||||
$cmd_parts = [
|
||||
'vendor/bin/phpcs',
|
||||
'--standard=./build/phpcs.xml',
|
||||
'--report-xml=./build/logs/phpcs.xml'
|
||||
];
|
||||
$this->_run($cmd_parts);
|
||||
}
|
||||
|
||||
/**
|
||||
* Shortcut for joining an array of command arguments
|
||||
* and then running it
|
||||
|
@ -1 +0,0 @@
|
||||
Subproject commit b501f01403216a917754e3f76ba7022d4ad37a4e
|
@ -3,8 +3,12 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
@ -4,6 +4,8 @@
|
||||
|
||||
<file>../src/</file>
|
||||
|
||||
<encoding>utf-8</encoding>
|
||||
|
||||
<rule ref="Generic.Files.LineEndings">
|
||||
<properties>
|
||||
<property name="eolChar" value="\n"/>
|
||||
@ -24,15 +26,28 @@
|
||||
<rule ref="Generic.Formatting.DisallowMultipleStatements"/>
|
||||
|
||||
<!-- Classes and functions should be commented -->
|
||||
<rule ref="PEAR.Commenting.ClassComment"/>
|
||||
<rule ref="PEAR.Commenting.FunctionComment"/>
|
||||
<rule ref="Squiz.Commenting.FunctionCommentThrowTag"/>
|
||||
<rule ref="PEAR.Commenting.ClassComment">
|
||||
<exclude name="PEAR.Commenting.ClassComment.MissingCategoryTag" />
|
||||
<exclude name="PEAR.Commenting.ClassComment.MissingPackageTag" />
|
||||
<exclude name="PEAR.Commenting.ClassComment.MissingAuthorTag" />
|
||||
<exclude name="PEAR.Commenting.ClassComment.MissingLicenseTag" />
|
||||
<exclude name="PEAR.Commenting.ClassComment.MissingLinkTag" />
|
||||
</rule>
|
||||
<rule ref="PEAR.Commenting.FunctionComment">
|
||||
<!-- Exclude this sniff because it doesn't understand multiple types -->
|
||||
<exclude name="PEAR.Commenting.FunctionComment.MissingParamComment" />
|
||||
</rule>
|
||||
|
||||
<!-- Use warnings for docblock comments for files and variables, since nothing is cleary explained -->
|
||||
<rule ref="PEAR.Commenting.FileComment">
|
||||
<exclude name="PEAR.Commenting.FileComment.InvalidVersion" />
|
||||
<exclude name="PEAR.Commenting.FileComment.MissingCategoryTag" />
|
||||
<properties>
|
||||
<property name="error" value="false"/>
|
||||
</properties>
|
||||
</rule>
|
||||
|
||||
<rule ref="Squiz.Commenting.FunctionCommentThrowTag"/>
|
||||
<rule ref="Squiz.Commenting.VariableComment">
|
||||
<properties>
|
||||
<property name="error" value="false"/>
|
||||
@ -45,9 +60,19 @@
|
||||
<rule ref="PEAR.WhiteSpace.ScopeClosingBrace"/>
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing"/>
|
||||
|
||||
<!-- Use only short array syntax -->
|
||||
<rule ref="Generic.Arrays.DisallowLongArraySyntax" />
|
||||
|
||||
<rule ref="Generic.PHP.ForbiddenFunctions">
|
||||
<properties>
|
||||
<property name="forbiddenFunctions" type="array" value="create_function=>null,eval=>null" />
|
||||
</properties>
|
||||
</rule>
|
||||
|
||||
<!-- Inherit CodeIgniter Rules -->
|
||||
<rule ref="./CodeIgniter">
|
||||
<properties>
|
||||
<property name="error" value="false" />
|
||||
</properties>
|
||||
</rule>
|
||||
</ruleset>
|
@ -85,7 +85,7 @@
|
||||
</source>
|
||||
|
||||
<!-- PHP Code Sniffer findings -->
|
||||
<source type="phpcs">
|
||||
<source type="checkstyle">
|
||||
<file name="phpcs.xml" />
|
||||
</source>
|
||||
|
||||
|
@ -9,7 +9,8 @@
|
||||
},
|
||||
"autoload-dev": {
|
||||
"psr-4": {
|
||||
"Aviat\\Ion\\Tests\\": "tests/Ion/"
|
||||
"Aviat\\Ion\\Tests\\": "tests/Ion/",
|
||||
"CodeIgniter\\": "build/CodeIgniter/"
|
||||
}
|
||||
},
|
||||
"require": {
|
||||
@ -36,7 +37,7 @@
|
||||
"nikic/php-parser": "3.0.*@alpha",
|
||||
"monolog/monolog": "1.*",
|
||||
"predis/predis": "1.1.*",
|
||||
"squizlabs/php_codesniffer": "^2.6"
|
||||
"squizlabs/php_codesniffer": "^3.0.0@alpha"
|
||||
},
|
||||
"suggest": {
|
||||
"monolog/monolog": "Provides implementation of psr/log",
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache\Driver;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache\Driver;
|
||||
@ -22,8 +26,10 @@ trait DriverTrait {
|
||||
|
||||
/**
|
||||
* Key prefix for key / value cache stores
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected static $CACHE_KEY_PREFIX = "hbac:cache:";
|
||||
protected static $CACHE_KEY_PREFIX = "aviat:ion:cache:";
|
||||
|
||||
/**
|
||||
* Set key prefix for cache drivers that have global keys
|
||||
|
@ -4,14 +4,17 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache\Driver;
|
||||
use Aviat\Ion\ConfigInterface;
|
||||
|
||||
/**
|
||||
* The Driver for no real cache
|
||||
@ -20,6 +23,7 @@ class NullDriver implements DriverInterface {
|
||||
|
||||
/**
|
||||
* 'Cache' for Null data store
|
||||
* @var array
|
||||
*/
|
||||
protected $data = [];
|
||||
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache\Driver;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Cache\Driver;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di;
|
||||
@ -160,7 +164,7 @@ class Container implements ContainerInterface {
|
||||
$uses_trait = in_array($trait_name, class_uses($obj));
|
||||
$implements_interface = in_array($interface_name, class_implements($obj));
|
||||
|
||||
if ($uses_trait || $implements_interface)
|
||||
if ($uses_trait OR $implements_interface)
|
||||
{
|
||||
$obj->setContainer($this);
|
||||
}
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di\Exception;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Di\Exception;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Exception;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Exception;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
@ -39,6 +43,7 @@ class Friend {
|
||||
* Create a friend object
|
||||
*
|
||||
* @param object $obj
|
||||
* @throws InvalidArgumentException
|
||||
*/
|
||||
public function __construct($obj)
|
||||
{
|
||||
@ -90,6 +95,7 @@ class Friend {
|
||||
* @param string $method
|
||||
* @param array $args
|
||||
* @return mixed
|
||||
* @throws BadMethodCallException
|
||||
*/
|
||||
public function __call($method, $args)
|
||||
{
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
@ -103,6 +107,7 @@ class Json {
|
||||
* Call the json error functions to check for errors encoding/decoding
|
||||
*
|
||||
* @throws JsonException
|
||||
* @return void
|
||||
*/
|
||||
protected static function check_json_error()
|
||||
{
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Model;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
@ -25,13 +29,13 @@ trait StaticInstance {
|
||||
private static $instance = [];
|
||||
|
||||
/**
|
||||
* Call methods protected to allow for
|
||||
* Call protected methods to allow for
|
||||
* static and instance calling
|
||||
*
|
||||
* @codeCoverageIgnore
|
||||
* @param string $method
|
||||
* @param array $args
|
||||
* @retun mixed
|
||||
* @return mixed
|
||||
*/
|
||||
public function __call($method, $args)
|
||||
{
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Transformer;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Transformer;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Type;
|
||||
@ -214,7 +218,7 @@ class ArrayType {
|
||||
|
||||
foreach ($key as $level)
|
||||
{
|
||||
if (empty($pos) || ! is_array($pos))
|
||||
if (empty($pos) OR ! is_array($pos))
|
||||
{
|
||||
// Directly returning a NULL value here will
|
||||
// result in a reference error. This isn't
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\Type;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
@ -16,12 +20,13 @@ use Psr\Http\Message\ResponseInterface;
|
||||
|
||||
use Aviat\Ion\Di\ContainerInterface;
|
||||
use Aviat\Ion\Exception\DoubleRenderException;
|
||||
use Aviat\Ion\Type\StringType;
|
||||
|
||||
/**
|
||||
* Base view response class
|
||||
*/
|
||||
abstract class View /* partially */ implements ViewInterface {
|
||||
abstract class View
|
||||
// partially
|
||||
implements ViewInterface {
|
||||
|
||||
use Di\ContainerAware;
|
||||
use StringWrapper;
|
||||
@ -64,7 +69,11 @@ abstract class View /* partially */ implements ViewInterface {
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
* Return rendered output as string. Renders the view,
|
||||
* and any attempts to call again will result in a DoubleRenderException
|
||||
*
|
||||
* @throws DoubleRenderException
|
||||
* @return string
|
||||
*/
|
||||
public function __toString()
|
||||
{
|
||||
@ -77,7 +86,10 @@ abstract class View /* partially */ implements ViewInterface {
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
* Set the output string
|
||||
*
|
||||
* @param string $string
|
||||
* @return ViewInterface
|
||||
*/
|
||||
public function setOutput($string)
|
||||
{
|
||||
@ -87,7 +99,10 @@ abstract class View /* partially */ implements ViewInterface {
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
* Append additional output.
|
||||
*
|
||||
* @param string $string
|
||||
* @return ViewInterface
|
||||
*/
|
||||
public function appendOutput($string)
|
||||
{
|
||||
@ -95,7 +110,10 @@ abstract class View /* partially */ implements ViewInterface {
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
* Get the current output as a string. Does not
|
||||
* render view or send headers.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getOutput()
|
||||
{
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\View;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\View;
|
||||
@ -68,7 +72,11 @@ class HttpView extends BaseView {
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
* Send output to client. As it renders the view,
|
||||
* any attempt to call again will result in a DoubleRenderException.
|
||||
*
|
||||
* @throws DoubleRenderException
|
||||
* @return void
|
||||
*/
|
||||
public function send()
|
||||
{
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion\View;
|
||||
|
@ -4,10 +4,14 @@
|
||||
*
|
||||
* Building blocks for web development
|
||||
*
|
||||
* PHP version 5.6
|
||||
*
|
||||
* @package Ion
|
||||
* @author Timothy J. Warren
|
||||
* @copyright Copyright (c) 2015 - 2016
|
||||
* @license MIT
|
||||
* @author Timothy J. Warren <tim@timshomepage.net>
|
||||
* @copyright 2015 - 2016 Timothy J. Warren
|
||||
* @license http://www.opensource.org/licenses/mit-license.html MIT License
|
||||
* @version 1.0.0
|
||||
* @link https://git.timshomepage.net/timw4mail/ion
|
||||
*/
|
||||
|
||||
namespace Aviat\Ion;
|
||||
|
Loading…
Reference in New Issue
Block a user