diff --git a/RoboFile.php b/RoboFile.php index 1e18dec2e3..81409685ec 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -270,7 +270,7 @@ public function testCli($option = [ if (!$inDocker) { - $containerInfo = json_decode(`docker inspect cli_cli`); + $containerInfo = json_decode(`docker inspect joomlapythagoras_cli`); $build = false; if (empty($containerInfo)) @@ -293,10 +293,10 @@ public function testCli($option = [ if ($build) { $this->say('Building container.'); - `docker-compose -f tests/cli/docker-compose.yml build`; + `docker-compose -f docker-compose-cli.yml build`; } - $this->say(`docker-compose -f tests/cli/docker-compose.yml up`); + $this->say(`docker-compose -f docker-compose-cli.yml up`); $this->remap('/var/test', __DIR__, 'build/reports/coverage.cli.php'); diff --git a/build/.gitignore b/build/.gitignore index bea6bf8199..0f890c008c 100644 --- a/build/.gitignore +++ b/build/.gitignore @@ -2,3 +2,13 @@ /docs /reports /logs +/pdepend-summary.xml +/phpmd.xml +/pdepend-pyramid.svg +/phploc.xml +/phpmetrics.html +/phpcpd.xml +/checkstyle.xml +/phpmetrics.xml +/pdepend-jdepend.svg +/pdepend-jdepend.xml diff --git a/build/docker/cli/Dockerfile b/build/docker/cli/Dockerfile index 128413c091..79e283f033 100644 --- a/build/docker/cli/Dockerfile +++ b/build/docker/cli/Dockerfile @@ -9,23 +9,22 @@ RUN apt-get update \ sqlite3 \ libsqlite3-dev +# Install Composer +RUN cd /usr/src \ + && curl -sS https://getcomposer.org/installer -o composer-setup.php \ + && php composer-setup.php --install-dir=/usr/local/bin --filename=composer + # Install MailCatcher RUN gem install mailcatcher --no-ri --no-rdoc -RUN php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" \ - && php -r "if (hash_file('SHA384', 'composer-setup.php') === 'e115a8dc7871f15d853148a7fbac7da27d6c0030b848d9b3dc09e2a0388afed865e6a3d6b3c0fad45c48e2b5fc1196ae') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" \ - && php composer-setup.php --install-dir=/ \ - && php -r "unlink('composer-setup.php');" \ - && mv composer.phar /usr/local/bin/composer - # Setup the Xdebug version to install -ENV XDEBUG_VERSION 2.4.1 -ENV XDEBUG_SHA1 52b5cede5dcb815de469d671bfdc626aec8adee3 +ENV XDEBUG_VERSION 2.5.1 +ENV XDEBUG_SHA256 7fda9020fd5a2c549ae5a692fcabbb00f74e39dda81d53d25e622bdab4880ec2 # Install Xdebug RUN set -x \ && curl -SL "http://www.xdebug.org/files/xdebug-$XDEBUG_VERSION.tgz" -o xdebug.tgz \ - && echo $XDEBUG_SHA1 xdebug.tgz | sha1sum -c - \ + && echo $XDEBUG_SHA256 xdebug.tgz | sha256sum -c - \ && mkdir -p /usr/src/xdebug \ && tar -xf xdebug.tgz -C /usr/src/xdebug --strip-components=1 \ && rm xdebug.* \ diff --git a/build/docker/cli/runtests.sh b/build/docker/cli/runtests.sh index d2f8f9eb6d..ef239c25dc 100755 --- a/build/docker/cli/runtests.sh +++ b/build/docker/cli/runtests.sh @@ -8,11 +8,10 @@ cd $WORK_DIR cp /usr/local/lib/php/prepend.php . cp /usr/local/lib/php/append.php . cp /usr/local/lib/php/phpunit_coverage.php . -cp tests/cli/codeception.yml . echo "Running tests ..." -./libraries/vendor/bin/codecept run --coverage=coverage.cli.php cli +./libraries/vendor/bin/robo test:cli --coverage return_code=$? echo "Collecting results ..." @@ -22,7 +21,6 @@ php phpunit_coverage.php rm prepend.php rm append.php rm phpunit_coverage.php -rm codeception.yml echo "Done." diff --git a/composer.json b/composer.json index 627873c2e8..8a3389a1ad 100644 --- a/composer.json +++ b/composer.json @@ -13,7 +13,6 @@ "vendor-dir": "libraries/vendor" }, "require": { - "php": ">=5.5.9", "league/flysystem": "^1.0", "doctrine/dbal": "^2.5.5", "league/tactician": "^1.0", @@ -29,11 +28,9 @@ }, "require-dev": { "codeception/codeception": "^2.0", - "codegyre/robo": "^0.7.0", "slim/csrf": "^0.7.0", "greencape/coding-standards": "^1.0", "mayflower/php-codebrowser": "^1.1", - "apigen/apigen": "^4", "codeception/mockery-module": "^0.2.2", "phpmetrics/phpmetrics": "^1.10", "phploc/phploc": "^2.1", @@ -42,7 +39,8 @@ "phpmd/phpmd": "^2.4", "phpunit/phpunit": "^5", "phpunit/php-code-coverage": "^4", - "phpunit/phpunit-mock-objects": "^3.2" + "phpunit/phpunit-mock-objects": "^3.2", + "consolidation/robo": "^1.0" }, "autoload": { "psr-4": { diff --git a/composer.lock b/composer.lock index 2bef750e71..30025fe4f3 100644 --- a/composer.lock +++ b/composer.lock @@ -4,21 +4,21 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "7754f9d55a05cb81d9d50de272cef3e9", - "content-hash": "07e099f160181350a097c1a4538af96a", + "hash": "9b156cf6fbe1737f1554272d03ecd190", + "content-hash": "9fde5b1ba459e549fa6caecd68e9edbd", "packages": [ { "name": "aura/session", - "version": "2.0.1", + "version": "2.1.0", "source": { "type": "git", "url": "https://github.com/auraphp/Aura.Session.git", - "reference": "9e018278794228e40c7695b699c848bea2355a12" + "reference": "7d2f7d41ad693970b5b6b83facca0961d3378883" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/auraphp/Aura.Session/zipball/9e018278794228e40c7695b699c848bea2355a12", - "reference": "9e018278794228e40c7695b699c848bea2355a12", + "url": "https://api.github.com/repos/auraphp/Aura.Session/zipball/7d2f7d41ad693970b5b6b83facca0961d3378883", + "reference": "7d2f7d41ad693970b5b6b83facca0961d3378883", "shasum": "" }, "require": { @@ -30,7 +30,8 @@ "suggest": { "ext-mcrypt": "Mcrypt generates the next best secure CSRF tokens.", "ext-openssl": "OpenSSL generates the best secure CSRF tokens.", - "ircmaxell/random-lib": "A Library For Generating Secure Random Numbers" + "ircmaxell/random-lib": "A Library For Generating Secure Random Numbers", + "paragonie/random_compat": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7" }, "type": "library", "extra": { @@ -39,9 +40,6 @@ "config": { "common": "Aura\\Session\\_Config\\Common" } - }, - "branch-alias": { - "dev-develop-2": "2.0.x-dev" } }, "autoload": { @@ -69,22 +67,25 @@ "session", "sessions" ], - "time": "2015-03-27 18:33:22" + "time": "2016-10-03 20:28:32" }, { "name": "container-interop/container-interop", - "version": "1.1.0", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/container-interop/container-interop.git", - "reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e" + "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/container-interop/container-interop/zipball/fc08354828f8fd3245f77a66b9e23a6bca48297e", - "reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e", + "url": "https://api.github.com/repos/container-interop/container-interop/zipball/79cbf1341c22ec75643d841642dd5d6acd83bdb8", + "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8", "shasum": "" }, + "require": { + "psr/container": "^1.0" + }, "type": "library", "autoload": { "psr-4": { @@ -96,39 +97,40 @@ "MIT" ], "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", - "time": "2014-12-30 15:22:37" + "homepage": "https://github.com/container-interop/container-interop", + "time": "2017-02-14 19:40:03" }, { "name": "doctrine/annotations", - "version": "v1.2.7", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/doctrine/annotations.git", - "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535" + "reference": "54cacc9b81758b14e3ce750f205a393d52339e97" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/f25c8aab83e0c3e976fd7d19875f198ccf2f7535", - "reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535", + "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97", + "reference": "54cacc9b81758b14e3ce750f205a393d52339e97", "shasum": "" }, "require": { "doctrine/lexer": "1.*", - "php": ">=5.3.2" + "php": "^5.6 || ^7.0" }, "require-dev": { "doctrine/cache": "1.*", - "phpunit/phpunit": "4.*" + "phpunit/phpunit": "^5.7" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3.x-dev" + "dev-master": "1.4.x-dev" } }, "autoload": { - "psr-0": { - "Doctrine\\Common\\Annotations\\": "lib/" + "psr-4": { + "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" } }, "notification-url": "https://packagist.org/downloads/", @@ -164,20 +166,20 @@ "docblock", "parser" ], - "time": "2015-08-31 12:32:49" + "time": "2017-02-24 16:22:25" }, { "name": "doctrine/cache", - "version": "v1.6.0", + "version": "v1.6.1", "source": { "type": "git", "url": "https://github.com/doctrine/cache.git", - "reference": "f8af318d14bdb0eff0336795b428b547bd39ccb6" + "reference": "b6f544a20f4807e81f7044d31e679ccbb1866dc3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/f8af318d14bdb0eff0336795b428b547bd39ccb6", - "reference": "f8af318d14bdb0eff0336795b428b547bd39ccb6", + "url": "https://api.github.com/repos/doctrine/cache/zipball/b6f544a20f4807e81f7044d31e679ccbb1866dc3", + "reference": "b6f544a20f4807e81f7044d31e679ccbb1866dc3", "shasum": "" }, "require": { @@ -234,32 +236,33 @@ "cache", "caching" ], - "time": "2015-12-31 16:37:02" + "time": "2016-10-29 11:16:17" }, { "name": "doctrine/collections", - "version": "v1.3.0", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/doctrine/collections.git", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a" + "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/6c1e4eef75f310ea1b3e30945e9f06e652128b8a", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a", + "url": "https://api.github.com/repos/doctrine/collections/zipball/1a4fb7e902202c33cce8c55989b945612943c2ba", + "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": "^5.6 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "~4.0" + "doctrine/coding-standard": "~0.1@dev", + "phpunit/phpunit": "^5.7" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "1.3.x-dev" } }, "autoload": { @@ -300,20 +303,20 @@ "collections", "iterator" ], - "time": "2015-04-14 22:21:58" + "time": "2017-01-03 10:49:41" }, { "name": "doctrine/common", - "version": "v2.6.1", + "version": "v2.7.2", "source": { "type": "git", "url": "https://github.com/doctrine/common.git", - "reference": "a579557bc689580c19fee4e27487a67fe60defc0" + "reference": "930297026c8009a567ac051fd545bf6124150347" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/a579557bc689580c19fee4e27487a67fe60defc0", - "reference": "a579557bc689580c19fee4e27487a67fe60defc0", + "url": "https://api.github.com/repos/doctrine/common/zipball/930297026c8009a567ac051fd545bf6124150347", + "reference": "930297026c8009a567ac051fd545bf6124150347", "shasum": "" }, "require": { @@ -322,10 +325,10 @@ "doctrine/collections": "1.*", "doctrine/inflector": "1.*", "doctrine/lexer": "1.*", - "php": "~5.5|~7.0" + "php": "~5.6|~7.0" }, "require-dev": { - "phpunit/phpunit": "~4.8|~5.0" + "phpunit/phpunit": "^5.4.6" }, "type": "library", "extra": { @@ -373,29 +376,29 @@ "persistence", "spl" ], - "time": "2015-12-25 13:18:31" + "time": "2017-01-13 14:02:13" }, { "name": "doctrine/dbal", - "version": "dev-master", + "version": "v2.5.12", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "2c345592d33f73dedddbf2bf4d0825495792f9e7" + "reference": "7b9e911f9d8b30d43b96853dab26898c710d8f44" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/2c345592d33f73dedddbf2bf4d0825495792f9e7", - "reference": "2c345592d33f73dedddbf2bf4d0825495792f9e7", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/7b9e911f9d8b30d43b96853dab26898c710d8f44", + "reference": "7b9e911f9d8b30d43b96853dab26898c710d8f44", "shasum": "" }, "require": { - "doctrine/common": "~2.4", - "php": ">=5.4" + "doctrine/common": ">=2.4,<2.8-dev", + "php": ">=5.3.2" }, "require-dev": { "phpunit/phpunit": "4.*", - "symfony/console": "2.*" + "symfony/console": "2.*||^3.0" }, "suggest": { "symfony/console": "For helpful console commands such as SQL execution and import of files." @@ -406,7 +409,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.6.x-dev" + "dev-master": "2.5.x-dev" } }, "autoload": { @@ -444,7 +447,7 @@ "persistence", "queryobject" ], - "time": "2015-12-18 15:47:37" + "time": "2017-02-08 12:53:47" }, { "name": "doctrine/inflector", @@ -569,27 +572,27 @@ }, { "name": "guzzlehttp/guzzle", - "version": "6.2.0", + "version": "6.2.3", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "d094e337976dff9d8e2424e8485872194e768662" + "reference": "8d6c6cc55186db87b7dc5009827429ba4e9dc006" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/d094e337976dff9d8e2424e8485872194e768662", - "reference": "d094e337976dff9d8e2424e8485872194e768662", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/8d6c6cc55186db87b7dc5009827429ba4e9dc006", + "reference": "8d6c6cc55186db87b7dc5009827429ba4e9dc006", "shasum": "" }, "require": { - "guzzlehttp/promises": "~1.0", - "guzzlehttp/psr7": "~1.1", - "php": ">=5.5.0" + "guzzlehttp/promises": "^1.0", + "guzzlehttp/psr7": "^1.4", + "php": ">=5.5" }, "require-dev": { "ext-curl": "*", - "phpunit/phpunit": "~4.0", - "psr/log": "~1.0" + "phpunit/phpunit": "^4.0", + "psr/log": "^1.0" }, "type": "library", "extra": { @@ -627,32 +630,32 @@ "rest", "web service" ], - "time": "2016-03-21 20:02:09" + "time": "2017-02-28 22:50:30" }, { "name": "guzzlehttp/promises", - "version": "1.2.0", + "version": "v1.3.1", "source": { "type": "git", "url": "https://github.com/guzzle/promises.git", - "reference": "c10d860e2a9595f8883527fa0021c7da9e65f579" + "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/promises/zipball/c10d860e2a9595f8883527fa0021c7da9e65f579", - "reference": "c10d860e2a9595f8883527fa0021c7da9e65f579", + "url": "https://api.github.com/repos/guzzle/promises/zipball/a59da6cf61d80060647ff4d3eb2c03a2bc694646", + "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646", "shasum": "" }, "require": { "php": ">=5.5.0" }, "require-dev": { - "phpunit/phpunit": "~4.0" + "phpunit/phpunit": "^4.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -678,20 +681,20 @@ "keywords": [ "promise" ], - "time": "2016-05-18 16:56:05" + "time": "2016-12-20 10:07:11" }, { "name": "guzzlehttp/psr7", - "version": "1.3.0", + "version": "1.4.2", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "31382fef2889136415751badebbd1cb022a4ed72" + "reference": "f5b8a8512e2b58b0071a7280e39f14f72e05d87c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/31382fef2889136415751badebbd1cb022a4ed72", - "reference": "31382fef2889136415751badebbd1cb022a4ed72", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/f5b8a8512e2b58b0071a7280e39f14f72e05d87c", + "reference": "f5b8a8512e2b58b0071a7280e39f14f72e05d87c", "shasum": "" }, "require": { @@ -707,7 +710,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -727,16 +730,23 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Schultze", + "homepage": "https://github.com/Tobion" } ], - "description": "PSR-7 message implementation", + "description": "PSR-7 message implementation that also provides common utility methods", "keywords": [ "http", "message", + "request", + "response", "stream", - "uri" + "uri", + "url" ], - "time": "2016-04-13 19:56:01" + "time": "2017-03-20 17:10:46" }, { "name": "ircmaxell/password-compat", @@ -780,54 +790,6 @@ ], "time": "2014-11-20 16:49:30" }, - { - "name": "jeremeamia/SuperClosure", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/jeremeamia/super_closure.git", - "reference": "4d89ca74994feab128ea46d5b3add92e6cb84554" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/jeremeamia/super_closure/zipball/4d89ca74994feab128ea46d5b3add92e6cb84554", - "reference": "4d89ca74994feab128ea46d5b3add92e6cb84554", - "shasum": "" - }, - "require": { - "nikic/php-parser": "~0.9", - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~3.7" - }, - "type": "library", - "autoload": { - "psr-0": { - "Jeremeamia\\SuperClosure": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jeremy Lindblom" - } - ], - "description": "Doing interesting things with closures like serialization.", - "homepage": "https://github.com/jeremeamia/super_closure", - "keywords": [ - "closure", - "function", - "parser", - "serializable", - "serialize", - "tokenizer" - ], - "time": "2015-01-10 01:09:28" - }, { "name": "joomla/compat", "version": "1.2.0", @@ -920,26 +882,29 @@ }, { "name": "joomla/string", - "version": "1.4.0", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/joomla-framework/string.git", - "reference": "05197132a075ee22a3f0f7da31a19a6d5b4717db" + "reference": "66363d317e6c020f30a70265c129281c77c43ca0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/joomla-framework/string/zipball/05197132a075ee22a3f0f7da31a19a6d5b4717db", - "reference": "05197132a075ee22a3f0f7da31a19a6d5b4717db", + "url": "https://api.github.com/repos/joomla-framework/string/zipball/66363d317e6c020f30a70265c129281c77c43ca0", + "reference": "66363d317e6c020f30a70265c129281c77c43ca0", "shasum": "" }, "require": { - "php": ">=5.3.10|>=7.0" + "php": "^5.3.10|~7.0" }, "require-dev": { "joomla/test": "~1.0", "phpunit/phpunit": "~4.8|~5.0", "squizlabs/php_codesniffer": "1.*" }, + "suggest": { + "ext-mbstring": "For improved processing" + }, "type": "joomla-package", "extra": { "branch-alias": { @@ -948,8 +913,7 @@ }, "autoload": { "psr-4": { - "Joomla\\String\\": "src/", - "Joomla\\String\\Tests\\": "Tests/" + "Joomla\\String\\": "src/" }, "files": [ "src/phputf8/utf8.php", @@ -980,28 +944,28 @@ "joomla", "string" ], - "time": "2016-01-30 20:04:23" + "time": "2016-12-10 18:13:42" }, { "name": "joomla/utilities", - "version": "1.4.0", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/joomla-framework/utilities.git", - "reference": "ecf18231ff86ab06cf555a7c3ed4dd447ae39e9b" + "reference": "8913ca02aad7b929e0d52d78fd5a6961070bdbc6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/joomla-framework/utilities/zipball/ecf18231ff86ab06cf555a7c3ed4dd447ae39e9b", - "reference": "ecf18231ff86ab06cf555a7c3ed4dd447ae39e9b", + "url": "https://api.github.com/repos/joomla-framework/utilities/zipball/8913ca02aad7b929e0d52d78fd5a6961070bdbc6", + "reference": "8913ca02aad7b929e0d52d78fd5a6961070bdbc6", "shasum": "" }, "require": { "joomla/string": "~1.3", - "php": ">=5.3.10" + "php": "^5.3.10|~7.0" }, "require-dev": { - "phpunit/phpunit": "4.*", + "phpunit/phpunit": "~4.8|~5.0", "squizlabs/php_codesniffer": "1.*" }, "type": "joomla-package", @@ -1012,8 +976,7 @@ }, "autoload": { "psr-4": { - "Joomla\\Utilities\\": "src/", - "Joomla\\Utilities\\Tests\\": "Tests/" + "Joomla\\Utilities\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -1027,24 +990,24 @@ "joomla", "utilities" ], - "time": "2015-09-05 16:41:24" + "time": "2016-12-10 17:09:33" }, { "name": "league/flysystem", - "version": "1.0.24", + "version": "1.0.37", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "9aca859a303fdca30370f42b8c611d9cf0dedf4b" + "reference": "78b5cc4feb61a882302df4fbaf63b7662e5e4ccd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/9aca859a303fdca30370f42b8c611d9cf0dedf4b", - "reference": "9aca859a303fdca30370f42b8c611d9cf0dedf4b", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/78b5cc4feb61a882302df4fbaf63b7662e5e4ccd", + "reference": "78b5cc4feb61a882302df4fbaf63b7662e5e4ccd", "shasum": "" }, "require": { - "php": ">=5.4.0" + "php": ">=5.5.9" }, "conflict": { "league/flysystem-sftp": "<1.0.6" @@ -1053,7 +1016,7 @@ "ext-fileinfo": "*", "mockery/mockery": "~0.9", "phpspec/phpspec": "^2.2", - "phpunit/phpunit": "~4.8 || ~5.0" + "phpunit/phpunit": "~4.8" }, "suggest": { "ext-fileinfo": "Required for MimeType", @@ -1110,20 +1073,20 @@ "sftp", "storage" ], - "time": "2016-06-03 19:11:39" + "time": "2017-03-22 15:43:14" }, { "name": "league/tactician", - "version": "v0.6.1", + "version": "v1.0.2", "source": { "type": "git", "url": "https://github.com/thephpleague/tactician.git", - "reference": "5313db226bf4e236faf8e5bb2a79203b78a9ae41" + "reference": "1f3aaad497f07a8bef147a37c7e3f2f7c23fcd21" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/tactician/zipball/5313db226bf4e236faf8e5bb2a79203b78a9ae41", - "reference": "5313db226bf4e236faf8e5bb2a79203b78a9ae41", + "url": "https://api.github.com/repos/thephpleague/tactician/zipball/1f3aaad497f07a8bef147a37c7e3f2f7c23fcd21", + "reference": "1f3aaad497f07a8bef147a37c7e3f2f7c23fcd21", "shasum": "" }, "require": { @@ -1137,7 +1100,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "0.7-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -1161,33 +1124,34 @@ "command bus", "service layer" ], - "time": "2015-08-02 09:13:42" + "time": "2016-02-20 11:14:36" }, { "name": "matthiasmullie/scrapbook", - "version": "1.2.2", + "version": "1.4.3", "source": { "type": "git", "url": "https://github.com/matthiasmullie/scrapbook.git", - "reference": "6b739a845321a17c4a02128ddf428a1c2eea89b6" + "reference": "828c9e4886340e6ea60688a7df2df6a591b0a4d5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/matthiasmullie/scrapbook/zipball/6b739a845321a17c4a02128ddf428a1c2eea89b6", - "reference": "6b739a845321a17c4a02128ddf428a1c2eea89b6", + "url": "https://api.github.com/repos/matthiasmullie/scrapbook/zipball/828c9e4886340e6ea60688a7df2df6a591b0a4d5", + "reference": "828c9e4886340e6ea60688a7df2df6a591b0a4d5", "shasum": "" }, "require": { "php": "^5.3|^7.0", - "psr/cache": "~1.0" + "psr/cache": "~1.0", + "psr/simple-cache": "~1.0" }, "provide": { - "psr/cache-implementation": "~1.0" + "psr/cache-implementation": "~1.0", + "psr/simple-cache-implementation": "~1.0" }, "require-dev": { - "cache/integration-tests": "dev-master", - "fabpot/php-cs-fixer": "~1.0", - "phpunit/phpunit": "~4.8" + "friendsofphp/php-cs-fixer": "~1.0", + "phpunit/phpunit": "~4.8|~5.0|~6.0" }, "suggest": { "ext-apc": ">=3.1.1", @@ -1233,9 +1197,10 @@ "mysql", "postgresql", "protection", + "psr-16", "psr-6", "psr-cache", - "psr6", + "psr-simple-cache", "redis", "rollback", "sql", @@ -1246,20 +1211,20 @@ "transactional", "value" ], - "time": "2016-05-09 18:41:33" + "time": "2017-03-01 13:56:52" }, { "name": "monolog/monolog", - "version": "1.19.0", + "version": "1.22.1", "source": { "type": "git", "url": "https://github.com/Seldaek/monolog.git", - "reference": "5f56ed5212dc509c8dc8caeba2715732abb32dbf" + "reference": "1e044bc4b34e91743943479f1be7a1d5eb93add0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/5f56ed5212dc509c8dc8caeba2715732abb32dbf", - "reference": "5f56ed5212dc509c8dc8caeba2715732abb32dbf", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/1e044bc4b34e91743943479f1be7a1d5eb93add0", + "reference": "1e044bc4b34e91743943479f1be7a1d5eb93add0", "shasum": "" }, "require": { @@ -1270,7 +1235,7 @@ "psr/log-implementation": "1.0.0" }, "require-dev": { - "aws/aws-sdk-php": "^2.4.9", + "aws/aws-sdk-php": "^2.4.9 || ^3.0", "doctrine/couchdb": "~1.0@dev", "graylog2/gelf-php": "~1.0", "jakub-onderka/php-parallel-lint": "0.9", @@ -1278,8 +1243,8 @@ "php-console/php-console": "^3.1.3", "phpunit/phpunit": "~4.5", "phpunit/phpunit-mock-objects": "2.3.0", - "raven/raven": "^0.13", "ruflin/elastica": ">=0.90 <3.0", + "sentry/sentry": "^0.13", "swiftmailer/swiftmailer": "~5.3" }, "suggest": { @@ -1291,9 +1256,9 @@ "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", "php-console/php-console": "Allow sending log messages to Google Chrome", - "raven/raven": "Allow sending log messages to a Sentry server", "rollbar/rollbar": "Allow sending log messages to Rollbar", - "ruflin/elastica": "Allow sending log messages to an Elastic Search server" + "ruflin/elastica": "Allow sending log messages to an Elastic Search server", + "sentry/sentry": "Allow sending log messages to a Sentry server" }, "type": "library", "extra": { @@ -1324,65 +1289,66 @@ "logging", "psr-3" ], - "time": "2016-04-12 18:29:35" + "time": "2017-03-13 07:08:03" }, { - "name": "nikic/php-parser", - "version": "v0.9.5", + "name": "psr/cache", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "ef70767475434bdb3615b43c327e2cae17ef12eb" + "url": "https://github.com/php-fig/cache.git", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/ef70767475434bdb3615b43c327e2cae17ef12eb", - "reference": "ef70767475434bdb3615b43c327e2cae17ef12eb", + "url": "https://api.github.com/repos/php-fig/cache/zipball/d11b50ad223250cf17b86e38383413f5a6764bf8", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", "shasum": "" }, "require": { - "ext-tokenizer": "*", - "php": ">=5.2" + "php": ">=5.3.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "0.9-dev" + "dev-master": "1.0.x-dev" } }, "autoload": { - "psr-0": { - "PHPParser": "lib/" + "psr-4": { + "Psr\\Cache\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Nikita Popov" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "A PHP parser written in PHP", + "description": "Common interface for caching libraries", "keywords": [ - "parser", - "php" + "cache", + "psr", + "psr-6" ], - "time": "2014-07-23 18:24:17" + "time": "2016-08-06 20:24:11" }, { - "name": "psr/cache", + "name": "psr/container", "version": "1.0.0", "source": { "type": "git", - "url": "https://github.com/php-fig/cache.git", - "reference": "9e66031f41fbbdda45ee11e93c45d480ccba3eb3" + "url": "https://github.com/php-fig/container.git", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/cache/zipball/9e66031f41fbbdda45ee11e93c45d480ccba3eb3", - "reference": "9e66031f41fbbdda45ee11e93c45d480ccba3eb3", + "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", "shasum": "" }, "require": { @@ -1396,7 +1362,7 @@ }, "autoload": { "psr-4": { - "Psr\\Cache\\": "src/" + "Psr\\Container\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -1409,26 +1375,29 @@ "homepage": "http://www.php-fig.org/" } ], - "description": "Common interface for caching libraries", + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", "keywords": [ - "cache", - "psr", - "psr-6" + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" ], - "time": "2015-12-11 02:52:07" + "time": "2017-02-14 16:28:37" }, { "name": "psr/http-message", - "version": "1.0", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/php-fig/http-message.git", - "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298" + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", - "reference": "85d63699f0dbedb190bbd4b0d2b9dc707ea4c298", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", "shasum": "" }, "require": { @@ -1456,6 +1425,7 @@ } ], "description": "Common interface for HTTP messages", + "homepage": "https://github.com/php-fig/http-message", "keywords": [ "http", "http-message", @@ -1464,26 +1434,34 @@ "request", "response" ], - "time": "2015-05-04 20:22:00" + "time": "2016-08-06 14:39:51" }, { "name": "psr/log", - "version": "1.0.0", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b" + "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/fe0936ee26643249e916849d48e3a51d5f5e278b", - "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b", + "url": "https://api.github.com/repos/php-fig/log/zipball/4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", + "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", "shasum": "" }, + "require": { + "php": ">=5.3.0" + }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, "autoload": { - "psr-0": { - "Psr\\Log\\": "" + "psr-4": { + "Psr\\Log\\": "Psr/Log/" } }, "notification-url": "https://packagist.org/downloads/", @@ -1497,25 +1475,74 @@ } ], "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", "keywords": [ "log", "psr", "psr-3" ], - "time": "2012-12-21 11:40:51" + "time": "2016-10-10 12:19:37" + }, + { + "name": "psr/simple-cache", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/simple-cache.git", + "reference": "753fa598e8f3b9966c886fe13f370baa45ef0e24" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/753fa598e8f3b9966c886fe13f370baa45ef0e24", + "reference": "753fa598e8f3b9966c886fe13f370baa45ef0e24", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\SimpleCache\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interfaces for simple caching", + "keywords": [ + "cache", + "caching", + "psr", + "psr-16", + "simple-cache" + ], + "time": "2017-01-02 13:31:39" }, { "name": "symfony/polyfill-php55", - "version": "v1.2.0", + "version": "v1.3.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php55.git", - "reference": "bf2ff9ad6be1a4772cb873e4eea94d70daa95c6d" + "reference": "03e3f0350bca2220e3623a0e340eef194405fc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php55/zipball/bf2ff9ad6be1a4772cb873e4eea94d70daa95c6d", - "reference": "bf2ff9ad6be1a4772cb873e4eea94d70daa95c6d", + "url": "https://api.github.com/repos/symfony/polyfill-php55/zipball/03e3f0350bca2220e3623a0e340eef194405fc67", + "reference": "03e3f0350bca2220e3623a0e340eef194405fc67", "shasum": "" }, "require": { @@ -1525,7 +1552,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2-dev" + "dev-master": "1.3-dev" } }, "autoload": { @@ -1558,20 +1585,20 @@ "portable", "shim" ], - "time": "2016-05-18 14:26:46" + "time": "2016-11-14 01:06:16" }, { "name": "vlucas/phpdotenv", - "version": "v2.2.1", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/vlucas/phpdotenv.git", - "reference": "63f37b9395e8041cd4313129c08ece896d06ca8e" + "reference": "3cc116adbe4b11be5ec557bf1d24dc5e3a21d18c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/63f37b9395e8041cd4313129c08ece896d06ca8e", - "reference": "63f37b9395e8041cd4313129c08ece896d06ca8e", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/3cc116adbe4b11be5ec557bf1d24dc5e3a21d18c", + "reference": "3cc116adbe4b11be5ec557bf1d24dc5e3a21d18c", "shasum": "" }, "require": { @@ -1583,7 +1610,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.2-dev" + "dev-master": "2.4-dev" } }, "autoload": { @@ -1608,20 +1635,20 @@ "env", "environment" ], - "time": "2016-04-15 10:48:49" + "time": "2016-09-01 10:05:43" }, { "name": "zendframework/zend-diactoros", - "version": "1.3.5", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/zendframework/zend-diactoros.git", - "reference": "b1d59735b672865dbeb930805029c24f226e3e77" + "reference": "b03f285a333f51e58c95cce54109a4a9ed691436" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-diactoros/zipball/b1d59735b672865dbeb930805029c24f226e3e77", - "reference": "b1d59735b672865dbeb930805029c24f226e3e77", + "url": "https://api.github.com/repos/zendframework/zend-diactoros/zipball/b03f285a333f51e58c95cce54109a4a9ed691436", + "reference": "b03f285a333f51e58c95cce54109a4a9ed691436", "shasum": "" }, "require": { @@ -1629,17 +1656,19 @@ "psr/http-message": "~1.0" }, "provide": { - "psr/http-message-implementation": "~1.0.0" + "psr/http-message-implementation": "1.0" }, "require-dev": { - "phpunit/phpunit": "~4.6", - "squizlabs/php_codesniffer": "^2.3.1" + "ext-dom": "*", + "ext-libxml": "*", + "phpunit/phpunit": "^4.6 || ^5.5", + "zendframework/zend-coding-standard": "~1.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev", - "dev-develop": "1.4-dev" + "dev-master": "1.4-dev", + "dev-develop": "1.5-dev" } }, "autoload": { @@ -1658,166 +1687,31 @@ "psr", "psr-7" ], - "time": "2016-03-17 18:02:05" + "time": "2017-04-06 16:18:34" } ], "packages-dev": [ - { - "name": "andrewsville/php-token-reflection", - "version": "1.4.0", - "source": { - "type": "git", - "url": "https://github.com/Andrewsville/PHP-Token-Reflection.git", - "reference": "e6d0ac2baf66cdf154be34c3d2a2aa1bd4b426ee" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Andrewsville/PHP-Token-Reflection/zipball/e6d0ac2baf66cdf154be34c3d2a2aa1bd4b426ee", - "reference": "e6d0ac2baf66cdf154be34c3d2a2aa1bd4b426ee", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.3.0" - }, - "type": "library", - "autoload": { - "psr-0": { - "TokenReflection": "./" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3" - ], - "authors": [ - { - "name": "Ondřej Nešpor", - "homepage": "https://github.com/andrewsville" - }, - { - "name": "Jaroslav Hanslík", - "homepage": "https://github.com/kukulich" - } - ], - "description": "Library emulating the PHP internal reflection using just the tokenized source code.", - "homepage": "http://andrewsville.github.com/PHP-Token-Reflection/", - "keywords": [ - "library", - "reflection", - "tokenizer" - ], - "time": "2014-08-06 16:37:08" - }, - { - "name": "apigen/apigen", - "version": "v4.0.1", - "source": { - "type": "git", - "url": "https://github.com/ApiGen/ApiGen.git", - "reference": "b719a6ad49107b5bc0bdf9fc8fae219a9a6dd5f1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/ApiGen/ApiGen/zipball/b719a6ad49107b5bc0bdf9fc8fae219a9a6dd5f1", - "reference": "b719a6ad49107b5bc0bdf9fc8fae219a9a6dd5f1", - "shasum": "" - }, - "require": { - "andrewsville/php-token-reflection": "~1.4", - "herrera-io/phar-update": "~2.0", - "kdyby/events": "~2.0", - "kukulich/fshl": "~2.1", - "latte/latte": "~2.2", - "michelf/php-markdown": "~1.4", - "nette/application": "~2.2", - "nette/bootstrap": "~2.2", - "nette/di": "~2.2", - "nette/mail": "~2.2", - "nette/neon": "~2.2", - "nette/robot-loader": "~2.2", - "nette/safe-stream": "~2.2", - "php": ">=5.4", - "symfony/console": "~2.6", - "symfony/options-resolver": "~2.6.1", - "tracy/tracy": "~2.2" - }, - "require-dev": { - "jakub-onderka/php-parallel-lint": "~0.8", - "mockery/mockery": "~0.9", - "phpunit/phpunit": "~4.4", - "zenify/coding-standard": "~3.0" - }, - "bin": [ - "bin/apigen" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.0.0-dev" - } - }, - "autoload": { - "psr-4": { - "ApiGen\\": "src/ApiGen" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "http://davidgrudl.com" - }, - { - "name": "Ondřej Nešpor", - "homepage": "https://github.com/andrewsville" - }, - { - "name": "Jaroslav Hanslík", - "homepage": "https://github.com/kukulich" - }, - { - "name": "Tomáš Votruba", - "email": "tomas.vot@gmail.com" - }, - { - "name": "Olivier Laviale", - "homepage": "https://github.com/olvlvl" - } - ], - "description": "PHP source code API generator", - "homepage": "http://apigen.org/", - "keywords": [ - "api", - "documentation", - "generator", - "phpdoc" - ], - "time": "2015-03-09 11:03:45" - }, { "name": "behat/gherkin", - "version": "v4.4.1", + "version": "v4.4.5", "source": { "type": "git", "url": "https://github.com/Behat/Gherkin.git", - "reference": "1576b485c0f92ef6d27da9c4bbfc57ee30cf6911" + "reference": "5c14cff4f955b17d20d088dec1bde61c0539ec74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Behat/Gherkin/zipball/1576b485c0f92ef6d27da9c4bbfc57ee30cf6911", - "reference": "1576b485c0f92ef6d27da9c4bbfc57ee30cf6911", + "url": "https://api.github.com/repos/Behat/Gherkin/zipball/5c14cff4f955b17d20d088dec1bde61c0539ec74", + "reference": "5c14cff4f955b17d20d088dec1bde61c0539ec74", "shasum": "" }, "require": { "php": ">=5.3.1" }, "require-dev": { - "phpunit/phpunit": "~4.0", - "symfony/yaml": "~2.1" + "phpunit/phpunit": "~4.5|~5", + "symfony/phpunit-bridge": "~2.7|~3", + "symfony/yaml": "~2.3|~3" }, "suggest": { "symfony/yaml": "If you want to parse features, represented in YAML files" @@ -1854,20 +1748,20 @@ "gherkin", "parser" ], - "time": "2015-12-30 14:47:00" + "time": "2016-10-30 11:50:56" }, { "name": "codeception/codeception", - "version": "2.2.1", + "version": "2.2.10", "source": { "type": "git", "url": "https://github.com/Codeception/Codeception.git", - "reference": "f137636f0c185e7d4a495b9cea70c1afae27dfc7" + "reference": "c32a3f92834db08ceedb4666ea2265c3aa43396e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Codeception/Codeception/zipball/f137636f0c185e7d4a495b9cea70c1afae27dfc7", - "reference": "f137636f0c185e7d4a495b9cea70c1afae27dfc7", + "url": "https://api.github.com/repos/Codeception/Codeception/zipball/c32a3f92834db08ceedb4666ea2265c3aa43396e", + "reference": "c32a3f92834db08ceedb4666ea2265c3aa43396e", "shasum": "" }, "require": { @@ -1878,19 +1772,22 @@ "guzzlehttp/guzzle": ">=4.1.4 <7.0", "guzzlehttp/psr7": "~1.0", "php": ">=5.4.0 <8.0", - "phpunit/php-code-coverage": ">=2.1.3", - "phpunit/phpunit": ">4.8.20 <5.5", + "phpunit/php-code-coverage": ">=2.2.4 <5.0", + "phpunit/phpunit": ">4.8.20 <6.0", + "sebastian/comparator": "~1.1", + "sebastian/diff": "^1.4", + "stecman/symfony-console-completion": "^0.7.0", "symfony/browser-kit": ">=2.7 <4.0", "symfony/console": ">=2.7 <4.0", "symfony/css-selector": ">=2.7 <4.0", - "symfony/dom-crawler": ">=2.7 <4.0", + "symfony/dom-crawler": ">=2.7.5 <4.0", "symfony/event-dispatcher": ">=2.7 <4.0", "symfony/finder": ">=2.7 <4.0", "symfony/yaml": ">=2.7 <4.0" }, "require-dev": { "codeception/specify": "~0.3", - "facebook/php-sdk-v4": "~5.0", + "facebook/graph-sdk": "~5.3", "flow/jsonpath": "~0.2", "league/factory-muffin": "^3.0", "league/factory-muffin-faker": "^1.0", @@ -1899,7 +1796,8 @@ "pda/pheanstalk": "~3.0", "php-amqplib/php-amqplib": "~2.4", "predis/predis": "^1.0", - "squizlabs/php_codesniffer": "~2.0" + "squizlabs/php_codesniffer": "~2.0", + "vlucas/phpdotenv": "^2.4.0" }, "suggest": { "codeception/specify": "BDD-style code blocks", @@ -1943,7 +1841,7 @@ "functional testing", "unit testing" ], - "time": "2016-06-03 12:44:06" + "time": "2017-03-25 03:19:52" }, { "name": "codeception/mockery-module", @@ -1986,42 +1884,42 @@ "time": "2015-09-24 19:28:29" }, { - "name": "codegyre/robo", - "version": "0.6.0", + "name": "consolidation/annotated-command", + "version": "2.4.8", "source": { "type": "git", - "url": "https://github.com/consolidation-org/Robo.git", - "reference": "d18185f0494c854d36aa5ee0ad931ee23bbef552" + "url": "https://github.com/consolidation/annotated-command.git", + "reference": "6672ea38212f8bffb71fec7eadc8b3372154b17e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/consolidation-org/Robo/zipball/d18185f0494c854d36aa5ee0ad931ee23bbef552", - "reference": "d18185f0494c854d36aa5ee0ad931ee23bbef552", + "url": "https://api.github.com/repos/consolidation/annotated-command/zipball/6672ea38212f8bffb71fec7eadc8b3372154b17e", + "reference": "6672ea38212f8bffb71fec7eadc8b3372154b17e", "shasum": "" }, "require": { - "henrikbjorn/lurker": "1.0.*@dev", + "consolidation/output-formatters": "^3.1.5", "php": ">=5.4.0", - "symfony/console": "~2.5", - "symfony/filesystem": "~2.5", - "symfony/finder": "~2.5", - "symfony/process": "~2.5" + "phpdocumentor/reflection-docblock": "^2.0|^3.0.2", + "psr/log": "^1", + "symfony/console": "^2.8|~3", + "symfony/event-dispatcher": "^2.5|^3", + "symfony/finder": "^2.5|^3" }, "require-dev": { - "codeception/aspect-mock": "0.5.*", - "codeception/base": "~2.1", - "codeception/codeception": "2.1", - "codeception/verify": "0.2.*", - "natxet/cssmin": "~3.0", - "patchwork/jsqueeze": "~1.0" + "phpunit/phpunit": "^4.8", + "satooshi/php-coveralls": "^1.0", + "squizlabs/php_codesniffer": "^2.7" }, - "bin": [ - "robo" - ], "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.x-dev" + } + }, "autoload": { "psr-4": { - "Robo\\": "src" + "Consolidation\\AnnotatedCommand\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -2030,12 +1928,246 @@ ], "authors": [ { - "name": "Davert", + "name": "Greg Anderson", + "email": "greg.1.anderson@greenknowe.org" + } + ], + "description": "Initialize Symfony Console commands from annotated command class methods.", + "time": "2017-04-03 22:37:00" + }, + { + "name": "consolidation/log", + "version": "1.0.3", + "source": { + "type": "git", + "url": "https://github.com/consolidation/log.git", + "reference": "74ba81b4edc585616747cc5c5309ce56fec41254" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/consolidation/log/zipball/74ba81b4edc585616747cc5c5309ce56fec41254", + "reference": "74ba81b4edc585616747cc5c5309ce56fec41254", + "shasum": "" + }, + "require": { + "php": ">=5.5.0", + "psr/log": "~1.0", + "symfony/console": "~2.5|~3.0" + }, + "require-dev": { + "phpunit/phpunit": "4.*", + "squizlabs/php_codesniffer": "2.*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Consolidation\\Log\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Greg Anderson", + "email": "greg.1.anderson@greenknowe.org" + } + ], + "description": "Improved Psr-3 / Psr\\Log logger based on Symfony Console components.", + "time": "2016-03-23 23:46:42" + }, + { + "name": "consolidation/output-formatters", + "version": "3.1.8", + "source": { + "type": "git", + "url": "https://github.com/consolidation/output-formatters.git", + "reference": "0b50ba1134d581fd55376f3e21508dab009ced47" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/consolidation/output-formatters/zipball/0b50ba1134d581fd55376f3e21508dab009ced47", + "reference": "0b50ba1134d581fd55376f3e21508dab009ced47", + "shasum": "" + }, + "require": { + "php": ">=5.4.0", + "symfony/console": "^2.8|~3", + "symfony/finder": "~2.5|~3.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8", + "satooshi/php-coveralls": "^1.0", + "squizlabs/php_codesniffer": "^2.7", + "victorjonsson/markdowndocs": "^1.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.x-dev" + } + }, + "autoload": { + "psr-4": { + "Consolidation\\OutputFormatters\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Greg Anderson", + "email": "greg.1.anderson@greenknowe.org" + } + ], + "description": "Format text by applying transformations provided by plug-in formatters.", + "time": "2017-03-01 20:54:45" + }, + { + "name": "consolidation/robo", + "version": "1.0.6", + "source": { + "type": "git", + "url": "https://github.com/consolidation/Robo.git", + "reference": "de6225256b2ed88822af1cd8cc3a01bf933add8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/consolidation/Robo/zipball/de6225256b2ed88822af1cd8cc3a01bf933add8c", + "reference": "de6225256b2ed88822af1cd8cc3a01bf933add8c", + "shasum": "" + }, + "require": { + "consolidation/annotated-command": "^2.2", + "consolidation/log": "~1", + "consolidation/output-formatters": "^3.1.5", + "dflydev/dot-access-data": "^1.1.0", + "grasmash/yaml-expander": "^1.1", + "league/container": "^2.2", + "php": ">=5.5.0", + "squizlabs/php_codesniffer": "^2.8", + "symfony/console": "~2.8|~3.0", + "symfony/event-dispatcher": "~2.5|~3.0", + "symfony/filesystem": "~2.5|~3.0", + "symfony/finder": "~2.5|~3.0", + "symfony/process": "~2.5|~3.0" + }, + "replace": { + "codegyre/robo": "< 1.0" + }, + "require-dev": { + "codeception/aspect-mock": "~1", + "codeception/base": "^2.2.6", + "codeception/verify": "^0.3.2", + "henrikbjorn/lurker": "~1", + "natxet/cssmin": "~3", + "patchwork/jsqueeze": "~2", + "pear/archive_tar": "^1.4.2", + "phpunit/php-code-coverage": "~2|~4", + "satooshi/php-coveralls": "~1" + }, + "suggest": { + "henrikbjorn/lurker": "For monitoring filesystem changes in taskWatch", + "natxet/CssMin": "For minifying JS files in taskMinify", + "patchwork/jsqueeze": "For minifying JS files in taskMinify", + "pear/archive_tar": "Allows tar archives to be created and extracted in taskPack and taskExtract, respectively." + }, + "bin": [ + "robo" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "classmap": [ + "scripts/composer/ScriptHandler.php" + ], + "psr-4": { + "Robo\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Davert", "email": "davert.php@resend.cc" } ], "description": "Modern task runner", - "time": "2015-10-30 11:29:52" + "time": "2017-03-31 18:23:36" + }, + { + "name": "dflydev/dot-access-data", + "version": "v1.1.0", + "source": { + "type": "git", + "url": "https://github.com/dflydev/dflydev-dot-access-data.git", + "reference": "3fbd874921ab2c041e899d044585a2ab9795df8a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/dflydev/dflydev-dot-access-data/zipball/3fbd874921ab2c041e899d044585a2ab9795df8a", + "reference": "3fbd874921ab2c041e899d044585a2ab9795df8a", + "shasum": "" + }, + "require": { + "php": ">=5.3.2" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-0": { + "Dflydev\\DotAccessData": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Dragonfly Development Inc.", + "email": "info@dflydev.com", + "homepage": "http://dflydev.com" + }, + { + "name": "Beau Simensen", + "email": "beau@dflydev.com", + "homepage": "http://beausimensen.com" + }, + { + "name": "Carlos Frutos", + "email": "carlos@kiwing.it", + "homepage": "https://github.com/cfrutos" + } + ], + "description": "Given a deep data structure, access data by dot notation.", + "homepage": "https://github.com/dflydev/dflydev-dot-access-data", + "keywords": [ + "access", + "data", + "dot", + "notation" + ], + "time": "2017-01-20 21:14:22" }, { "name": "doctrine/instantiator", @@ -2093,23 +2225,29 @@ }, { "name": "facebook/webdriver", - "version": "1.1.1", + "version": "1.3.0", "source": { "type": "git", "url": "https://github.com/facebook/php-webdriver.git", - "reference": "1c98108ba3eb435b681655764de11502a0653705" + "reference": "77300c4ab2025d4316635f592ec849ca7323bd8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/facebook/php-webdriver/zipball/1c98108ba3eb435b681655764de11502a0653705", - "reference": "1c98108ba3eb435b681655764de11502a0653705", + "url": "https://api.github.com/repos/facebook/php-webdriver/zipball/77300c4ab2025d4316635f592ec849ca7323bd8c", + "reference": "77300c4ab2025d4316635f592ec849ca7323bd8c", "shasum": "" }, "require": { - "php": ">=5.3.19" + "ext-curl": "*", + "php": "^5.5 || ~7.0", + "symfony/process": "^2.8 || ^3.1" }, "require-dev": { - "phpunit/phpunit": "4.6.*" + "friendsofphp/php-cs-fixer": "^1.11", + "php-mock/php-mock-phpunit": "^1.1", + "phpunit/phpunit": "4.6.* || ~5.0", + "satooshi/php-coveralls": "^1.0", + "squizlabs/php_codesniffer": "^2.6" }, "suggest": { "phpdocumentor/phpdocumentor": "2.*" @@ -2132,7 +2270,55 @@ "selenium", "webdriver" ], - "time": "2015-12-31 15:58:49" + "time": "2017-01-13 15:48:08" + }, + { + "name": "grasmash/yaml-expander", + "version": "1.1.0", + "source": { + "type": "git", + "url": "https://github.com/grasmash/yaml-expander.git", + "reference": "95f9c876ca31f31bf5bfd9c8e89cc1f065c45528" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/grasmash/yaml-expander/zipball/95f9c876ca31f31bf5bfd9c8e89cc1f065c45528", + "reference": "95f9c876ca31f31bf5bfd9c8e89cc1f065c45528", + "shasum": "" + }, + "require": { + "dflydev/dot-access-data": "^1.1.0", + "php": ">=5.4", + "symfony/console": "^2.8.11|^3", + "symfony/yaml": "^2.8.11|^3" + }, + "require-dev": { + "phpunit/phpunit": "^4.8|^5.5.4", + "satooshi/php-coveralls": "^1.0", + "squizlabs/php_codesniffer": "^2.7" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Grasmash\\YamlExpander\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Matthew Grasmick" + } + ], + "description": "Expands internal property references in a yaml file.", + "time": "2017-03-24 20:31:04" }, { "name": "greencape/coding-standards", @@ -2225,332 +2411,105 @@ "time": "2015-05-11 14:41:42" }, { - "name": "henrikbjorn/lurker", - "version": "1.0.0", + "name": "hoa/compiler", + "version": "2.15.10.29", "source": { "type": "git", - "url": "https://github.com/flint/Lurker.git", - "reference": "a020d45b3bc37810aeafe27343c51af8a74c9419" + "url": "https://github.com/hoaproject/Compiler.git", + "reference": "ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/flint/Lurker/zipball/a020d45b3bc37810aeafe27343c51af8a74c9419", - "reference": "a020d45b3bc37810aeafe27343c51af8a74c9419", + "url": "https://api.github.com/repos/hoaproject/Compiler/zipball/ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39", + "reference": "ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39", "shasum": "" }, "require": { - "php": ">=5.3.3", - "symfony/config": "~2.2", - "symfony/event-dispatcher": "~2.2" + "hoa/core": "~2.0", + "hoa/file": "~0.0", + "hoa/iterator": "~1.0", + "hoa/math": "~0.0", + "hoa/regex": "~0.0", + "hoa/visitor": "~1.0" }, - "suggest": { - "ext-inotify": ">=0.1.6" + "require-dev": { + "hoa/json": "~1.0", + "hoa/test": "~1.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.x-dev" } }, "autoload": { - "psr-0": { - "Lurker": "src" + "psr-4": { + "Hoa\\Compiler\\": "." } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Yaroslav Kiliba", - "email": "om.dattaya@gmail.com" - }, - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com" + "name": "Ivan Enderlin", + "email": "ivan.enderlin@hoa-project.net" }, { - "name": "Henrik Bjrnskov", - "email": "henrik@bjrnskov.dk" + "name": "Hoa community", + "homepage": "http://hoa-project.net/" } ], - "description": "Resource Watcher.", + "description": "The Hoa\\Compiler library.", + "homepage": "http://hoa-project.net/", "keywords": [ - "filesystem", - "resource", - "watching" + "algebraic", + "ast", + "compiler", + "context-free", + "coverage", + "exhaustive", + "grammar", + "isotropic", + "language", + "lexer", + "library", + "ll1", + "llk", + "parser", + "pp", + "random", + "regular", + "rule", + "sampler", + "syntax", + "token", + "trace", + "uniform" ], - "time": "2013-05-24 06:47:29" + "time": "2015-10-29 21:35:12" }, { - "name": "herrera-io/json", - "version": "1.0.3", + "name": "hoa/core", + "version": "2.15.11.09", "source": { "type": "git", - "url": "https://github.com/kherge-abandoned/php-json.git", - "reference": "60c696c9370a1e5136816ca557c17f82a6fa83f1" + "url": "https://github.com/hoaproject/Core.git", + "reference": "5538b1e90e2c66c90df5cc45e03fb85d047be900" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/kherge-abandoned/php-json/zipball/60c696c9370a1e5136816ca557c17f82a6fa83f1", - "reference": "60c696c9370a1e5136816ca557c17f82a6fa83f1", + "url": "https://api.github.com/repos/hoaproject/Core/zipball/5538b1e90e2c66c90df5cc45e03fb85d047be900", + "reference": "5538b1e90e2c66c90df5cc45e03fb85d047be900", "shasum": "" }, "require": { - "ext-json": "*", - "justinrainbow/json-schema": ">=1.0,<2.0-dev", - "php": ">=5.3.3", - "seld/jsonlint": ">=1.0,<2.0-dev" + "ext-spl": "*", + "php": ">=5.4.0" }, "require-dev": { - "herrera-io/phpunit-test-case": "1.*", - "mikey179/vfsstream": "1.1.0", - "phpunit/phpunit": "3.7.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0-dev" - } - }, - "autoload": { - "files": [ - "src/lib/json_version.php" - ], - "psr-0": { - "Herrera\\Json": "src/lib" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Kevin Herrera", - "email": "kevin@herrera.io", - "homepage": "http://kevin.herrera.io" - } - ], - "description": "A library for simplifying JSON linting and validation.", - "homepage": "http://herrera-io.github.com/php-json", - "keywords": [ - "json", - "lint", - "schema", - "validate" - ], - "time": "2013-10-30 16:51:34" - }, - { - "name": "herrera-io/phar-update", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/kherge-abandoned/php-phar-update.git", - "reference": "15643c90d3d43620a4f45c910e6afb7a0ad4b488" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/kherge-abandoned/php-phar-update/zipball/15643c90d3d43620a4f45c910e6afb7a0ad4b488", - "reference": "15643c90d3d43620a4f45c910e6afb7a0ad4b488", - "shasum": "" - }, - "require": { - "herrera-io/json": "1.*", - "herrera-io/version": "1.*", - "php": ">=5.3.3" - }, - "require-dev": { - "herrera-io/phpunit-test-case": "1.*", - "mikey179/vfsstream": "1.1.0", - "phpunit/phpunit": "3.7.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "files": [ - "src/lib/constants.php" - ], - "psr-0": { - "Herrera\\Phar\\Update": "src/lib" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Kevin Herrera", - "email": "kevin@herrera.io", - "homepage": "http://kevin.herrera.io" - } - ], - "description": "A library for self-updating Phars.", - "homepage": "http://herrera-io.github.com/php-phar-update", - "keywords": [ - "phar", - "update" - ], - "time": "2013-11-09 17:13:13" - }, - { - "name": "herrera-io/version", - "version": "1.1.1", - "source": { - "type": "git", - "url": "https://github.com/kherge-abandoned/php-version.git", - "reference": "d39d9642b92a04d8b8a28b871b797a35a2545e85" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/kherge-abandoned/php-version/zipball/d39d9642b92a04d8b8a28b871b797a35a2545e85", - "reference": "d39d9642b92a04d8b8a28b871b797a35a2545e85", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "herrera-io/phpunit-test-case": "1.*", - "phpunit/phpunit": "3.7.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "autoload": { - "psr-0": { - "Herrera\\Version": "src/lib" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Kevin Herrera", - "email": "kevin@herrera.io", - "homepage": "http://kevin.herrera.io" - } - ], - "description": "A library for creating, editing, and comparing semantic versioning numbers.", - "homepage": "http://github.com/herrera-io/php-version", - "keywords": [ - "semantic", - "version" - ], - "time": "2014-05-27 05:29:25" - }, - { - "name": "hoa/compiler", - "version": "2.15.10.29", - "source": { - "type": "git", - "url": "https://github.com/hoaproject/Compiler.git", - "reference": "ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/hoaproject/Compiler/zipball/ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39", - "reference": "ec0849fd3c1472fbcd86c3c961981f0cfe1f8d39", - "shasum": "" - }, - "require": { - "hoa/core": "~2.0", - "hoa/file": "~0.0", - "hoa/iterator": "~1.0", - "hoa/math": "~0.0", - "hoa/regex": "~0.0", - "hoa/visitor": "~1.0" - }, - "require-dev": { - "hoa/json": "~1.0", - "hoa/test": "~1.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Hoa\\Compiler\\": "." - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Ivan Enderlin", - "email": "ivan.enderlin@hoa-project.net" - }, - { - "name": "Hoa community", - "homepage": "http://hoa-project.net/" - } - ], - "description": "The Hoa\\Compiler library.", - "homepage": "http://hoa-project.net/", - "keywords": [ - "algebraic", - "ast", - "compiler", - "context-free", - "coverage", - "exhaustive", - "grammar", - "isotropic", - "language", - "lexer", - "library", - "ll1", - "llk", - "parser", - "pp", - "random", - "regular", - "rule", - "sampler", - "syntax", - "token", - "trace", - "uniform" - ], - "time": "2015-10-29 21:35:12" - }, - { - "name": "hoa/core", - "version": "2.15.11.09", - "source": { - "type": "git", - "url": "https://github.com/hoaproject/Core.git", - "reference": "5538b1e90e2c66c90df5cc45e03fb85d047be900" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/hoaproject/Core/zipball/5538b1e90e2c66c90df5cc45e03fb85d047be900", - "reference": "5538b1e90e2c66c90df5cc45e03fb85d047be900", - "shasum": "" - }, - "require": { - "ext-spl": "*", - "php": ">=5.4.0" - }, - "require-dev": { - "hoa/test": "~1.0" + "hoa/test": "~1.0" }, "suggest": { "ext-mbstring": "ext/mbstring must be present (or a third implementation).", @@ -2875,1461 +2834,420 @@ "homepage": "http://hoa-project.net/" } ], - "description": "The Hoa\\Ruler library.", - "homepage": "http://hoa-project.net/", - "keywords": [ - "library", - "ruler" - ], - "time": "2015-11-09 06:58:52" - }, - { - "name": "hoa/stream", - "version": "0.15.10.26", - "source": { - "type": "git", - "url": "https://github.com/hoaproject/Stream.git", - "reference": "3bc446bc00849bf51166adc415d77aa375d48d8c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/hoaproject/Stream/zipball/3bc446bc00849bf51166adc415d77aa375d48d8c", - "reference": "3bc446bc00849bf51166adc415d77aa375d48d8c", - "shasum": "" - }, - "require": { - "hoa/core": "~2.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Hoa\\Stream\\": "." - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Ivan Enderlin", - "email": "ivan.enderlin@hoa-project.net" - }, - { - "name": "Hoa community", - "homepage": "http://hoa-project.net/" - } - ], - "description": "The Hoa\\Stream library.", - "homepage": "http://hoa-project.net/", - "keywords": [ - "Context", - "bucket", - "composite", - "filter", - "in", - "library", - "out", - "protocol", - "stream", - "wrapper" - ], - "time": "2015-10-26 12:21:43" - }, - { - "name": "hoa/ustring", - "version": "3.15.11.09", - "source": { - "type": "git", - "url": "https://github.com/hoaproject/Ustring.git", - "reference": "8506be4910212b1a2beb9014763a8a4fbd871001" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/hoaproject/Ustring/zipball/8506be4910212b1a2beb9014763a8a4fbd871001", - "reference": "8506be4910212b1a2beb9014763a8a4fbd871001", - "shasum": "" - }, - "require": { - "hoa/core": "~2.0" - }, - "require-dev": { - "hoa/test": "~1.0" - }, - "suggest": { - "ext-iconv": "ext/iconv must be present (or a third implementation) to use Hoa\\Ustring::transcode().", - "ext-intl": "To get a better Hoa\\Ustring::toAscii() and Hoa\\Ustring::compareTo()." - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Hoa\\Ustring\\": "." - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Ivan Enderlin", - "email": "ivan.enderlin@hoa-project.net" - }, - { - "name": "Hoa community", - "homepage": "http://hoa-project.net/" - } - ], - "description": "The Hoa\\Ustring library.", - "homepage": "http://hoa-project.net/", - "keywords": [ - "library", - "search", - "string", - "unicode" - ], - "time": "2015-11-09 06:44:33" - }, - { - "name": "hoa/visitor", - "version": "1.15.08.17", - "source": { - "type": "git", - "url": "https://github.com/hoaproject/Visitor.git", - "reference": "e30bfff741f71979f6476a41548e34afe8053c67" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/hoaproject/Visitor/zipball/e30bfff741f71979f6476a41548e34afe8053c67", - "reference": "e30bfff741f71979f6476a41548e34afe8053c67", - "shasum": "" - }, - "require": { - "hoa/core": "~2.0" - }, - "require-dev": { - "hoa/test": "~1.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Hoa\\Visitor\\": "." - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Ivan Enderlin", - "email": "ivan.enderlin@hoa-project.net" - }, - { - "name": "Hoa community", - "homepage": "http://hoa-project.net/" - } - ], - "description": "The Hoa\\Visitor library.", - "homepage": "http://hoa-project.net/", - "keywords": [ - "library", - "structure", - "visit", - "visitor" - ], - "time": "2015-08-17 06:30:58" - }, - { - "name": "justinrainbow/json-schema", - "version": "1.6.1", - "source": { - "type": "git", - "url": "https://github.com/justinrainbow/json-schema.git", - "reference": "cc84765fb7317f6b07bd8ac78364747f95b86341" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/cc84765fb7317f6b07bd8ac78364747f95b86341", - "reference": "cc84765fb7317f6b07bd8ac78364747f95b86341", - "shasum": "" - }, - "require": { - "php": ">=5.3.29" - }, - "require-dev": { - "json-schema/json-schema-test-suite": "1.1.0", - "phpdocumentor/phpdocumentor": "~2", - "phpunit/phpunit": "~3.7" - }, - "bin": [ - "bin/validate-json" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6.x-dev" - } - }, - "autoload": { - "psr-4": { - "JsonSchema\\": "src/JsonSchema/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Bruno Prieto Reis", - "email": "bruno.p.reis@gmail.com" - }, - { - "name": "Justin Rainbow", - "email": "justin.rainbow@gmail.com" - }, - { - "name": "Igor Wiedler", - "email": "igor@wiedler.ch" - }, - { - "name": "Robert Schönthal", - "email": "seroscho@googlemail.com" - } - ], - "description": "A library to validate a json schema.", - "homepage": "https://github.com/justinrainbow/json-schema", - "keywords": [ - "json", - "schema" - ], - "time": "2016-01-25 15:43:01" - }, - { - "name": "kdyby/events", - "version": "v2.4.1", - "source": { - "type": "git", - "url": "https://github.com/Kdyby/Events.git", - "reference": "d8a0e8a64a59f501996f8f9591aa3f950208f091" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Kdyby/Events/zipball/d8a0e8a64a59f501996f8f9591aa3f950208f091", - "reference": "d8a0e8a64a59f501996f8f9591aa3f950208f091", - "shasum": "" - }, - "require": { - "nette/di": "~2.3@dev", - "nette/utils": "~2.3@dev" - }, - "require-dev": { - "latte/latte": "~2.3@dev", - "nette/application": "~2.3@dev", - "nette/bootstrap": "~2.3@dev", - "nette/caching": "~2.3@dev", - "nette/component-model": "~2.2@dev", - "nette/database": "~2.3@dev", - "nette/deprecated": "~2.3@dev", - "nette/di": "~2.3@dev", - "nette/finder": "~2.3@dev", - "nette/forms": "~2.3@dev", - "nette/http": "~2.3@dev", - "nette/mail": "~2.3@dev", - "nette/neon": "~2.3@dev", - "nette/php-generator": "~2.3@dev", - "nette/reflection": "~2.3@dev", - "nette/robot-loader": "~2.3@dev", - "nette/safe-stream": "~2.3@dev", - "nette/security": "~2.3@dev", - "nette/tester": "~1.4", - "nette/tokenizer": "~2.2@dev", - "nette/utils": "~2.3@dev", - "symfony/event-dispatcher": "~2.3", - "tracy/tracy": "~2.3@dev" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.4-dev" - } - }, - "autoload": { - "psr-0": { - "Kdyby\\Events\\": "src/" - }, - "classmap": [ - "src/Kdyby/Events/exceptions.php" - ], - "files": [ - "src/Doctrine/compatibility.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "Filip Procházka", - "email": "filip@prochazka.su", - "homepage": "http://filip-prochazka.com" - } - ], - "description": "Events for Nette Framework", - "homepage": "http://kdyby.org", - "keywords": [ - "kdyby", - "nette" - ], - "time": "2016-04-19 11:19:31" - }, - { - "name": "kukulich/fshl", - "version": "2.1.0", - "source": { - "type": "git", - "url": "https://github.com/kukulich/fshl.git", - "reference": "974c294ade5d76c0c16b6fe3fd3a584ba999b24f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/kukulich/fshl/zipball/974c294ade5d76c0c16b6fe3fd3a584ba999b24f", - "reference": "974c294ade5d76c0c16b6fe3fd3a584ba999b24f", - "shasum": "" - }, - "require": { - "php": ">=5.3" - }, - "type": "library", - "autoload": { - "psr-0": { - "FSHL": "./" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0+" - ], - "authors": [ - { - "name": "Jaroslav Hanslík", - "homepage": "https://github.com/kukulich" - } - ], - "description": "FSHL is a free, open source, universal, fast syntax highlighter written in PHP.", - "homepage": "http://fshl.kukulich.cz/", - "keywords": [ - "highlight", - "library", - "syntax" - ], - "time": "2012-09-08 19:00:07" - }, - { - "name": "latte/latte", - "version": "v2.3.12", - "source": { - "type": "git", - "url": "https://github.com/nette/latte.git", - "reference": "26af8b6b68ea68bb466ce692c12b8898524456bd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/latte/zipball/26af8b6b68ea68bb466ce692c12b8898524456bd", - "reference": "26af8b6b68ea68bb466ce692c12b8898524456bd", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.3.1" - }, - "require-dev": { - "nette/tester": "~1.3" - }, - "suggest": { - "ext-fileinfo": "to use filter |datastream", - "ext-mbstring": "to use filters like lower, upper, capitalize, ..." - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Latte: the amazing template engine for PHP", - "homepage": "https://latte.nette.org", - "keywords": [ - "templating", - "twig" - ], - "time": "2016-05-30 09:11:18" - }, - { - "name": "mayflower/php-codebrowser", - "version": "1.1.2", - "source": { - "type": "git", - "url": "https://github.com/mayflower/PHP_CodeBrowser.git", - "reference": "b44cb1867211b3eb9efe8bb61a57fe782c84831f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/mayflower/PHP_CodeBrowser/zipball/b44cb1867211b3eb9efe8bb61a57fe782c84831f", - "reference": "b44cb1867211b3eb9efe8bb61a57fe782c84831f", - "shasum": "" - }, - "require": { - "monolog/monolog": "~1.7", - "phpunit/php-file-iterator": "~1.3", - "symfony/console": "~2.1|~3.0" - }, - "require-dev": { - "phploc/phploc": "*", - "phpmd/phpmd": "1.5.*", - "phpunit/phpunit": "3.7.*", - "sebastian/phpcpd": "*", - "squizlabs/php_codesniffer": "1.*" - }, - "bin": [ - "bin/phpcb" - ], - "type": "library", - "autoload": { - "psr-0": { - "PHPCodeBrowser\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Robin Gloster", - "email": "robin.gloster@mayflower.de", - "role": "developer" - } - ], - "description": "A code browser that augments the code with information from various QA tools.", - "homepage": "https://github.com/Mayflower/PHP_CodeBrowser", - "time": "2016-01-14 12:43:42" - }, - { - "name": "michelf/php-markdown", - "version": "1.6.0", - "source": { - "type": "git", - "url": "https://github.com/michelf/php-markdown.git", - "reference": "156e56ee036505ec637d761ee62dc425d807183c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/michelf/php-markdown/zipball/156e56ee036505ec637d761ee62dc425d807183c", - "reference": "156e56ee036505ec637d761ee62dc425d807183c", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-lib": "1.4.x-dev" - } - }, - "autoload": { - "psr-0": { - "Michelf": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Michel Fortin", - "email": "michel.fortin@michelf.ca", - "homepage": "https://michelf.ca/", - "role": "Developer" - }, - { - "name": "John Gruber", - "homepage": "https://daringfireball.net/" - } - ], - "description": "PHP Markdown", - "homepage": "https://michelf.ca/projects/php-markdown/", - "keywords": [ - "markdown" - ], - "time": "2015-12-24 01:37:31" - }, - { - "name": "mockery/mockery", - "version": "0.9.5", - "source": { - "type": "git", - "url": "https://github.com/padraic/mockery.git", - "reference": "4db079511a283e5aba1b3c2fb19037c645e70fc2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/padraic/mockery/zipball/4db079511a283e5aba1b3c2fb19037c645e70fc2", - "reference": "4db079511a283e5aba1b3c2fb19037c645e70fc2", - "shasum": "" - }, - "require": { - "hamcrest/hamcrest-php": "~1.1", - "lib-pcre": ">=7.0", - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "0.9.x-dev" - } - }, - "autoload": { - "psr-0": { - "Mockery": "library/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Pádraic Brady", - "email": "padraic.brady@gmail.com", - "homepage": "http://blog.astrumfutura.com" - }, - { - "name": "Dave Marshall", - "email": "dave.marshall@atstsolutions.co.uk", - "homepage": "http://davedevelopment.co.uk" - } - ], - "description": "Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succinct API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL). Designed as a drop in alternative to PHPUnit's phpunit-mock-objects library, Mockery is easy to integrate with PHPUnit and can operate alongside phpunit-mock-objects without the World ending.", - "homepage": "http://github.com/padraic/mockery", - "keywords": [ - "BDD", - "TDD", - "library", - "mock", - "mock objects", - "mockery", - "stub", - "test", - "test double", - "testing" - ], - "time": "2016-05-22 21:52:33" - }, - { - "name": "myclabs/deep-copy", - "version": "1.5.1", - "source": { - "type": "git", - "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "a8773992b362b58498eed24bf85005f363c34771" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/a8773992b362b58498eed24bf85005f363c34771", - "reference": "a8773992b362b58498eed24bf85005f363c34771", - "shasum": "" - }, - "require": { - "php": ">=5.4.0" - }, - "require-dev": { - "doctrine/collections": "1.*", - "phpunit/phpunit": "~4.1" - }, - "type": "library", - "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Create deep copies (clones) of your objects", - "homepage": "https://github.com/myclabs/DeepCopy", - "keywords": [ - "clone", - "copy", - "duplicate", - "object", - "object graph" - ], - "time": "2015-11-20 12:04:31" - }, - { - "name": "nette/application", - "version": "v2.3.12", - "source": { - "type": "git", - "url": "https://github.com/nette/application.git", - "reference": "bd834c6a97a86d384cb71a9f16d59d78990f61d8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/application/zipball/bd834c6a97a86d384cb71a9f16d59d78990f61d8", - "reference": "bd834c6a97a86d384cb71a9f16d59d78990f61d8", - "shasum": "" - }, - "require": { - "nette/component-model": "~2.2", - "nette/http": "~2.2", - "nette/reflection": "~2.2", - "nette/security": "~2.2", - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "latte/latte": "~2.3.9", - "nette/di": "~2.3", - "nette/forms": "~2.2", - "nette/robot-loader": "~2.2", - "nette/tester": "~1.3" - }, - "suggest": { - "latte/latte": "Allows using Latte in templates", - "nette/forms": "Allows to use Nette\\Application\\UI\\Form" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Application MVC Component", - "homepage": "https://nette.org", - "time": "2016-04-06 10:25:42" - }, - { - "name": "nette/bootstrap", - "version": "v2.3.4", - "source": { - "type": "git", - "url": "https://github.com/nette/bootstrap.git", - "reference": "e32964df66f2c5a3a50b229204f583d20c1f6829" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/bootstrap/zipball/e32964df66f2c5a3a50b229204f583d20c1f6829", - "reference": "e32964df66f2c5a3a50b229204f583d20c1f6829", - "shasum": "" - }, - "require": { - "nette/di": "~2.3", - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "latte/latte": "~2.2", - "nette/application": "~2.3", - "nette/caching": "~2.3", - "nette/database": "~2.3", - "nette/forms": "~2.3", - "nette/http": "~2.3", - "nette/mail": "~2.3", - "nette/robot-loader": "~2.2", - "nette/safe-stream": "~2.2", - "nette/security": "~2.3", - "nette/tester": "~1.3", - "tracy/tracy": "~2.3" - }, - "suggest": { - "nette/robot-loader": "to use Configurator::createRobotLoader()", - "tracy/tracy": "to use Configurator::enableDebugger()" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Bootstrap", - "homepage": "https://nette.org", - "time": "2015-11-16 20:18:31" - }, - { - "name": "nette/caching", - "version": "v2.4.4", - "source": { - "type": "git", - "url": "https://github.com/nette/caching.git", - "reference": "9bcb68939f4387a89dc7be0fb5dcaae98b87976b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/caching/zipball/9bcb68939f4387a89dc7be0fb5dcaae98b87976b", - "reference": "9bcb68939f4387a89dc7be0fb5dcaae98b87976b", - "shasum": "" - }, - "require": { - "nette/finder": "~2.2", - "nette/utils": "~2.2", - "php": ">=5.4.4" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "latte/latte": "~2.3.0", - "nette/di": "~2.3", - "nette/tester": "~1.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.4-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Caching Component", - "homepage": "https://nette.org", - "time": "2016-02-22 01:58:50" - }, - { - "name": "nette/component-model", - "version": "v2.2.4", - "source": { - "type": "git", - "url": "https://github.com/nette/component-model.git", - "reference": "07bce436051fd92d084642ce7a47f00045e0d1e5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/component-model/zipball/07bce436051fd92d084642ce7a47f00045e0d1e5", - "reference": "07bce436051fd92d084642ce7a47f00045e0d1e5", - "shasum": "" - }, - "require": { - "nette/utils": "^2.3.5", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "nette/tester": "~1.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Component Model", - "homepage": "https://nette.org", - "time": "2015-10-06 17:54:05" - }, - { - "name": "nette/di", - "version": "v2.3.10", - "source": { - "type": "git", - "url": "https://github.com/nette/di.git", - "reference": "2e361f237de2c2e0b54ad83716b605180c27f09f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/di/zipball/2e361f237de2c2e0b54ad83716b605180c27f09f", - "reference": "2e361f237de2c2e0b54ad83716b605180c27f09f", - "shasum": "" - }, - "require": { - "nette/neon": "^2.3.3", - "nette/php-generator": "^2.3.3", - "nette/utils": "^2.3.5", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "nette/tester": "^1.6" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Dependency Injection Component", - "homepage": "https://nette.org", - "time": "2016-03-11 22:33:31" - }, - { - "name": "nette/finder", - "version": "v2.3.2", - "source": { - "type": "git", - "url": "https://github.com/nette/finder.git", - "reference": "ea8e796b42d542bd90e76f5b2a41c2c86a008256" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/finder/zipball/ea8e796b42d542bd90e76f5b2a41c2c86a008256", - "reference": "ea8e796b42d542bd90e76f5b2a41c2c86a008256", - "shasum": "" - }, - "require": { - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "nette/tester": "~1.4" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette Finder: Files Searching", - "homepage": "https://nette.org", - "time": "2015-10-20 17:15:41" - }, - { - "name": "nette/http", - "version": "v2.3.6", - "source": { - "type": "git", - "url": "https://github.com/nette/http.git", - "reference": "24459307b19456706febbff8dbd033e1ff56ba04" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/http/zipball/24459307b19456706febbff8dbd033e1ff56ba04", - "reference": "24459307b19456706febbff8dbd033e1ff56ba04", - "shasum": "" - }, - "require": { - "nette/utils": "~2.2, >=2.2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "nette/di": "~2.3", - "nette/tester": "~1.4" - }, - "suggest": { - "ext-fileinfo": "to detect type of uploaded files" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Nette HTTP Component", - "homepage": "https://nette.org", - "time": "2016-04-02 17:09:25" - }, - { - "name": "nette/mail", - "version": "v2.3.5", - "source": { - "type": "git", - "url": "https://github.com/nette/mail.git", - "reference": "44491710d30db970e731c3908c491d061a0e22df" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/mail/zipball/44491710d30db970e731c3908c491d061a0e22df", - "reference": "44491710d30db970e731c3908c491d061a0e22df", - "shasum": "" - }, - "require": { - "ext-iconv": "*", - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" - }, - "require-dev": { - "nette/di": "~2.3", - "nette/tester": "~1.3" - }, - "suggest": { - "ext-fileinfo": "to detect type of attached files" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } + "description": "The Hoa\\Ruler library.", + "homepage": "http://hoa-project.net/", + "keywords": [ + "library", + "ruler" ], - "description": "Nette Mail: Sending E-mails", - "homepage": "https://nette.org", - "time": "2016-04-10 12:50:29" + "time": "2015-11-09 06:58:52" }, { - "name": "nette/neon", - "version": "v2.3.4", + "name": "hoa/stream", + "version": "0.15.10.26", "source": { "type": "git", - "url": "https://github.com/nette/neon.git", - "reference": "0042f72a2c51b24f5de3ca5f365494cd9b0d45f0" + "url": "https://github.com/hoaproject/Stream.git", + "reference": "3bc446bc00849bf51166adc415d77aa375d48d8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/neon/zipball/0042f72a2c51b24f5de3ca5f365494cd9b0d45f0", - "reference": "0042f72a2c51b24f5de3ca5f365494cd9b0d45f0", + "url": "https://api.github.com/repos/hoaproject/Stream/zipball/3bc446bc00849bf51166adc415d77aa375d48d8c", + "reference": "3bc446bc00849bf51166adc415d77aa375d48d8c", "shasum": "" }, "require": { - "ext-iconv": "*", - "php": ">=5.3.1" - }, - "require-dev": { - "nette/tester": "~1.4" + "hoa/core": "~2.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.x-dev" + } + }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Hoa\\Stream\\": "." + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "BSD-3-Clause" ], "authors": [ { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" + "name": "Ivan Enderlin", + "email": "ivan.enderlin@hoa-project.net" }, { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" + "name": "Hoa community", + "homepage": "http://hoa-project.net/" } ], - "description": "Nette NEON: parser & generator for Nette Object Notation", - "homepage": "http://ne-on.org", - "time": "2016-01-13 14:20:27" + "description": "The Hoa\\Stream library.", + "homepage": "http://hoa-project.net/", + "keywords": [ + "Context", + "bucket", + "composite", + "filter", + "in", + "library", + "out", + "protocol", + "stream", + "wrapper" + ], + "time": "2015-10-26 12:21:43" }, { - "name": "nette/php-generator", - "version": "v2.3.5", + "name": "hoa/ustring", + "version": "3.15.11.09", "source": { "type": "git", - "url": "https://github.com/nette/php-generator.git", - "reference": "224730a45e0cd6e76e692997a3d981a592f80b5d" + "url": "https://github.com/hoaproject/Ustring.git", + "reference": "8506be4910212b1a2beb9014763a8a4fbd871001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/php-generator/zipball/224730a45e0cd6e76e692997a3d981a592f80b5d", - "reference": "224730a45e0cd6e76e692997a3d981a592f80b5d", + "url": "https://api.github.com/repos/hoaproject/Ustring/zipball/8506be4910212b1a2beb9014763a8a4fbd871001", + "reference": "8506be4910212b1a2beb9014763a8a4fbd871001", "shasum": "" }, "require": { - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" + "hoa/core": "~2.0" }, "require-dev": { - "nette/tester": "~1.4" + "hoa/test": "~1.0" + }, + "suggest": { + "ext-iconv": "ext/iconv must be present (or a third implementation) to use Hoa\\Ustring::transcode().", + "ext-intl": "To get a better Hoa\\Ustring::toAscii() and Hoa\\Ustring::compareTo()." }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + } + }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Hoa\\Ustring\\": "." + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "BSD-3-Clause" ], "authors": [ { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" + "name": "Ivan Enderlin", + "email": "ivan.enderlin@hoa-project.net" }, { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" + "name": "Hoa community", + "homepage": "http://hoa-project.net/" } ], - "description": "Nette PHP Generator", - "homepage": "https://nette.org", - "time": "2015-11-29 22:14:37" + "description": "The Hoa\\Ustring library.", + "homepage": "http://hoa-project.net/", + "keywords": [ + "library", + "search", + "string", + "unicode" + ], + "time": "2015-11-09 06:44:33" }, { - "name": "nette/reflection", - "version": "v2.3.2", + "name": "hoa/visitor", + "version": "1.15.08.17", "source": { "type": "git", - "url": "https://github.com/nette/reflection.git", - "reference": "6c39adc4661f5f7b64be7ee161b8f67d8174da4d" + "url": "https://github.com/hoaproject/Visitor.git", + "reference": "e30bfff741f71979f6476a41548e34afe8053c67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/reflection/zipball/6c39adc4661f5f7b64be7ee161b8f67d8174da4d", - "reference": "6c39adc4661f5f7b64be7ee161b8f67d8174da4d", + "url": "https://api.github.com/repos/hoaproject/Visitor/zipball/e30bfff741f71979f6476a41548e34afe8053c67", + "reference": "e30bfff741f71979f6476a41548e34afe8053c67", "shasum": "" }, "require": { - "ext-tokenizer": "*", - "nette/caching": "~2.2", - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" + "hoa/core": "~2.0" }, "require-dev": { - "nette/di": "~2.3", - "nette/tester": "~1.4" + "hoa/test": "~1.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Hoa\\Visitor\\": "." + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "BSD-3-Clause" ], "authors": [ { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" + "name": "Ivan Enderlin", + "email": "ivan.enderlin@hoa-project.net" }, { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" + "name": "Hoa community", + "homepage": "http://hoa-project.net/" } ], - "description": "Nette PHP Reflection Component", - "homepage": "https://nette.org", - "time": "2016-03-12 14:57:07" + "description": "The Hoa\\Visitor library.", + "homepage": "http://hoa-project.net/", + "keywords": [ + "library", + "structure", + "visit", + "visitor" + ], + "time": "2015-08-17 06:30:58" }, { - "name": "nette/robot-loader", - "version": "v2.3.1", + "name": "league/container", + "version": "2.4.0", "source": { "type": "git", - "url": "https://github.com/nette/robot-loader.git", - "reference": "69331d359bbc9e5f911c12b82187cac914d983fb" + "url": "https://github.com/thephpleague/container.git", + "reference": "5ec434f4760d83c2a479266b618fb3e3be24c974" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/robot-loader/zipball/69331d359bbc9e5f911c12b82187cac914d983fb", - "reference": "69331d359bbc9e5f911c12b82187cac914d983fb", + "url": "https://api.github.com/repos/thephpleague/container/zipball/5ec434f4760d83c2a479266b618fb3e3be24c974", + "reference": "5ec434f4760d83c2a479266b618fb3e3be24c974", "shasum": "" }, "require": { - "nette/caching": "~2.2", - "nette/finder": "~2.3", - "nette/utils": "~2.2", - "php": ">=5.3.1" + "container-interop/container-interop": "^1.2", + "php": "^5.4.0 || ^7.0" }, - "conflict": { - "nette/nette": "<2.2" + "provide": { + "container-interop/container-interop-implementation": "^1.2", + "psr/container-implementation": "^1.0" + }, + "replace": { + "orno/di": "~2.0" }, "require-dev": { - "nette/tester": "~1.4" + "phpunit/phpunit": "4.*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-2.x": "2.x-dev", + "dev-1.x": "1.x-dev" + } + }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "League\\Container\\": "src" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "MIT" ], "authors": [ { - "name": "David Grudl", - "homepage": "http://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "http://nette.org/contributors" + "name": "Phil Bennett", + "email": "philipobenito@gmail.com", + "homepage": "http://www.philipobenito.com", + "role": "Developer" } ], - "description": "Nette RobotLoader: comfortable autoloading", - "homepage": "http://nette.org", - "time": "2015-07-11 21:20:57" + "description": "A fast and intuitive dependency injection container.", + "homepage": "https://github.com/thephpleague/container", + "keywords": [ + "container", + "dependency", + "di", + "injection", + "league", + "provider", + "service" + ], + "time": "2017-03-06 15:24:06" }, { - "name": "nette/safe-stream", - "version": "v2.3.2", + "name": "mayflower/php-codebrowser", + "version": "1.1.2", "source": { "type": "git", - "url": "https://github.com/nette/safe-stream.git", - "reference": "4b9bb3266a537e59b10a2932f05dca47333420fc" + "url": "https://github.com/mayflower/PHP_CodeBrowser.git", + "reference": "b44cb1867211b3eb9efe8bb61a57fe782c84831f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/safe-stream/zipball/4b9bb3266a537e59b10a2932f05dca47333420fc", - "reference": "4b9bb3266a537e59b10a2932f05dca47333420fc", + "url": "https://api.github.com/repos/mayflower/PHP_CodeBrowser/zipball/b44cb1867211b3eb9efe8bb61a57fe782c84831f", + "reference": "b44cb1867211b3eb9efe8bb61a57fe782c84831f", "shasum": "" }, "require": { - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" + "monolog/monolog": "~1.7", + "phpunit/php-file-iterator": "~1.3", + "symfony/console": "~2.1|~3.0" }, "require-dev": { - "nette/tester": "~1.0", - "tracy/tracy": "^2.3" + "phploc/phploc": "*", + "phpmd/phpmd": "1.5.*", + "phpunit/phpunit": "3.7.*", + "sebastian/phpcpd": "*", + "squizlabs/php_codesniffer": "1.*" }, + "bin": [ + "bin/phpcb" + ], "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, "autoload": { - "files": [ - "src/loader.php" - ] + "psr-0": { + "PHPCodeBrowser\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "BSD-3-Clause" ], "authors": [ { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" + "name": "Robin Gloster", + "email": "robin.gloster@mayflower.de", + "role": "developer" } ], - "description": "Nette SafeStream: Atomic Operations", - "homepage": "https://nette.org", - "time": "2016-03-19 13:06:04" + "description": "A code browser that augments the code with information from various QA tools.", + "homepage": "https://github.com/Mayflower/PHP_CodeBrowser", + "time": "2016-01-14 12:43:42" }, { - "name": "nette/security", - "version": "v2.3.1", + "name": "mockery/mockery", + "version": "0.9.9", "source": { "type": "git", - "url": "https://github.com/nette/security.git", - "reference": "744264a42b506d63009d7e3853ed72b04c99e964" + "url": "https://github.com/padraic/mockery.git", + "reference": "6fdb61243844dc924071d3404bb23994ea0b6856" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/security/zipball/744264a42b506d63009d7e3853ed72b04c99e964", - "reference": "744264a42b506d63009d7e3853ed72b04c99e964", + "url": "https://api.github.com/repos/padraic/mockery/zipball/6fdb61243844dc924071d3404bb23994ea0b6856", + "reference": "6fdb61243844dc924071d3404bb23994ea0b6856", "shasum": "" }, "require": { - "nette/utils": "~2.2", - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" + "hamcrest/hamcrest-php": "~1.1", + "lib-pcre": ">=7.0", + "php": ">=5.3.2" }, "require-dev": { - "nette/di": "~2.3", - "nette/http": "~2.3", - "nette/tester": "~1.4" + "phpunit/phpunit": "~4.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.9.x-dev" + } + }, "autoload": { - "classmap": [ - "src/" - ] + "psr-0": { + "Mockery": "library/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "BSD-3-Clause" ], "authors": [ { - "name": "David Grudl", - "homepage": "http://davidgrudl.com" + "name": "Pádraic Brady", + "email": "padraic.brady@gmail.com", + "homepage": "http://blog.astrumfutura.com" }, { - "name": "Nette Community", - "homepage": "http://nette.org/contributors" + "name": "Dave Marshall", + "email": "dave.marshall@atstsolutions.co.uk", + "homepage": "http://davedevelopment.co.uk" } ], - "description": "Nette Security: Access Control Component", - "homepage": "http://nette.org", - "time": "2015-07-11 21:22:53" + "description": "Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succinct API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL). Designed as a drop in alternative to PHPUnit's phpunit-mock-objects library, Mockery is easy to integrate with PHPUnit and can operate alongside phpunit-mock-objects without the World ending.", + "homepage": "http://github.com/padraic/mockery", + "keywords": [ + "BDD", + "TDD", + "library", + "mock", + "mock objects", + "mockery", + "stub", + "test", + "test double", + "testing" + ], + "time": "2017-02-28 12:52:32" }, { - "name": "nette/utils", - "version": "v2.3.9", + "name": "myclabs/deep-copy", + "version": "1.6.0", "source": { "type": "git", - "url": "https://github.com/nette/utils.git", - "reference": "f6586f827292bd35c8593df943437f2247ba5337" + "url": "https://github.com/myclabs/DeepCopy.git", + "reference": "5a5a9fc8025a08d8919be87d6884d5a92520cefe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nette/utils/zipball/f6586f827292bd35c8593df943437f2247ba5337", - "reference": "f6586f827292bd35c8593df943437f2247ba5337", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/5a5a9fc8025a08d8919be87d6884d5a92520cefe", + "reference": "5a5a9fc8025a08d8919be87d6884d5a92520cefe", "shasum": "" }, "require": { - "php": ">=5.3.1" - }, - "conflict": { - "nette/nette": "<2.2" + "php": ">=5.4.0" }, "require-dev": { - "nette/tester": "~1.0" - }, - "suggest": { - "ext-gd": "to use Image", - "ext-iconv": "to use Strings::webalize() and toAscii()", - "ext-intl": "for script transliteration in Strings::webalize() and toAscii()", - "ext-mbstring": "to use Strings::lower() etc..." + "doctrine/collections": "1.*", + "phpunit/phpunit": "~4.1" }, "type": "library", "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" + "MIT" ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } + "description": "Create deep copies (clones) of your objects", + "homepage": "https://github.com/myclabs/DeepCopy", + "keywords": [ + "clone", + "copy", + "duplicate", + "object", + "object graph" ], - "description": "Nette Utility Classes", - "homepage": "https://nette.org", - "time": "2016-04-21 09:36:23" + "time": "2017-01-26 22:05:40" }, { "name": "paragonie/random_compat", - "version": "v1.4.1", + "version": "v2.0.10", "source": { "type": "git", "url": "https://github.com/paragonie/random_compat.git", - "reference": "c7e26a21ba357863de030f0b9e701c7d04593774" + "reference": "634bae8e911eefa89c1abfbf1b66da679ac8f54d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/c7e26a21ba357863de030f0b9e701c7d04593774", - "reference": "c7e26a21ba357863de030f0b9e701c7d04593774", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/634bae8e911eefa89c1abfbf1b66da679ac8f54d", + "reference": "634bae8e911eefa89c1abfbf1b66da679ac8f54d", "shasum": "" }, "require": { @@ -4364,20 +3282,20 @@ "pseudorandom", "random" ], - "time": "2016-03-18 20:34:03" + "time": "2017-03-13 16:27:32" }, { "name": "pdepend/pdepend", - "version": "2.2.4", + "version": "2.5.0", "source": { "type": "git", "url": "https://github.com/pdepend/pdepend.git", - "reference": "b086687f3a01dc6bb92d633aef071d2c5dd0db06" + "reference": "0c50874333149c0dad5a2877801aed148f2767ff" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pdepend/pdepend/zipball/b086687f3a01dc6bb92d633aef071d2c5dd0db06", - "reference": "b086687f3a01dc6bb92d633aef071d2c5dd0db06", + "url": "https://api.github.com/repos/pdepend/pdepend/zipball/0c50874333149c0dad5a2877801aed148f2767ff", + "reference": "0c50874333149c0dad5a2877801aed148f2767ff", "shasum": "" }, "require": { @@ -4404,7 +3322,7 @@ "BSD-3-Clause" ], "description": "Official version of pdepend to be handled with Composer", - "time": "2016-03-10 15:15:04" + "time": "2017-01-19 14:23:36" }, { "name": "phpdocumentor/reflection-common", @@ -4462,22 +3380,22 @@ }, { "name": "phpdocumentor/reflection-docblock", - "version": "3.0.2", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "45ada3e3fd09789fbfbd6d65b3f0901f0030dc61" + "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/45ada3e3fd09789fbfbd6d65b3f0901f0030dc61", - "reference": "45ada3e3fd09789fbfbd6d65b3f0901f0030dc61", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/8331b5efe816ae05461b7ca1e721c01b46bafb3e", + "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e", "shasum": "" }, "require": { "php": ">=5.5", "phpdocumentor/reflection-common": "^1.0@dev", - "phpdocumentor/type-resolver": "^0.1.5", + "phpdocumentor/type-resolver": "^0.2.0", "webmozart/assert": "^1.0" }, "require-dev": { @@ -4503,20 +3421,20 @@ } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2016-06-06 06:44:13" + "time": "2016-09-30 07:12:33" }, { "name": "phpdocumentor/type-resolver", - "version": "0.1.8", + "version": "0.2.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "9891754231e55d42f0d16988ffb799af39f31a12" + "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/9891754231e55d42f0d16988ffb799af39f31a12", - "reference": "9891754231e55d42f0d16988ffb799af39f31a12", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", + "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", "shasum": "" }, "require": { @@ -4525,7 +3443,7 @@ }, "require-dev": { "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^5.2" + "phpunit/phpunit": "^5.2||^4.8.24" }, "type": "library", "extra": { @@ -4550,7 +3468,7 @@ "email": "me@mikevanriel.com" } ], - "time": "2016-03-28 10:02:29" + "time": "2016-11-25 06:54:22" }, { "name": "phploc/phploc", @@ -4607,21 +3525,22 @@ }, { "name": "phpmd/phpmd", - "version": "2.4.3", + "version": "2.6.0", "source": { "type": "git", "url": "https://github.com/phpmd/phpmd.git", - "reference": "2b9c2417a18696dfb578b38c116cd0ddc19b256e" + "reference": "4e9924b2c157a3eb64395460fcf56b31badc8374" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpmd/phpmd/zipball/2b9c2417a18696dfb578b38c116cd0ddc19b256e", - "reference": "2b9c2417a18696dfb578b38c116cd0ddc19b256e", + "url": "https://api.github.com/repos/phpmd/phpmd/zipball/4e9924b2c157a3eb64395460fcf56b31badc8374", + "reference": "4e9924b2c157a3eb64395460fcf56b31badc8374", "shasum": "" }, "require": { - "pdepend/pdepend": "^2.0.4", - "php": ">=5.3.0" + "ext-xml": "*", + "pdepend/pdepend": "^2.5", + "php": ">=5.3.9" }, "require-dev": { "phpunit/phpunit": "^4.0", @@ -4668,7 +3587,7 @@ "phpmd", "pmd" ], - "time": "2016-04-04 11:52:04" + "time": "2017-01-20 14:41:10" }, { "name": "phpmetrics/phpmetrics", @@ -4736,27 +3655,28 @@ }, { "name": "phpspec/prophecy", - "version": "v1.6.1", + "version": "v1.7.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "58a8137754bc24b25740d4281399a4a3596058e0" + "reference": "93d39f1f7f9326d746203c7c056f300f7f126073" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/58a8137754bc24b25740d4281399a4a3596058e0", - "reference": "58a8137754bc24b25740d4281399a4a3596058e0", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/93d39f1f7f9326d746203c7c056f300f7f126073", + "reference": "93d39f1f7f9326d746203c7c056f300f7f126073", "shasum": "" }, "require": { "doctrine/instantiator": "^1.0.2", "php": "^5.3|^7.0", "phpdocumentor/reflection-docblock": "^2.0|^3.0.2", - "sebastian/comparator": "^1.1", - "sebastian/recursion-context": "^1.0" + "sebastian/comparator": "^1.1|^2.0", + "sebastian/recursion-context": "^1.0|^2.0|^3.0" }, "require-dev": { - "phpspec/phpspec": "^2.0" + "phpspec/phpspec": "^2.5|^3.2", + "phpunit/phpunit": "^4.8 || ^5.6.5" }, "type": "library", "extra": { @@ -4794,39 +3714,39 @@ "spy", "stub" ], - "time": "2016-06-07 08:13:47" + "time": "2017-03-02 20:05:34" }, { "name": "phpunit/php-code-coverage", - "version": "4.0.0", + "version": "4.0.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "900370c81280cc0d942ffbc5912d80464eaee7e9" + "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/900370c81280cc0d942ffbc5912d80464eaee7e9", - "reference": "900370c81280cc0d942ffbc5912d80464eaee7e9", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/ef7b2f56815df854e66ceaee8ebe9393ae36a40d", + "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d", "shasum": "" }, "require": { + "ext-dom": "*", + "ext-xmlwriter": "*", "php": "^5.6 || ^7.0", - "phpunit/php-file-iterator": "~1.3", - "phpunit/php-text-template": "~1.2", - "phpunit/php-token-stream": "^1.4.2", - "sebastian/code-unit-reverse-lookup": "~1.0", - "sebastian/environment": "^1.3.2", - "sebastian/version": "~1.0|~2.0" + "phpunit/php-file-iterator": "^1.3", + "phpunit/php-text-template": "^1.2", + "phpunit/php-token-stream": "^1.4.2 || ^2.0", + "sebastian/code-unit-reverse-lookup": "^1.0", + "sebastian/environment": "^1.3.2 || ^2.0", + "sebastian/version": "^1.0 || ^2.0" }, "require-dev": { - "ext-xdebug": ">=2.1.4", - "phpunit/phpunit": "^5.4" + "ext-xdebug": "^2.1.4", + "phpunit/phpunit": "^5.7" }, "suggest": { - "ext-dom": "*", - "ext-xdebug": ">=2.4.0", - "ext-xmlwriter": "*" + "ext-xdebug": "^2.5.1" }, "type": "library", "extra": { @@ -4857,20 +3777,20 @@ "testing", "xunit" ], - "time": "2016-06-03 05:03:56" + "time": "2017-04-02 07:44:40" }, { "name": "phpunit/php-file-iterator", - "version": "1.4.1", + "version": "1.4.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0" + "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/6150bf2c35d3fc379e50c7602b75caceaa39dbf0", - "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/3cc8f69b3028d0f96a9078e6295d86e9bf019be5", + "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5", "shasum": "" }, "require": { @@ -4904,7 +3824,7 @@ "filesystem", "iterator" ], - "time": "2015-06-21 13:08:43" + "time": "2016-10-03 07:40:28" }, { "name": "phpunit/php-text-template", @@ -4949,25 +3869,30 @@ }, { "name": "phpunit/php-timer", - "version": "1.0.8", + "version": "1.0.9", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "38e9124049cf1a164f1e4537caf19c99bf1eb260" + "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/38e9124049cf1a164f1e4537caf19c99bf1eb260", - "reference": "38e9124049cf1a164f1e4537caf19c99bf1eb260", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", + "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": "^5.3.3 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "~4|~5" + "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -4989,20 +3914,20 @@ "keywords": [ "timer" ], - "time": "2016-05-12 18:03:57" + "time": "2017-02-26 11:10:40" }, { "name": "phpunit/php-token-stream", - "version": "1.4.8", + "version": "1.4.11", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da" + "reference": "e03f8f67534427a787e21a385a67ec3ca6978ea7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", - "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/e03f8f67534427a787e21a385a67ec3ca6978ea7", + "reference": "e03f8f67534427a787e21a385a67ec3ca6978ea7", "shasum": "" }, "require": { @@ -5038,47 +3963,54 @@ "keywords": [ "tokenizer" ], - "time": "2015-09-15 10:49:45" + "time": "2017-02-27 10:12:30" }, { "name": "phpunit/phpunit", - "version": "5.4.3", + "version": "5.7.19", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "fd1dd4117ca2d7c4175dfd4f35b32762a3a9f9ca" + "reference": "69c4f49ff376af2692bad9cebd883d17ebaa98a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/fd1dd4117ca2d7c4175dfd4f35b32762a3a9f9ca", - "reference": "fd1dd4117ca2d7c4175dfd4f35b32762a3a9f9ca", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/69c4f49ff376af2692bad9cebd883d17ebaa98a1", + "reference": "69c4f49ff376af2692bad9cebd883d17ebaa98a1", "shasum": "" }, "require": { "ext-dom": "*", "ext-json": "*", - "ext-pcre": "*", - "ext-reflection": "*", - "ext-spl": "*", + "ext-libxml": "*", + "ext-mbstring": "*", + "ext-xml": "*", "myclabs/deep-copy": "~1.3", "php": "^5.6 || ^7.0", - "phpspec/prophecy": "^1.3.1", - "phpunit/php-code-coverage": "^4.0", + "phpspec/prophecy": "^1.6.2", + "phpunit/php-code-coverage": "^4.0.4", "phpunit/php-file-iterator": "~1.4", "phpunit/php-text-template": "~1.2", "phpunit/php-timer": "^1.0.6", "phpunit/phpunit-mock-objects": "^3.2", - "sebastian/comparator": "~1.1", + "sebastian/comparator": "^1.2.4", "sebastian/diff": "~1.2", - "sebastian/environment": "~1.3", - "sebastian/exporter": "~1.2", - "sebastian/global-state": "~1.0", - "sebastian/object-enumerator": "~1.0", + "sebastian/environment": "^1.3.4 || ^2.0", + "sebastian/exporter": "~2.0", + "sebastian/global-state": "^1.1", + "sebastian/object-enumerator": "~2.0", "sebastian/resource-operations": "~1.0", - "sebastian/version": "~1.0|~2.0", + "sebastian/version": "~1.0.3|~2.0", "symfony/yaml": "~2.1|~3.0" }, + "conflict": { + "phpdocumentor/reflection-docblock": "3.0.2" + }, + "require-dev": { + "ext-pdo": "*" + }, "suggest": { + "ext-xdebug": "*", "phpunit/php-invoker": "~1.1" }, "bin": [ @@ -5087,7 +4019,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "5.4.x-dev" + "dev-master": "5.7.x-dev" } }, "autoload": { @@ -5113,27 +4045,27 @@ "testing", "xunit" ], - "time": "2016-06-09 06:10:10" + "time": "2017-04-03 02:22:27" }, { "name": "phpunit/phpunit-mock-objects", - "version": "3.2.3", + "version": "3.4.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "b13d0d9426ced06958bd32104653526a6c998a52" + "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/b13d0d9426ced06958bd32104653526a6c998a52", - "reference": "b13d0d9426ced06958bd32104653526a6c998a52", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/3ab72b65b39b491e0c011e2e09bb2206c2aa8e24", + "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24", "shasum": "" }, "require": { "doctrine/instantiator": "^1.0.2", "php": "^5.6 || ^7.0", "phpunit/php-text-template": "^1.2", - "sebastian/exporter": "^1.2" + "sebastian/exporter": "^1.2 || ^2.0" }, "conflict": { "phpunit/phpunit": "<5.4.0" @@ -5172,27 +4104,27 @@ "mock", "xunit" ], - "time": "2016-06-12 07:37:26" + "time": "2016-12-08 20:27:08" }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.0", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe" + "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/c36f5e7cfce482fde5bf8d10d41a53591e0198fe", - "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", + "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", "shasum": "" }, "require": { - "php": ">=5.6" + "php": "^5.6 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "~5" + "phpunit/phpunit": "^5.7 || ^6.0" }, "type": "library", "extra": { @@ -5217,26 +4149,26 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2016-02-13 06:45:14" + "time": "2017-03-04 06:30:41" }, { "name": "sebastian/comparator", - "version": "1.2.0", + "version": "1.2.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "937efb279bd37a375bcadf584dec0726f84dbf22" + "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/937efb279bd37a375bcadf584dec0726f84dbf22", - "reference": "937efb279bd37a375bcadf584dec0726f84dbf22", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", + "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", "shasum": "" }, "require": { "php": ">=5.3.3", "sebastian/diff": "~1.2", - "sebastian/exporter": "~1.2" + "sebastian/exporter": "~1.2 || ~2.0" }, "require-dev": { "phpunit/phpunit": "~4.4" @@ -5281,7 +4213,7 @@ "compare", "equality" ], - "time": "2015-07-26 15:48:44" + "time": "2017-01-29 09:50:25" }, { "name": "sebastian/diff", @@ -5337,28 +4269,28 @@ }, { "name": "sebastian/environment", - "version": "1.3.7", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "4e8f0da10ac5802913afc151413bc8c53b6c2716" + "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/4e8f0da10ac5802913afc151413bc8c53b6c2716", - "reference": "4e8f0da10ac5802913afc151413bc8c53b6c2716", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/5795ffe5dc5b02460c3e34222fee8cbe245d8fac", + "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": "^5.6 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^5.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -5383,33 +4315,34 @@ "environment", "hhvm" ], - "time": "2016-05-17 03:18:57" + "time": "2016-11-26 07:53:53" }, { "name": "sebastian/exporter", - "version": "1.2.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "7ae5513327cb536431847bcc0c10edba2701064e" + "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/7ae5513327cb536431847bcc0c10edba2701064e", - "reference": "7ae5513327cb536431847bcc0c10edba2701064e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", + "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", "shasum": "" }, "require": { "php": ">=5.3.3", - "sebastian/recursion-context": "~1.0" + "sebastian/recursion-context": "~2.0" }, "require-dev": { + "ext-mbstring": "*", "phpunit/phpunit": "~4.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -5449,7 +4382,7 @@ "export", "exporter" ], - "time": "2015-06-21 07:55:53" + "time": "2016-11-19 08:54:04" }, { "name": "sebastian/finder-facade", @@ -5492,16 +4425,16 @@ }, { "name": "sebastian/git", - "version": "2.1.3", + "version": "2.1.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/git.git", - "reference": "5100bc50cd9e70f424c643618e142214225024f3" + "reference": "815bbbc963cf35e5413df195aa29df58243ecd24" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/git/zipball/5100bc50cd9e70f424c643618e142214225024f3", - "reference": "5100bc50cd9e70f424c643618e142214225024f3", + "url": "https://api.github.com/repos/sebastianbergmann/git/zipball/815bbbc963cf35e5413df195aa29df58243ecd24", + "reference": "815bbbc963cf35e5413df195aa29df58243ecd24", "shasum": "" }, "require": { @@ -5533,7 +4466,7 @@ "keywords": [ "git" ], - "time": "2016-06-15 09:30:19" + "time": "2017-01-23 20:57:12" }, { "name": "sebastian/global-state", @@ -5588,21 +4521,21 @@ }, { "name": "sebastian/object-enumerator", - "version": "1.0.0", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "d4ca2fb70344987502567bc50081c03e6192fb26" + "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/d4ca2fb70344987502567bc50081c03e6192fb26", - "reference": "d4ca2fb70344987502567bc50081c03e6192fb26", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/1311872ac850040a79c3c058bea3e22d0f09cbb7", + "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7", "shasum": "" }, "require": { "php": ">=5.6", - "sebastian/recursion-context": "~1.0" + "sebastian/recursion-context": "~2.0" }, "require-dev": { "phpunit/phpunit": "~5" @@ -5610,7 +4543,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -5630,7 +4563,7 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2016-01-28 13:25:10" + "time": "2017-02-18 15:18:39" }, { "name": "sebastian/phpcpd", @@ -5685,16 +4618,16 @@ }, { "name": "sebastian/recursion-context", - "version": "1.0.2", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "913401df809e99e4f47b27cdd781f4a258d58791" + "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/913401df809e99e4f47b27cdd781f4a258d58791", - "reference": "913401df809e99e4f47b27cdd781f4a258d58791", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/2c3ba150cbec723aa057506e73a8d33bdb286c9a", + "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a", "shasum": "" }, "require": { @@ -5706,7 +4639,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -5734,7 +4667,7 @@ ], "description": "Provides functionality to recursively process PHP variables", "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2015-11-11 19:50:13" + "time": "2016-11-19 07:33:16" }, { "name": "sebastian/resource-operations", @@ -5813,68 +4746,22 @@ "homepage": "https://github.com/sebastianbergmann/version", "time": "2015-06-21 13:59:46" }, - { - "name": "seld/jsonlint", - "version": "1.4.0", - "source": { - "type": "git", - "url": "https://github.com/Seldaek/jsonlint.git", - "reference": "66834d3e3566bb5798db7294619388786ae99394" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Seldaek/jsonlint/zipball/66834d3e3566bb5798db7294619388786ae99394", - "reference": "66834d3e3566bb5798db7294619388786ae99394", - "shasum": "" - }, - "require": { - "php": "^5.3 || ^7.0" - }, - "bin": [ - "bin/jsonlint" - ], - "type": "library", - "autoload": { - "psr-4": { - "Seld\\JsonLint\\": "src/Seld/JsonLint/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "JSON Linter", - "keywords": [ - "json", - "linter", - "parser", - "validator" - ], - "time": "2015-11-21 02:21:41" - }, { "name": "slim/csrf", - "version": "0.6.0", + "version": "0.7.0", "source": { "type": "git", "url": "https://github.com/slimphp/Slim-Csrf.git", - "reference": "f56bccc1c3a9c76e5fcf7c6d56698a32f9e7e9d8" + "reference": "788f658de275e5d856d498aa8698cde70029decd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/slimphp/Slim-Csrf/zipball/f56bccc1c3a9c76e5fcf7c6d56698a32f9e7e9d8", - "reference": "f56bccc1c3a9c76e5fcf7c6d56698a32f9e7e9d8", + "url": "https://api.github.com/repos/slimphp/Slim-Csrf/zipball/788f658de275e5d856d498aa8698cde70029decd", + "reference": "788f658de275e5d856d498aa8698cde70029decd", "shasum": "" }, "require": { - "paragonie/random_compat": "^1.1", + "paragonie/random_compat": "^1.1|^2.0", "php": ">=5.5.0", "psr/http-message": "^1.0" }, @@ -5907,20 +4794,20 @@ "middleware", "slim" ], - "time": "2015-12-22 10:13:02" + "time": "2016-06-08 18:26:56" }, { "name": "squizlabs/php_codesniffer", - "version": "2.6.1", + "version": "2.8.1", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "fb72ed32f8418db5e7770be1653e62e0d6f5dd3d" + "reference": "d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/fb72ed32f8418db5e7770be1653e62e0d6f5dd3d", - "reference": "fb72ed32f8418db5e7770be1653e62e0d6f5dd3d", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d", + "reference": "d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d", "shasum": "" }, "require": { @@ -5985,20 +4872,65 @@ "phpcs", "standards" ], - "time": "2016-05-30 22:24:32" + "time": "2017-03-01 22:17:45" + }, + { + "name": "stecman/symfony-console-completion", + "version": "0.7.0", + "source": { + "type": "git", + "url": "https://github.com/stecman/symfony-console-completion.git", + "reference": "5461d43e53092b3d3b9dbd9d999f2054730f4bbb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/stecman/symfony-console-completion/zipball/5461d43e53092b3d3b9dbd9d999f2054730f4bbb", + "reference": "5461d43e53092b3d3b9dbd9d999f2054730f4bbb", + "shasum": "" + }, + "require": { + "php": ">=5.3.2", + "symfony/console": "~2.3 || ~3.0" + }, + "require-dev": { + "phpunit/phpunit": "~4.4" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.6.x-dev" + } + }, + "autoload": { + "psr-4": { + "Stecman\\Component\\Symfony\\Console\\BashCompletion\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Stephen Holdaway", + "email": "stephen@stecman.co.nz" + } + ], + "description": "Automatic BASH completion for Symfony Console Component based applications.", + "time": "2016-02-24 05:08:54" }, { "name": "symfony/browser-kit", - "version": "v3.1.0", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/browser-kit.git", - "reference": "b645a9b23d6c0eeba5ac823fa87bf010db9aff22" + "reference": "2fe0caa60c1a1dfeefd0425741182687a9b382b8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/browser-kit/zipball/b645a9b23d6c0eeba5ac823fa87bf010db9aff22", - "reference": "b645a9b23d6c0eeba5ac823fa87bf010db9aff22", + "url": "https://api.github.com/repos/symfony/browser-kit/zipball/2fe0caa60c1a1dfeefd0425741182687a9b382b8", + "reference": "2fe0caa60c1a1dfeefd0425741182687a9b382b8", "shasum": "" }, "require": { @@ -6015,7 +4947,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6042,25 +4974,28 @@ ], "description": "Symfony BrowserKit Component", "homepage": "https://symfony.com", - "time": "2016-03-04 07:56:56" + "time": "2017-02-21 09:12:04" }, { "name": "symfony/config", - "version": "v2.8.7", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/config.git", - "reference": "a2edd59c2163c65747fc3f35d132b5a39266bd05" + "reference": "8444bde28e3c2a33e571e6f180c2d78bfdc4480d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/a2edd59c2163c65747fc3f35d132b5a39266bd05", - "reference": "a2edd59c2163c65747fc3f35d132b5a39266bd05", + "url": "https://api.github.com/repos/symfony/config/zipball/8444bde28e3c2a33e571e6f180c2d78bfdc4480d", + "reference": "8444bde28e3c2a33e571e6f180c2d78bfdc4480d", "shasum": "" }, "require": { - "php": ">=5.3.9", - "symfony/filesystem": "~2.3|~3.0.0" + "php": ">=5.5.9", + "symfony/filesystem": "~2.8|~3.0" + }, + "require-dev": { + "symfony/yaml": "~3.0" }, "suggest": { "symfony/yaml": "To use the yaml reference dumper" @@ -6068,7 +5003,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6095,24 +5030,25 @@ ], "description": "Symfony Config Component", "homepage": "https://symfony.com", - "time": "2016-06-06 11:11:27" + "time": "2017-04-04 15:30:56" }, { "name": "symfony/console", - "version": "v2.8.7", + "version": "v2.8.19", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "5ac8bc9aa77bb2edf06af3a1bb6bc1020d23acd3" + "reference": "86407ff20855a5eaa2a7219bd815e9c40a88633e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/5ac8bc9aa77bb2edf06af3a1bb6bc1020d23acd3", - "reference": "5ac8bc9aa77bb2edf06af3a1bb6bc1020d23acd3", + "url": "https://api.github.com/repos/symfony/console/zipball/86407ff20855a5eaa2a7219bd815e9c40a88633e", + "reference": "86407ff20855a5eaa2a7219bd815e9c40a88633e", "shasum": "" }, "require": { "php": ">=5.3.9", + "symfony/debug": "^2.7.2|~3.0.0", "symfony/polyfill-mbstring": "~1.0" }, "require-dev": { @@ -6155,20 +5091,20 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2016-06-06 15:06:25" + "time": "2017-04-03 20:37:06" }, { "name": "symfony/css-selector", - "version": "v3.1.0", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "e17f386efef7258ac671c24e727673abd086b0cf" + "reference": "a48f13dc83c168f1253a5d2a5a4fb46c36244c4c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/e17f386efef7258ac671c24e727673abd086b0cf", - "reference": "e17f386efef7258ac671c24e727673abd086b0cf", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/a48f13dc83c168f1253a5d2a5a4fb46c36244c4c", + "reference": "a48f13dc83c168f1253a5d2a5a4fb46c36244c4c", "shasum": "" }, "require": { @@ -6177,7 +5113,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6208,29 +5144,89 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2016-03-04 07:56:56" + "time": "2017-02-21 09:12:04" + }, + { + "name": "symfony/debug", + "version": "v3.0.9", + "source": { + "type": "git", + "url": "https://github.com/symfony/debug.git", + "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/debug/zipball/697c527acd9ea1b2d3efac34d9806bf255278b0a", + "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a", + "shasum": "" + }, + "require": { + "php": ">=5.5.9", + "psr/log": "~1.0" + }, + "conflict": { + "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" + }, + "require-dev": { + "symfony/class-loader": "~2.8|~3.0", + "symfony/http-kernel": "~2.8|~3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Debug\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Debug Component", + "homepage": "https://symfony.com", + "time": "2016-07-30 07:22:48" }, { "name": "symfony/dependency-injection", - "version": "v3.1.1", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "4b9645f5870e0b4ab35cc5b528422049946e8bec" + "reference": "923bb014708b666e4092c9ba39993895c9c8fcd7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/4b9645f5870e0b4ab35cc5b528422049946e8bec", - "reference": "4b9645f5870e0b4ab35cc5b528422049946e8bec", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/923bb014708b666e4092c9ba39993895c9c8fcd7", + "reference": "923bb014708b666e4092c9ba39993895c9c8fcd7", "shasum": "" }, "require": { "php": ">=5.5.9" }, + "conflict": { + "symfony/yaml": "<3.2" + }, "require-dev": { "symfony/config": "~2.8|~3.0", "symfony/expression-language": "~2.8|~3.0", - "symfony/yaml": "~2.8|~3.0" + "symfony/yaml": "~3.2" }, "suggest": { "symfony/config": "", @@ -6241,7 +5237,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6268,20 +5264,20 @@ ], "description": "Symfony DependencyInjection Component", "homepage": "https://symfony.com", - "time": "2016-06-14 11:18:07" + "time": "2017-04-04 07:26:27" }, { "name": "symfony/dom-crawler", - "version": "v3.1.0", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/dom-crawler.git", - "reference": "12aa63fd41b060d2bee9a34623d29eda70bc8fe3" + "reference": "403944e294cf4ceb3b8447f54cbad88ea7b99cee" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/12aa63fd41b060d2bee9a34623d29eda70bc8fe3", - "reference": "12aa63fd41b060d2bee9a34623d29eda70bc8fe3", + "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/403944e294cf4ceb3b8447f54cbad88ea7b99cee", + "reference": "403944e294cf4ceb3b8447f54cbad88ea7b99cee", "shasum": "" }, "require": { @@ -6297,7 +5293,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6324,31 +5320,31 @@ ], "description": "Symfony DomCrawler Component", "homepage": "https://symfony.com", - "time": "2016-05-13 15:49:09" + "time": "2017-02-21 09:12:04" }, { "name": "symfony/event-dispatcher", - "version": "v2.8.7", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "2a6b8713f8bdb582058cfda463527f195b066110" + "reference": "154bb1ef7b0e42ccc792bd53edbce18ed73440ca" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/2a6b8713f8bdb582058cfda463527f195b066110", - "reference": "2a6b8713f8bdb582058cfda463527f195b066110", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/154bb1ef7b0e42ccc792bd53edbce18ed73440ca", + "reference": "154bb1ef7b0e42ccc792bd53edbce18ed73440ca", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.5.9" }, "require-dev": { "psr/log": "~1.0", - "symfony/config": "~2.0,>=2.0.5|~3.0.0", - "symfony/dependency-injection": "~2.6|~3.0.0", - "symfony/expression-language": "~2.6|~3.0.0", - "symfony/stopwatch": "~2.3|~3.0.0" + "symfony/config": "~2.8|~3.0", + "symfony/dependency-injection": "~2.8|~3.0", + "symfony/expression-language": "~2.8|~3.0", + "symfony/stopwatch": "~2.8|~3.0" }, "suggest": { "symfony/dependency-injection": "", @@ -6357,7 +5353,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6384,29 +5380,29 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2016-06-06 11:11:27" + "time": "2017-04-04 07:26:27" }, { "name": "symfony/filesystem", - "version": "v2.8.7", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "dee379131dceed90a429e951546b33edfe7dccbb" + "reference": "64421e6479c4a8e60d790fb666bd520992861b66" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/dee379131dceed90a429e951546b33edfe7dccbb", - "reference": "dee379131dceed90a429e951546b33edfe7dccbb", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/64421e6479c4a8e60d790fb666bd520992861b66", + "reference": "64421e6479c4a8e60d790fb666bd520992861b66", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.5.9" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6433,29 +5429,29 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", - "time": "2016-04-12 18:01:21" + "time": "2017-03-26 15:47:15" }, { "name": "symfony/finder", - "version": "v2.8.7", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "3ec095fab1800222732ca522a95dce8fa124007b" + "reference": "b20900ce5ea164cd9314af52725b0bb5a758217a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/3ec095fab1800222732ca522a95dce8fa124007b", - "reference": "3ec095fab1800222732ca522a95dce8fa124007b", + "url": "https://api.github.com/repos/symfony/finder/zipball/b20900ce5ea164cd9314af52725b0bb5a758217a", + "reference": "b20900ce5ea164cd9314af52725b0bb5a758217a", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.5.9" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6482,75 +5478,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2016-06-06 11:11:27" - }, - { - "name": "symfony/options-resolver", - "version": "v2.6.13", - "target-dir": "Symfony/Component/OptionsResolver", - "source": { - "type": "git", - "url": "https://github.com/symfony/options-resolver.git", - "reference": "31e56594cee489e9a235b852228b0598b52101c1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/31e56594cee489e9a235b852228b0598b52101c1", - "reference": "31e56594cee489e9a235b852228b0598b52101c1", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "symfony/phpunit-bridge": "~2.7" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.6-dev" - } - }, - "autoload": { - "psr-0": { - "Symfony\\Component\\OptionsResolver\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony OptionsResolver Component", - "homepage": "https://symfony.com", - "keywords": [ - "config", - "configuration", - "options" - ], - "time": "2015-05-13 11:33:56" + "time": "2017-03-20 09:32:19" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.2.0", + "version": "v1.3.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "dff51f72b0706335131b00a7f49606168c582594" + "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/dff51f72b0706335131b00a7f49606168c582594", - "reference": "dff51f72b0706335131b00a7f49606168c582594", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/e79d363049d1c2128f133a2667e4f4190904f7f4", + "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4", "shasum": "" }, "require": { @@ -6562,7 +5503,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2-dev" + "dev-master": "1.3-dev" } }, "autoload": { @@ -6596,29 +5537,29 @@ "portable", "shim" ], - "time": "2016-05-18 14:26:46" + "time": "2016-11-14 01:06:16" }, { "name": "symfony/process", - "version": "v2.8.7", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "115347d00c342198cdc52a7bd8bc15b5ab43500c" + "reference": "57fdaa55827ae14d617550ebe71a820f0a5e2282" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/115347d00c342198cdc52a7bd8bc15b5ab43500c", - "reference": "115347d00c342198cdc52a7bd8bc15b5ab43500c", + "url": "https://api.github.com/repos/symfony/process/zipball/57fdaa55827ae14d617550ebe71a820f0a5e2282", + "reference": "57fdaa55827ae14d617550ebe71a820f0a5e2282", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": ">=5.5.9" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6645,29 +5586,35 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2016-06-06 11:11:27" + "time": "2017-03-27 18:07:02" }, { "name": "symfony/yaml", - "version": "v3.1.0", + "version": "v3.2.7", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "eca51b7b65eb9be6af88ad7cc91685f1556f5c9a" + "reference": "62b4cdb99d52cb1ff253c465eb1532a80cebb621" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/eca51b7b65eb9be6af88ad7cc91685f1556f5c9a", - "reference": "eca51b7b65eb9be6af88ad7cc91685f1556f5c9a", + "url": "https://api.github.com/repos/symfony/yaml/zipball/62b4cdb99d52cb1ff253c465eb1532a80cebb621", + "reference": "62b4cdb99d52cb1ff253c465eb1532a80cebb621", "shasum": "" }, "require": { "php": ">=5.5.9" }, + "require-dev": { + "symfony/console": "~2.8|~3.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -6694,7 +5641,7 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", - "time": "2016-05-26 21:46:24" + "time": "2017-03-20 09:45:15" }, { "name": "theseer/fdomdocument", @@ -6736,86 +5683,32 @@ "homepage": "https://github.com/theseer/fDOMDocument", "time": "2015-05-27 22:58:02" }, - { - "name": "tracy/tracy", - "version": "v2.3.11", - "source": { - "type": "git", - "url": "https://github.com/nette/tracy.git", - "reference": "152b7602115dd3a66f3190280951390097a15f65" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nette/tracy/zipball/152b7602115dd3a66f3190280951390097a15f65", - "reference": "152b7602115dd3a66f3190280951390097a15f65", - "shasum": "" - }, - "require": { - "php": ">=5.3.1" - }, - "require-dev": { - "nette/di": "~2.3", - "nette/tester": "~1.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "src" - ], - "files": [ - "src/shortcuts.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause", - "GPL-2.0", - "GPL-3.0" - ], - "authors": [ - { - "name": "David Grudl", - "homepage": "https://davidgrudl.com" - }, - { - "name": "Nette Community", - "homepage": "https://nette.org/contributors" - } - ], - "description": "Tracy: useful PHP debugger", - "homepage": "https://tracy.nette.org", - "keywords": [ - "debug", - "debugger", - "nette" - ], - "time": "2016-05-30 09:03:15" - }, { "name": "twig/twig", - "version": "v1.24.1", + "version": "v1.33.0", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "3566d311a92aae4deec6e48682dc5a4528c4a512" + "reference": "05cf49921b13f6f01d3cfdf9018cfa7a8086fd5a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/3566d311a92aae4deec6e48682dc5a4528c4a512", - "reference": "3566d311a92aae4deec6e48682dc5a4528c4a512", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/05cf49921b13f6f01d3cfdf9018cfa7a8086fd5a", + "reference": "05cf49921b13f6f01d3cfdf9018cfa7a8086fd5a", "shasum": "" }, "require": { "php": ">=5.2.7" }, "require-dev": { + "psr/container": "^1.0", "symfony/debug": "~2.7", - "symfony/phpunit-bridge": "~2.7" + "symfony/phpunit-bridge": "~3.3@dev" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.24-dev" + "dev-master": "1.33-dev" } }, "autoload": { @@ -6850,32 +5743,33 @@ "keywords": [ "templating" ], - "time": "2016-05-30 09:11:59" + "time": "2017-03-22 15:40:09" }, { "name": "webmozart/assert", - "version": "1.0.2", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/webmozart/assert.git", - "reference": "30eed06dd6bc88410a4ff7f77b6d22f3ce13dbde" + "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/30eed06dd6bc88410a4ff7f77b6d22f3ce13dbde", - "reference": "30eed06dd6bc88410a4ff7f77b6d22f3ce13dbde", + "url": "https://api.github.com/repos/webmozart/assert/zipball/2db61e59ff05fe5126d152bd0655c9ea113e550f", + "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": "^5.3.3 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "^4.6" + "phpunit/phpunit": "^4.6", + "sebastian/version": "^1.0.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.3-dev" } }, "autoload": { @@ -6899,18 +5793,14 @@ "check", "validate" ], - "time": "2015-08-24 13:29:44" + "time": "2016-11-23 20:04:58" } ], "aliases": [], "minimum-stability": "stable", - "stability-flags": { - "doctrine/dbal": 20 - }, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, - "platform": { - "php": ">=5.5.9" - }, + "platform": [], "platform-dev": [] } diff --git a/data/entities/.gitkeep b/data/entities/.gitkeep deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/tests/cli/docker-compose.yml b/docker-compose-cli.yml similarity index 100% rename from tests/cli/docker-compose.yml rename to docker-compose-cli.yml diff --git a/docs/.gitignore b/docs/.gitignore index 0b9b7e365d..1442772af9 100644 --- a/docs/.gitignore +++ b/docs/.gitignore @@ -1,3 +1,2 @@ -/.gitignore /discussion *.pdf diff --git a/docs/list-of-events.md b/docs/list-of-events.md index 0003f38f5d..f894b90ee6 100644 --- a/docs/list-of-events.md +++ b/docs/list-of-events.md @@ -58,7 +58,7 @@ It is a `Joomla\Event\Event` object with the following parameters: Parameter | Type | Description --------- | ---- | ----------- `type` | string | The name of the ContentType -`stream` | Psr\Http\Message\StreamInterface | The output stream in its current state +`renderer` | Joomla\Renderer\RendererInterface | The output renderer in its current state ### onRender\Failure diff --git a/docs/orthogonality.md b/docs/orthogonality.md new file mode 100644 index 0000000000..d68b067e24 --- /dev/null +++ b/docs/orthogonality.md @@ -0,0 +1,57 @@ +# Orthogonality + +The Joomla! X architecture is based on the principle of orthogonal components. +This principle describes vertical components, like content, weblinks, or users, +that are combined with horizontal components, like workflow, tagging, or versioning. +Horizontal components (HCs) add functionality to vertical components (VCs) *without explicit code* in the components. + +This document defines the communication between those two kinds of components. + +## Scope + +For each possible combination of installed HCs and VCs, the administrator can define, +whether or not this combination is supported. This could be represented by a list of supported HCs for each VC: + +```json +{ + "content": [ + "workflow", + "tagging", + "versioning" + ], + "weblinks": [ + "workflow" + ], + "users": [ + "workflow", + "tagging" + ] +} +``` + +## Storage + +Horizontal components must be able to add fields, relations, and conditions on read access, +and handle persistence of added information on write access. + +Components use Entities to communicate with the storage layer, which are created by an EntityBuilder. +It is the responsibility of the EntityBuilder to provide additional fields, which are populated on read, +and to provide the necessary information for the Persistor to handle additional data correctly. + + - The `create()` method of the EntityBuilder needs to be modified to add the relation definitions + of all associated HCs. + + - Since related data is stored as a child Entity in the main Entity, + the Persistor can handle storage based on the information from the child Entity. + + - A HC must provide a condition (might be empty) for use in retrievals. + The workflow HC, fx., should add `['state', Operator::EQ, Workflow::PUBLISHED]`, + so that by default only published items are shown. + +## Rendering + + - On list views, the HCs should provide filters for the fields, they add. + + - Content types based on entities (e.g., Article, Teaser) create a compound element from the entity's properties. + A `ContentTypeQuery` is issued, and the `ContentTypeQueryHandler` is responsible to let the HCs add their data. + *The current implementation contains just a dummy for that, just adding `extended => YES` to the elements.* diff --git a/libraries/incubator/Content/ContentTypeInterface.php b/libraries/incubator/Content/ContentTypeInterface.php index a0946257c1..bd4544d0f4 100644 --- a/libraries/incubator/Content/ContentTypeInterface.php +++ b/libraries/incubator/Content/ContentTypeInterface.php @@ -25,7 +25,7 @@ interface ContentTypeInterface * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor); diff --git a/libraries/incubator/Content/ContentTypeVisitorInterface.php b/libraries/incubator/Content/ContentTypeVisitorInterface.php index 2353fd2962..7c681f8a34 100644 --- a/libraries/incubator/Content/ContentTypeVisitorInterface.php +++ b/libraries/incubator/Content/ContentTypeVisitorInterface.php @@ -17,154 +17,194 @@ use Joomla\Content\Type\Dump; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; /** - * Renderer Interface + * Interface ContentTypeVisitorInterface * - * @package Joomla/Renderer + * @package Joomla\Content * * @since __DEPLOY_VERSION__ */ interface ContentTypeVisitorInterface { /** - * Render a headline. + * Render an accordion * - * @param Headline $headline The headline + * @param Accordion $accordion The accordion * - * @return integer Number of bytes written to the output + * @return void */ - public function visitHeadline(Headline $headline); + public function visitAccordion(Accordion $accordion); /** - * Render a compound (block) element + * Render an article * - * @param Compound $compound The compound + * @param Article $article The article * - * @return integer Number of bytes written to the output + * @return void */ - public function visitCompound(Compound $compound); + public function visitArticle(Article $article); /** * Render an attribution to an author * * @param Attribution $attribution The attribution * - * @return integer Number of bytes written to the output + * @return void */ public function visitAttribution(Attribution $attribution); /** - * Render a paragraph + * Render columns * - * @param Paragraph $paragraph The paragraph + * @param Columns $columns The columns * - * @return integer Number of bytes written to the output + * @return void */ - public function visitParagraph(Paragraph $paragraph); + public function visitColumns(Columns $columns); /** - * Render an image + * Render a compound (block) element * - * @param Image $image The image + * @param Compound $compound The compound * - * @return integer Number of bytes written to the output + * @return void */ - public function visitImage(Image $image); + public function visitCompound(Compound $compound); /** - * Render an slider + * Render a defaultMenu * - * @param Slider $slider The slider + * @param DefaultMenu $defaultMenu The defaultMenu * - * @return integer Number of bytes written to the output + * @return void */ - public function visitSlider(Slider $slider); + public function visitDefaultMenu(DefaultMenu $defaultMenu); /** - * Render an accordion + * Dump an item * - * @param Accordion $accordion The accordion + * @param Dump $dump The dump * - * @return integer Number of bytes written to the output + * @return void */ - public function visitAccordion(Accordion $accordion); + public function visitDump(Dump $dump); /** - * Render a tree + * Render a headline. * - * @param Tree $tree The tree + * @param Headline $headline The headline * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTree(Tree $tree); + public function visitHeadline(Headline $headline); /** - * Render tabs + * Render an image * - * @param Tabs $tabs The tabs + * @param Image $image The image * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTabs(Tabs $tabs); + public function visitImage(Image $image); /** - * Dump an item + * Render a link + * + * @param Link $link The link + * + * @return void + */ + public function visitLink(Link $link); + + /** + * Render a one-pager + * + * @param OnePager $onePager The one-pager + * + * @return void + */ + public function visitOnePager(OnePager $onePager); + + /** + * Render a one-pager section * - * @param ContentTypeInterface $dump The dump + * @param OnePagerSection $onePagerSection The one-pager section * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDump(ContentTypeInterface $dump); + public function visitOnePagerSection(OnePagerSection $onePagerSection); + + /** + * Render a paragraph + * + * @param Paragraph $paragraph The paragraph + * + * @return void + */ + public function visitParagraph(Paragraph $paragraph); /** * Render rows * * @param Rows $rows The rows * - * @return integer Number of bytes written to the output + * @return void */ public function visitRows(Rows $rows); /** - * Render columns + * Render an slider * - * @param Columns $columns The columns + * @param Slider $slider The slider * - * @return integer Number of bytes written to the output + * @return void */ - public function visitColumns(Columns $columns); + public function visitSlider(Slider $slider); /** - * Render an article + * Render an span * - * @param Article $article The article + * @param Span $span The span * - * @return integer Number of bytes written to the output + * @return void */ - public function visitArticle(Article $article); + public function visitSpan(Span $span); + + /** + * Render tabs + * + * @param Tabs $tabs The tabs + * + * @return void + */ + public function visitTabs(Tabs $tabs); /** * Render a teaser * * @param Teaser $teaser The teaser * - * @return integer Number of bytes written to the output + * @return void */ public function visitTeaser(Teaser $teaser); /** - * Render a defaultMenu + * Render a tree * - * @param DefaultMenu $defaultMenu The defaultMenu + * @param Tree $tree The tree * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDefaultMenu(DefaultMenu $defaultMenu); + public function visitTree(Tree $tree); } diff --git a/libraries/incubator/Content/ContentTypeVisitorTrait.php b/libraries/incubator/Content/ContentTypeVisitorTrait.php new file mode 100644 index 0000000000..1e7fcebd29 --- /dev/null +++ b/libraries/incubator/Content/ContentTypeVisitorTrait.php @@ -0,0 +1,281 @@ +($content)` methods to visit('visit', $content). + * This is very handy, if the implementations for the methods are very similar, since interfaces can not be + * implemented using `__call()`. + * + * @package Joomla\Content + * + * @since __DEPLOY_VERSION__ + */ +trait ContentTypeVisitorTrait +{ + /** + * Common handler for different ContentTypes. + * + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content + * + * @return mixed + */ + abstract public function visit($method, $content); + + /** + * Render an accordion + * + * @param Accordion $accordion The accordion + * + * @return void + */ + public function visitAccordion(Accordion $accordion) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render an article + * + * @param Article $article The article + * + * @return void + */ + public function visitArticle(Article $article) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render an attribution to an author + * + * @param Attribution $attribution The attribution + * + * @return void + */ + public function visitAttribution(Attribution $attribution) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render columns + * + * @param Columns $columns The columns + * + * @return void + */ + public function visitColumns(Columns $columns) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a compound (block) element + * + * @param Compound $compound The compound + * + * @return void + */ + public function visitCompound(Compound $compound) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a defaultMenu + * + * @param DefaultMenu $defaultMenu The defaultMenu + * + * @return void + */ + public function visitDefaultMenu(DefaultMenu $defaultMenu) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render dump + * + * @param Dump $dump The dump + * + * @return void + */ + public function visitDump(Dump $dump) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a headline. + * + * @param Headline $headline The headline + * + * @return void + */ + public function visitHeadline(Headline $headline) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render an image + * + * @param Image $image The image + * + * @return void + */ + public function visitImage(Image $image) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a link + * + * @param Link $link The link + * + * @return void + */ + public function visitLink(Link $link) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a one-pager + * + * @param OnePager $onePager The one-pager + * + * @return void + */ + public function visitOnePager(OnePager $onePager) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a one-pager section + * + * @param OnePagerSection $onePagerSection The one-pager section + * + * @return void + */ + public function visitOnePagerSection(OnePagerSection $onePagerSection) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a paragraph + * + * @param Paragraph $paragraph The paragraph + * + * @return void + */ + public function visitParagraph(Paragraph $paragraph) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render rows + * + * @param Rows $rows The rows + * + * @return void + */ + public function visitRows(Rows $rows) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render an slider + * + * @param Slider $slider The slider + * + * @return void + */ + public function visitSlider(Slider $slider) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render an span + * + * @param Span $span The span + * + * @return void + */ + public function visitSpan(Span $span) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render tabs + * + * @param Tabs $tabs The tabs + * + * @return void + */ + public function visitTabs(Tabs $tabs) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a teaser + * + * @param Teaser $teaser The teaser + * + * @return void + */ + public function visitTeaser(Teaser $teaser) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } + + /** + * Render a tree + * + * @param Tree $tree The tree + * + * @return void + */ + public function visitTree(Tree $tree) + { + $this->visit(__FUNCTION__, func_get_arg(0)); + } +} diff --git a/libraries/incubator/Content/Type/Accordion.php b/libraries/incubator/Content/Type/Accordion.php index 423ab9b5de..df77f97c10 100644 --- a/libraries/incubator/Content/Type/Accordion.php +++ b/libraries/incubator/Content/Type/Accordion.php @@ -26,10 +26,10 @@ class Accordion extends AbstractCompoundType * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitAccordion($this); + $visitor->visitAccordion($this); } } diff --git a/libraries/incubator/Content/Type/Article.php b/libraries/incubator/Content/Type/Article.php index 243399e2a4..dc2ca2181b 100644 --- a/libraries/incubator/Content/Type/Article.php +++ b/libraries/incubator/Content/Type/Article.php @@ -38,11 +38,11 @@ public function __construct($item) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitArticle($this); + $visitor->visitArticle($this); } /** diff --git a/libraries/incubator/Content/Type/Attribution.php b/libraries/incubator/Content/Type/Attribution.php index e3854c66d3..8cde0a0d6d 100644 --- a/libraries/incubator/Content/Type/Attribution.php +++ b/libraries/incubator/Content/Type/Attribution.php @@ -40,10 +40,10 @@ public function __construct($label, $name) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitAttribution($this); + $visitor->visitAttribution($this); } } diff --git a/libraries/incubator/Content/Type/Columns.php b/libraries/incubator/Content/Type/Columns.php index a00d139acb..f9e0646cbc 100644 --- a/libraries/incubator/Content/Type/Columns.php +++ b/libraries/incubator/Content/Type/Columns.php @@ -24,10 +24,10 @@ class Columns extends Compound * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitColumns($this); + $visitor->visitColumns($this); } } diff --git a/libraries/incubator/Content/Type/Compound.php b/libraries/incubator/Content/Type/Compound.php index ea314ce57e..f2fc94ad39 100644 --- a/libraries/incubator/Content/Type/Compound.php +++ b/libraries/incubator/Content/Type/Compound.php @@ -45,11 +45,11 @@ public function __construct($type, $title, $id, $params, $elements = []) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitCompound($this); + $visitor->visitCompound($this); } /** diff --git a/libraries/incubator/Content/Type/DefaultMenu.php b/libraries/incubator/Content/Type/DefaultMenu.php index d89ac02c63..15b64f5332 100644 --- a/libraries/incubator/Content/Type/DefaultMenu.php +++ b/libraries/incubator/Content/Type/DefaultMenu.php @@ -37,10 +37,10 @@ public function __construct($item) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitDefaultMenu($this); + $visitor->visitDefaultMenu($this); } } diff --git a/libraries/incubator/Content/Type/Dump.php b/libraries/incubator/Content/Type/Dump.php index 83c2fa6c48..7abb9f7dab 100644 --- a/libraries/incubator/Content/Type/Dump.php +++ b/libraries/incubator/Content/Type/Dump.php @@ -38,10 +38,10 @@ public function __construct($item) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitDump($this); + $visitor->visitDump($this); } } diff --git a/libraries/incubator/Content/Type/Headline.php b/libraries/incubator/Content/Type/Headline.php index d78a570390..bfb0c4746c 100644 --- a/libraries/incubator/Content/Type/Headline.php +++ b/libraries/incubator/Content/Type/Headline.php @@ -40,10 +40,10 @@ public function __construct($text, $level = 1) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitHeadline($this); + $visitor->visitHeadline($this); } } diff --git a/libraries/incubator/Content/Type/HorizontalLine.php b/libraries/incubator/Content/Type/HorizontalLine.php index 008c7019eb..a14f7106f8 100644 --- a/libraries/incubator/Content/Type/HorizontalLine.php +++ b/libraries/incubator/Content/Type/HorizontalLine.php @@ -25,10 +25,10 @@ class HorizontalLine extends AbstractContentType * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitHorizontalLine($this); + $visitor->visitHorizontalLine($this); } } diff --git a/libraries/incubator/Content/Type/Icon.php b/libraries/incubator/Content/Type/Icon.php index 8e8083d5c0..1f17339844 100644 --- a/libraries/incubator/Content/Type/Icon.php +++ b/libraries/incubator/Content/Type/Icon.php @@ -43,10 +43,10 @@ public function __construct($name) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitIcon($this); + $visitor->visitIcon($this); } } diff --git a/libraries/incubator/Content/Type/Image.php b/libraries/incubator/Content/Type/Image.php index 18b3defb37..b70f326895 100644 --- a/libraries/incubator/Content/Type/Image.php +++ b/libraries/incubator/Content/Type/Image.php @@ -41,11 +41,11 @@ public function __construct(ImageEntity $item, $alt = '') * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitImage($this); + $visitor->visitImage($this); } /** diff --git a/libraries/incubator/Content/Type/Link.php b/libraries/incubator/Content/Type/Link.php index 2c1a04d2d8..8ef95fb0ac 100644 --- a/libraries/incubator/Content/Type/Link.php +++ b/libraries/incubator/Content/Type/Link.php @@ -47,10 +47,10 @@ public function __construct($href, $text) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitLink($this); + $visitor->visitLink($this); } } diff --git a/libraries/incubator/Content/Type/OnePager.php b/libraries/incubator/Content/Type/OnePager.php index c320d30838..1567a7656d 100644 --- a/libraries/incubator/Content/Type/OnePager.php +++ b/libraries/incubator/Content/Type/OnePager.php @@ -27,10 +27,10 @@ class OnePager extends AbstractCompoundType * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitOnePager($this); + $visitor->visitOnePager($this); } } diff --git a/libraries/incubator/Content/Type/OnePagerSection.php b/libraries/incubator/Content/Type/OnePagerSection.php index 1b4b1879e5..21a15fc70a 100644 --- a/libraries/incubator/Content/Type/OnePagerSection.php +++ b/libraries/incubator/Content/Type/OnePagerSection.php @@ -27,10 +27,10 @@ class OnePagerSection extends Compound * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitOnePagerSection($this); + $visitor->visitOnePagerSection($this); } } diff --git a/libraries/incubator/Content/Type/Paragraph.php b/libraries/incubator/Content/Type/Paragraph.php index 9db55815cd..c37489d3b2 100644 --- a/libraries/incubator/Content/Type/Paragraph.php +++ b/libraries/incubator/Content/Type/Paragraph.php @@ -43,10 +43,10 @@ public function __construct($text, $variant = self::PLAIN) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitParagraph($this); + $visitor->visitParagraph($this); } } diff --git a/libraries/incubator/Content/Type/Rows.php b/libraries/incubator/Content/Type/Rows.php index 0f062f7379..0292afcca9 100644 --- a/libraries/incubator/Content/Type/Rows.php +++ b/libraries/incubator/Content/Type/Rows.php @@ -24,10 +24,10 @@ class Rows extends Compound * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitRows($this); + $visitor->visitRows($this); } } diff --git a/libraries/incubator/Content/Type/Slider.php b/libraries/incubator/Content/Type/Slider.php index 403b5cbdbe..4971b39059 100644 --- a/libraries/incubator/Content/Type/Slider.php +++ b/libraries/incubator/Content/Type/Slider.php @@ -24,10 +24,10 @@ class Slider extends AbstractCompoundType * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitSlider($this); + $visitor->visitSlider($this); } } diff --git a/libraries/incubator/Content/Type/Span.php b/libraries/incubator/Content/Type/Span.php index 7fc9256c50..65bebf75a0 100644 --- a/libraries/incubator/Content/Type/Span.php +++ b/libraries/incubator/Content/Type/Span.php @@ -37,10 +37,10 @@ public function __construct($text) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitSpan($this); + $visitor->visitSpan($this); } } diff --git a/libraries/incubator/Content/Type/Tabs.php b/libraries/incubator/Content/Type/Tabs.php index 3bc83d4e4d..4e050ffc54 100644 --- a/libraries/incubator/Content/Type/Tabs.php +++ b/libraries/incubator/Content/Type/Tabs.php @@ -24,10 +24,10 @@ class Tabs extends AbstractCompoundType * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitTabs($this); + $visitor->visitTabs($this); } } diff --git a/libraries/incubator/Content/Type/Teaser.php b/libraries/incubator/Content/Type/Teaser.php index 7c9b5273b5..c453db19af 100644 --- a/libraries/incubator/Content/Type/Teaser.php +++ b/libraries/incubator/Content/Type/Teaser.php @@ -38,10 +38,10 @@ public function __construct($item) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitTeaser($this); + $visitor->visitTeaser($this); } } diff --git a/libraries/incubator/Content/Type/Tree.php b/libraries/incubator/Content/Type/Tree.php index 5dcc81a8cd..81ae6c8f9b 100644 --- a/libraries/incubator/Content/Type/Tree.php +++ b/libraries/incubator/Content/Type/Tree.php @@ -38,10 +38,10 @@ public function __construct($item) * * @param ContentTypeVisitorInterface $visitor The Visitor * - * @return mixed + * @return void */ public function accept(ContentTypeVisitorInterface $visitor) { - return $visitor->visitTree($this); + $visitor->visitTree($this); } } diff --git a/libraries/incubator/Http/Middleware/RendererMiddleware.php b/libraries/incubator/Http/Middleware/RendererMiddleware.php index f1b02e6cc6..ed2168b2cc 100644 --- a/libraries/incubator/Http/Middleware/RendererMiddleware.php +++ b/libraries/incubator/Http/Middleware/RendererMiddleware.php @@ -8,11 +8,15 @@ namespace Joomla\Http\Middleware; -use Interop\Container\ContainerInterface; +use GuzzleHttp\Psr7\Stream; +use Joomla\Content\CustomContentTypeInterface; +use Joomla\DI\Container; use Joomla\Event\Dispatcher; +use Joomla\Extension\ExtensionInterface; use Joomla\Http\MiddlewareInterface; use Joomla\Renderer\EventDecorator; use Joomla\Renderer\Factory as RendererFactory; +use Joomla\Renderer\RendererInterface; use Psr\Http\Message\ResponseInterface; use Psr\Http\Message\ServerRequestInterface; @@ -28,22 +32,26 @@ */ class RendererMiddleware implements MiddlewareInterface { - /** @var Dispatcher */ + /** @var string */ + private $mappingFile; + + /** @var Dispatcher */ private $dispatcher; - /** @var ContainerInterface */ + /** @var Container */ private $container; /** * RendererMiddleware constructor. * - * @param Dispatcher $dispatcher The event dispatcher - * @param ContainerInterface $container The container + * @param Dispatcher $dispatcher The event dispatcher + * @param Container $container The container */ - public function __construct(Dispatcher $dispatcher, ContainerInterface $container) + public function __construct(Dispatcher $dispatcher, Container $container) { - $this->dispatcher = $dispatcher; - $this->container = $container; + $this->mappingFile = JPATH_ROOT . '/config/renderer.ini'; + $this->dispatcher = $dispatcher; + $this->container = $container; } /** @@ -58,6 +66,27 @@ public function __construct(Dispatcher $dispatcher, ContainerInterface $containe * @return ResponseInterface */ public function handle(ServerRequestInterface $request, ResponseInterface $response, callable $next = null) + { + $renderer = $this->createRenderer($request); + + $this->registerContentTypes($renderer, $this->container->get('extension_factory')->getExtensions()); + + $this->container->set('Renderer', $renderer); + + /** @var ResponseInterface $response */ + $response = $next($request, $response); + + return $response->withBody($this->createStream($renderer)); + } + + /** + * Create a renderer matching the request. + * + * @param ServerRequestInterface $request The Request + * + * @return RendererInterface The renderer + */ + private function createRenderer(ServerRequestInterface $request) { $acceptHeader = $request->getHeaderLine('Accept'); @@ -66,21 +95,60 @@ public function handle(ServerRequestInterface $request, ResponseInterface $respo $acceptHeader = 'text/plain'; } - $mapping = parse_ini_file(JPATH_ROOT . '/config/renderer.ini'); + $mapping = parse_ini_file($this->mappingFile); $renderer = (new RendererFactory($mapping))->create($acceptHeader, $this->container); + $renderer = new EventDecorator($renderer, $this->dispatcher); + + return $renderer; + } - foreach ($this->container->get('extension_factory')->getExtensions() as $extension) + /** + * Register custom content types with the renderer. + * + * @param RendererInterface $renderer The renderer + * @param ExtensionInterface[] $extensions The extensions + */ + private function registerContentTypes(RendererInterface $renderer, array $extensions) + { + foreach ($extensions as $extension) { foreach ($extension->getContentTypes() as $contentTypeClass) { - (new $contentTypeClass)->register($renderer); + /** @var CustomContentTypeInterface $contentType */ + $contentType = new $contentTypeClass; + $contentType->register($renderer); } } + } - $renderer = new EventDecorator($renderer, $this->dispatcher); + /** + * Create a PSR-7 message stream from the renderer's content. + * + * @param RendererInterface $renderer The renderer + * + * @return Stream The PSR-7 message stream + */ + private function createStream(RendererInterface $renderer) + { + $stream = fopen('php://temp', 'r+'); + $content = (string) $renderer; + + if ($content !== '') + { + fwrite($stream, $content); + fseek($stream, 0); + } - $response = $next($request, $response->withBody($renderer)); + $options = [ + 'wrapper_data' => [ + 'renderer' => $renderer->getClass(), + ], + 'wrapper_type' => 'RFC2397', + 'stream_type' => 'RFC2397', + 'mediatype' => $renderer->getMediaType(), + 'base64' => false, + ]; - return $response; + return new Stream($stream, $options); } } diff --git a/libraries/incubator/PageBuilder/DisplayPageCommand.php b/libraries/incubator/PageBuilder/DisplayPageCommand.php index b130db690a..40ad6ab1a9 100644 --- a/libraries/incubator/PageBuilder/DisplayPageCommand.php +++ b/libraries/incubator/PageBuilder/DisplayPageCommand.php @@ -9,6 +9,7 @@ namespace Joomla\PageBuilder; use Interop\Container\ContainerInterface; +use Joomla\Renderer\RendererInterface; use Joomla\Service\Command; use Psr\Http\Message\ServerRequestInterface; use Psr\Http\Message\StreamInterface; @@ -23,24 +24,24 @@ class DisplayPageCommand extends Command private $id; private $vars; private $request; - private $stream; + private $renderer; private $container; /** * DisplayPageCommand constructor. * - * @param integer $id The page ID - * @param array $vars Routing variables - * @param ServerRequestInterface $request The request object - * @param StreamInterface $stream The output stream + * @param integer $id The page ID + * @param array $vars Routing variables + * @param ServerRequestInterface $request The request object + * @param RendererInterface $renderer The renderer * @param ContainerInterface $container */ - public function __construct($id, $vars, $request, $stream, $container) + public function __construct($id, $vars, $request, $renderer, $container) { $this->id = $id; $this->vars = $vars; $this->request = $request; - $this->stream = $stream; + $this->renderer = $renderer; $this->container = $container; parent::__construct(); @@ -73,9 +74,9 @@ public function getRequest() /** * @return StreamInterface */ - public function getStream() + public function getRenderer() { - return $this->stream; + return $this->renderer; } /** diff --git a/libraries/incubator/PageBuilder/DisplayPageCommandHandler.php b/libraries/incubator/PageBuilder/DisplayPageCommandHandler.php index b13175b30c..db810cae02 100644 --- a/libraries/incubator/PageBuilder/DisplayPageCommandHandler.php +++ b/libraries/incubator/PageBuilder/DisplayPageCommandHandler.php @@ -61,7 +61,7 @@ public function handle(DisplayPageCommand $command) $id = $command->getId(); $this->vars = $command->getVars(); $this->request = $command->getRequest(); - $this->output = $command->getStream(); + $this->output = $command->getRenderer(); $this->container = $command->getContainer(); $this->registerContentTypes(); diff --git a/libraries/incubator/PageBuilder/RouterMiddleware.php b/libraries/incubator/PageBuilder/RouterMiddleware.php index db2d517003..aa87ff0ad0 100644 --- a/libraries/incubator/PageBuilder/RouterMiddleware.php +++ b/libraries/incubator/PageBuilder/RouterMiddleware.php @@ -48,7 +48,7 @@ public function __construct(Container $container) * @param ResponseInterface $response The response object * @param callable $next The next middleware handler * - * @return ResponseInterface + * @return ResponseInterface The response */ public function handle(ServerRequestInterface $request, ResponseInterface $response, callable $next = null) { @@ -68,7 +68,8 @@ public function handle(ServerRequestInterface $request, ResponseInterface $respo foreach ($pages as $page) { - $router->get($this->expandUrl($page->url, $page), function () use ($page) { + $router->get($this->expandUrl($page->url, $page), function () use ($page) + { return $page; }); } @@ -78,7 +79,7 @@ public function handle(ServerRequestInterface $request, ResponseInterface $respo $page = $route['controller'](); $vars = $route['vars']; - $command = new DisplayPageCommand($page->id, $vars, $request, $response->getBody(), $this->container); + $command = new DisplayPageCommand($page->id, $vars, $request, $this->container->get('Renderer'), $this->container); $request = $request->withAttribute('command', $command); // @todo Emit afterRouting event } @@ -92,10 +93,12 @@ public function handle(ServerRequestInterface $request, ResponseInterface $respo } /** - * @param $url - * @param $page + * Get the full URL for a page. * - * @return string + * @param string $url The local URL + * @param Page $page The page belonging to that URL + * + * @return string The full URL */ private function expandUrl($url, $page) { diff --git a/libraries/incubator/Renderer/AnsiRenderer.php b/libraries/incubator/Renderer/AnsiRenderer.php index df0929e527..e1ce89755a 100644 --- a/libraries/incubator/Renderer/AnsiRenderer.php +++ b/libraries/incubator/Renderer/AnsiRenderer.php @@ -9,20 +9,8 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; -use Joomla\Content\Type\Accordion; -use Joomla\Content\Type\Article; -use Joomla\Content\Type\Attribution; -use Joomla\Content\Type\Columns; -use Joomla\Content\Type\Compound; -use Joomla\Content\Type\DefaultMenu; -use Joomla\Content\Type\Headline; -use Joomla\Content\Type\Image; -use Joomla\Content\Type\Paragraph; -use Joomla\Content\Type\Rows; -use Joomla\Content\Type\Slider; -use Joomla\Content\Type\Tabs; -use Joomla\Content\Type\Teaser; -use Joomla\Content\Type\Tree; +use Joomla\Content\ContentTypeVisitorTrait; +use Joomla\Content\Type\Dump; /** * Class AnsiRenderer @@ -36,213 +24,30 @@ class AnsiRenderer extends Renderer /** @var string The MIME type */ protected $mediatype = 'text/ansi'; - /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } + use ContentTypeVisitorTrait; /** - * Render a compound (block) element + * Common handler for different ContentTypes. * - * @param Compound $compound The compound + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer Number of bytes written to the output + * @return mixed */ - public function visitCompound(Compound $compound) + public function visit($method, $content) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an attribution to an author - * - * @param Attribution $attribution The attribution - * - * @return integer Number of bytes written to the output - */ - public function visitAttribution(Attribution $attribution) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a paragraph - * - * @param Paragraph $paragraph The paragraph - * - * @return integer Number of bytes written to the output - */ - public function visitParagraph(Paragraph $paragraph) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + throw new \LogicException($method . ' is not implemented.'); } /** * Render dump * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - return $this->write(print_r($dump->item, true)); - - return 0; - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser + * @param Dump $dump The dump * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTeaser(Teaser $teaser) + public function visitDump(Dump $dump) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a defaultMenu - * - * @param DefaultMenu $defaultMenu The defaultMenu - * - * @return integer Number of bytes written to the output - */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + $this->write(print_r($dump->item, true)); } } diff --git a/libraries/incubator/Renderer/DocbookRenderer.php b/libraries/incubator/Renderer/DocbookRenderer.php index 00a8640872..ab27f1eeab 100644 --- a/libraries/incubator/Renderer/DocbookRenderer.php +++ b/libraries/incubator/Renderer/DocbookRenderer.php @@ -9,20 +9,7 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; -use Joomla\Content\Type\Accordion; -use Joomla\Content\Type\Article; -use Joomla\Content\Type\Attribution; -use Joomla\Content\Type\Columns; -use Joomla\Content\Type\Compound; -use Joomla\Content\Type\DefaultMenu; -use Joomla\Content\Type\Headline; -use Joomla\Content\Type\Image; -use Joomla\Content\Type\Paragraph; -use Joomla\Content\Type\Rows; -use Joomla\Content\Type\Slider; -use Joomla\Content\Type\Tabs; -use Joomla\Content\Type\Teaser; -use Joomla\Content\Type\Tree; +use Joomla\Content\ContentTypeVisitorTrait; /** * Class DocbookRenderer @@ -36,213 +23,18 @@ class DocbookRenderer extends Renderer /** @var string The MIME type */ protected $mediatype = 'application/docbook+xml'; - /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a compound (block) element - * - * @param Compound $compound The compound - * - * @return integer Number of bytes written to the output - */ - public function visitCompound(Compound $compound) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an attribution to an author - * - * @param Attribution $attribution The attribution - * - * @return integer Number of bytes written to the output - */ - public function visitAttribution(Attribution $attribution) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a paragraph - * - * @param Paragraph $paragraph The paragraph - * - * @return integer Number of bytes written to the output - */ - public function visitParagraph(Paragraph $paragraph) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Dump an item - * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } + use ContentTypeVisitorTrait; /** - * Render a defaultMenu + * Common handler for different ContentTypes. * - * @param DefaultMenu $defaultMenu The defaultMenu + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer Number of bytes written to the output + * @return mixed */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) + public function visit($method, $content) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + throw new \LogicException($method . ' is not implemented.'); } } diff --git a/libraries/incubator/Renderer/Event/RenderContentTypeSuccessEvent.php b/libraries/incubator/Renderer/Event/RenderContentTypeSuccessEvent.php index 47395ae770..1b91cb46e7 100644 --- a/libraries/incubator/Renderer/Event/RenderContentTypeSuccessEvent.php +++ b/libraries/incubator/Renderer/Event/RenderContentTypeSuccessEvent.php @@ -9,30 +9,30 @@ namespace Joomla\Renderer\Event; use Joomla\Event\Event; -use Psr\Http\Message\StreamInterface; +use Joomla\Renderer\RendererInterface; /** * Class RenderContentTypeSuccessEvent * * @package Joomla\Renderer * - * @since 1.0 + * @since __DEPLOY_VERSION__ */ class RenderContentTypeSuccessEvent extends Event { /** * RenderContentTypeSuccessEvent constructor. * - * @param string $type The name of the content type - * @param StreamInterface $stream The stream to which the content is added + * @param string $type The name of the content type + * @param RendererInterface $renderer The renderer to which the content is added */ - public function __construct($type, $stream) + public function __construct($type, $renderer) { parent::__construct( 'onAfter' . $type, [ - 'type' => $type, - 'stream' => $stream + 'type' => $type, + 'renderer' => clone($renderer) ] ); } diff --git a/libraries/incubator/Renderer/EventDecorator.php b/libraries/incubator/Renderer/EventDecorator.php index b77cdad9e3..6a3649bc17 100644 --- a/libraries/incubator/Renderer/EventDecorator.php +++ b/libraries/incubator/Renderer/EventDecorator.php @@ -9,18 +9,22 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; +use Joomla\Content\ContentTypeVisitorTrait; use Joomla\Content\Type\Accordion; use Joomla\Content\Type\Article; use Joomla\Content\Type\Attribution; use Joomla\Content\Type\Columns; use Joomla\Content\Type\Compound; use Joomla\Content\Type\DefaultMenu; -use Joomla\Content\Type\Dump; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -47,66 +51,36 @@ class EventDecorator implements RendererInterface /** @var DispatcherInterface */ private $dispatcher; - /** - * Decorator constructor. - * - * @param RendererInterface $renderer The renderer to be decorated - * @param DispatcherInterface $dispatcher The dispather handling the events - */ - public function __construct(RendererInterface $renderer, DispatcherInterface $dispatcher) - { - $this->renderer = $renderer; - $this->dispatcher = $dispatcher; - } + use ContentTypeVisitorTrait; /** - * @param string $type The content type - * @param callable|array|string $handler The handler for that type + * Common handler for different ContentTypes. * - * @return void + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @throws \Exception + * @return mixed */ - public function registerContentType($type, $handler) + public function visit($method, $content) { - $this->dispatcher->dispatch(new RegisterContentTypeEvent($type, $handler)); - - try - { - $this->renderer->registerContentType($type, $handler); - $this->dispatcher->dispatch(new RegisterContentTypeSuccessEvent($type, $handler)); - } - catch (\Exception $exception) - { - $this->dispatcher->dispatch(new RegisterContentTypeFailureEvent($type, $exception)); - throw $exception; - } + $this->delegate($method, [$content]); } /** - * @param string $method Method name; must start with 'visit' - * @param array $arguments Method arguments + * Decorator constructor. * - * @return mixed - * @throws \Exception + * @param RendererInterface $renderer The renderer to be decorated + * @param DispatcherInterface $dispatcher The dispather handling the events */ - public function __call($method, $arguments) + public function __construct(RendererInterface $renderer, DispatcherInterface $dispatcher) { - return $this->delegate($method, $arguments); + $this->renderer = $renderer; + $this->dispatcher = $dispatcher; } /** - * Reads all data from the stream into a string, from the beginning to end. - * - * This method MUST attempt to seek to the beginning of the stream before - * reading data and read the stream until the end is reached. - * - * Warning: This could attempt to load a large amount of data into memory. - * - * This method MUST NOT raise an exception in order to conform with PHP's - * string casting operations. + * Get the content from the buffer * - * @see http://php.net/manual/en/language.oop5.magic.php#object.tostring * @return string */ public function __toString() @@ -115,186 +89,75 @@ public function __toString() } /** - * Closes the stream and any underlying resources. + * Get the (inner) class of this renderer. * - * @return void - */ - public function close() - { - $this->renderer->close(); - } - - /** - * Separates any underlying resources from the stream. - * - * After the stream has been detached, the stream is in an unusable state. - * - * @return resource|null Underlying PHP stream, if any - */ - public function detach() - { - return $this->renderer->detach(); - } - - /** - * Get the size of the stream if known. - * - * @return integer|null Returns the size in bytes if known, or null if unknown. - */ - public function getSize() - { - return $this->renderer->getSize(); - } - - /** - * Returns the current position of the file read/write pointer - * - * @return integer Position of the file pointer - * @throws \RuntimeException on error. - */ - public function tell() - { - return $this->renderer->tell(); - } - - /** - * Returns true if the stream is at the end of the stream. - * - * @return boolean - */ - public function eof() - { - return $this->renderer->eof(); - } - - /** - * Returns whether or not the stream is seekable. - * - * @return boolean + * @return string */ - public function isSeekable() + public function getClass() { - return $this->renderer->isSeekable(); + return $this->renderer->getClass(); } /** - * Seek to a position in the stream. + * Get the media (MIME) type for this renderer. * - * @link http://www.php.net/manual/en/function.fseek.php - * - * @param int $offset Stream offset - * @param int $whence Specifies how the cursor position will be calculated - * based on the seek offset. Valid values are identical to the built-in - * PHP $whence values for `fseek()`. SEEK_SET: Set position equal to - * offset bytes SEEK_CUR: Set position to current location plus offset - * SEEK_END: Set position to end-of-stream plus offset. - * - * @return void - * - * @throws \RuntimeException on failure. + * @return string */ - public function seek($offset, $whence = SEEK_SET) + public function getMediaType() { - $this->renderer->seek($offset, $whence); + return $this->renderer->getMediaType(); } /** - * Seek to the beginning of the stream. - * - * If the stream is not seekable, this method will raise an exception; - * otherwise, it will perform a seek(0). + * Register a handler for a content type. * - * @see seek() - * @link http://www.php.net/manual/en/function.fseek.php + * @param string $type The content type + * @param callable|array|string $handler The handler for that type * * @return void - * @throws \RuntimeException on failure. - */ - public function rewind() - { - $this->renderer->rewind(); - } - - /** - * Returns whether or not the stream is writable. * - * @return boolean - */ - public function isWritable() - { - return $this->renderer->isWritable(); - } - - /** - * Write data to the stream. - * - * @param string $string The string that is to be written. - * - * @return integer Returns the number of bytes written to the stream. - * @throws \RuntimeException on failure. - */ - public function write($string) - { - return $this->renderer->write($string); - } - - /** - * Returns whether or not the stream is readable. - * - * @return boolean + * @throws \Exception */ - public function isReadable() + public function registerContentType($type, $handler) { - return $this->renderer->isReadable(); - } + $this->dispatcher->dispatch(new RegisterContentTypeEvent($type, $handler)); - /** - * Read data from the stream. - * - * @param int $length Read up to $length bytes from the object and return - * them. Fewer than $length bytes may be returned if underlying stream - * call returns fewer bytes. - * - * @return string Returns the data read from the stream, or an empty string - * if no bytes are available. - * - * @throws \RuntimeException if an error occurs. - */ - public function read($length) - { - return $this->renderer->read($length); + try + { + $this->renderer->registerContentType($type, $handler); + $this->dispatcher->dispatch(new RegisterContentTypeSuccessEvent($type, $handler)); + } + catch (\Exception $exception) + { + $this->dispatcher->dispatch(new RegisterContentTypeFailureEvent($type, $exception)); + throw $exception; + } } /** - * Returns the remaining contents in a string + * Write data to the output. * - * @return string + * @param ContentTypeInterface|string $content The string that is to be written. * - * @throws \RuntimeException if unable to read or an error occurs while - * reading. + * @return void */ - public function getContents() + public function write($content) { - return $this->renderer->getContents(); + $this->renderer->write($content); } /** - * Get stream metadata as an associative array or retrieve a specific key. - * - * The keys returned are identical to the keys returned from PHP's - * stream_get_meta_data() function. - * - * @link http://php.net/manual/en/function.stream-get-meta-data.php + * Delegate all methods. * - * @param string $key Specific metadata to retrieve. + * @param string $method Method name; must start with 'visit' + * @param array $arguments Method arguments * - * @return array|mixed|null Returns an associative array if no key is - * provided. Returns a specific key value if a key is provided and the - * value is found, or null if the key is not found. + * @return mixed + * @throws \Exception */ - public function getMetadata($key = null) + public function __call($method, $arguments) { - return $this->renderer->getMetadata($key); + return $this->delegate($method, $arguments); } /** @@ -314,10 +177,10 @@ private function delegate($method, $arguments) try { - $result = call_user_func_array([$this->renderer, $method], $arguments); + call_user_func_array([$this->renderer, $method], $arguments); $this->dispatcher->dispatch(new RenderContentTypeSuccessEvent($type, $this->renderer)); - return $result; + return null; } catch (\Exception $exception) { @@ -330,192 +193,4 @@ private function delegate($method, $arguments) return call_user_func_array([$this->renderer, $method], $arguments); } } - - /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - return $this->delegate('visitHeadline', [$headline]); - } - - /** - * Render a compound (block) element - * - * @param Compound $compound The compound - * - * @return integer Number of bytes written to the output - */ - public function visitCompound(Compound $compound) - { - return $this->delegate('visitCompound', [$compound]); - } - - /** - * Render an attribution to an author - * - * @param Attribution $attribution The attribution - * - * @return integer Number of bytes written to the output - */ - public function visitAttribution(Attribution $attribution) - { - return $this->delegate('visitAttribution', [$attribution]); - } - - /** - * Render a paragraph - * - * @param Paragraph $paragraph The paragraph - * - * @return integer Number of bytes written to the output - */ - public function visitParagraph(Paragraph $paragraph) - { - return $this->delegate('visitParagraph', [$paragraph]); - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - return $this->delegate('visitImage', [$image]); - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - return $this->delegate('visitSlider', [$slider]); - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - return $this->delegate('visitAccordion', [$accordion]); - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - return $this->delegate('visitTree', [$tree]); - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - return $this->delegate('visitTabs', [$tabs]); - } - - /** - * Dump an item - * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - return $this->delegate('visitDump', [$dump]); - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - return $this->delegate('visitRows', [$rows]); - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - return $this->delegate('visitColumns', [$columns]); - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - return $this->delegate('visitArticle', [$article]); - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - return $this->delegate('visitTeaser', [$teaser]); - } - - /** - * Render a defaultMenu - * - * @param DefaultMenu $defaultMenu The defaultMenu - * - * @return integer Number of bytes written to the output - */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) - { - return $this->delegate('visitDefaultMenu', [$defaultMenu]); - } - - /** - * @return string - */ - public function getClass() - { - return $this->renderer->getClass(); - } } diff --git a/libraries/incubator/Renderer/HtmlRenderer.php b/libraries/incubator/Renderer/HtmlRenderer.php index cada8c76c0..9078f78b72 100644 --- a/libraries/incubator/Renderer/HtmlRenderer.php +++ b/libraries/incubator/Renderer/HtmlRenderer.php @@ -16,6 +16,7 @@ use Joomla\Content\Type\Columns; use Joomla\Content\Type\Compound; use Joomla\Content\Type\DefaultMenu; +use Joomla\Content\Type\Dump; use Joomla\Content\Type\Headline; use Joomla\Content\Type\HorizontalLine; use Joomla\Content\Type\Icon; @@ -31,7 +32,6 @@ use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; use Joomla\ORM\Operator; -use Joomla\ORM\Repository\RepositoryInterface; use Joomla\PageBuilder\Entity\Layout; use Joomla\PageBuilder\Entity\Page; use Joomla\Renderer\Exception\NotFoundException; @@ -67,85 +67,43 @@ class HtmlRenderer extends Renderer use DumpTrait; /** - * @param ScriptStrategyInterface $strategy The scripting strategy (library) to use - * - * @return void - */ - public function setScriptStrategy(ScriptStrategyInterface $strategy) - { - $this->clientScript = $strategy; - } - - /** - * Sets the template + * Render an accordion * - * @param string $template The template + * @param Accordion $accordion The accordion * * @return void */ - public function setTemplate($template) + public function visitAccordion(Accordion $accordion) { - $this->template = $template; - } + $accordion->setId('accordion-' . spl_object_hash($accordion)); - /** - * @param string $label An identifier - * @param string $code The code associated with that identifier - * - * @return void - */ - public function addJavascript($label, $code) - { - $this->javascript[$label] = $code; - } + $this->preRenderChildElements($accordion); - /** - * @param string $namespace - * @param string $css - * - * @return void - */ - public function addCss($namespace, $css) - { - $this->style[] = preg_replace_callback( - '~([^{\s]*\s?\{[^{]*?\})~sm', - function ($match) use ($namespace) - { - return "#{$namespace} {$match[0]}"; - }, - $css - ); + $this->applyLayout('accordion.php', $accordion); } /** + * @param ContentTypeInterface $content The content element + * * @return void */ - public function writeJavascript() + private function preRenderChildElements(ContentTypeInterface $content) { - $this->write(''); - } + if (!isset($content->elements)) + { + return; + } - /** - * @return void - */ - public function writeCss() - { - $this->write(''); - } + $stash = $this->output; - /** - * @return array - */ - protected function collectMetadata() - { - $metaData = parent::collectMetadata(); - $metaData['wrapper_data']['client_script'] = empty($this->clientScript) ? null : get_class($this->clientScript); + foreach ($content->elements as $key => $item) + { + $this->output = ''; + $item->accept($this); + $item->html = $this->output; + } - return $metaData; + $this->output = $stash; } /** @@ -154,12 +112,11 @@ protected function collectMetadata() * @param string $filename The filename of the layout file * @param object|ContentTypeInterface $content The content * - * @return integer + * @return void */ private function applyLayout($filename, $content) { - $renderer = $this; - $layout = JPATH_ROOT . '/' . $this->template . '/overrides/' . $filename; + $layout = JPATH_ROOT . '/' . $this->template . '/overrides/' . $filename; if (!file_exists($layout)) { @@ -170,31 +127,19 @@ private function applyLayout($filename, $content) include $layout; $html = ob_get_clean(); - return $this->write($html); + $this->write($html); } /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - return $this->applyLayout('headline.php', $headline); - } - - /** - * Render a horizontal line. + * Render an article * - * @param HorizontalLine $headline The horizontal line + * @param Article $article The article * - * @return integer Number of bytes written to the output + * @return void */ - public function visitHorizontalLine(HorizontalLine $headline) + public function visitArticle(Article $article) { - return $this->write("
\n"); + $this->applyLayout('article.php', $article); } /** @@ -202,35 +147,25 @@ public function visitHorizontalLine(HorizontalLine $headline) * * @param Attribution $attribution The attribution * - * @return integer Number of bytes written to the output + * @return void */ public function visitAttribution(Attribution $attribution) { - return $this->applyLayout('attribution.php', $attribution); + $this->applyLayout('attribution.php', $attribution); } /** - * Render a paragraph + * Render columns * - * @param Paragraph $paragraph The paragraph + * @param Columns $columns The columns * - * @return integer Number of bytes written to the output + * @return void */ - public function visitParagraph(Paragraph $paragraph) + public function visitColumns(Columns $columns) { - return $this->applyLayout('paragraph.php', $paragraph); - } + $this->preRenderChildElements($columns); - /** - * Render a span element - * - * @param Span $span The text - * - * @return integer Number of bytes written to the output - */ - public function visitSpan(Span $span) - { - return $this->applyLayout('span.php', $span); + $this->applyLayout('columns.php', $columns); } /** @@ -238,7 +173,7 @@ public function visitSpan(Span $span) * * @param Compound $compound The compound * - * @return integer Number of bytes written to the output + * @return void */ public function visitCompound(Compound $compound) { @@ -251,159 +186,172 @@ public function visitCompound(Compound $compound) $class = " class=\"$class\""; } - $len = 0; - $len += $this->write("\n"); - $len += $this->write("<{$compound->getType()}{$id}{$class}>\n"); + $this->write("\n"); + $this->write("<{$compound->getType()}{$id}{$class}>\n"); foreach ($compound->elements as $item) { - $len += $item->accept($this); + $item->accept($this); } - $len += $this->write("getType()}>\n"); - $len += $this->write("\n"); - - return $len; + $this->write("getType()}>\n"); + $this->write("\n"); } /** - * Render an OnePager + * Render a defaultMenu * - * @param OnePager $page The page + * @param DefaultMenu $defaultMenu The defaultMenu * - * @return integer Number of bytes written to the output + * @return void */ - public function visitOnePager(OnePager $page) + public function visitDefaultMenu(DefaultMenu $defaultMenu) { - $this->preRenderChildElements($page); + $menu = $this->convertPageTreeToMenu($defaultMenu->item); + $defaultMenu->item = $menu; - return $this->applyLayout('onepager.php', $page); + $this->applyLayout('defaultMenu.php', $defaultMenu); } /** - * Render an OnePager section + * @param Page $page The page * - * @param OnePagerSection $section The page - * - * @return integer Number of bytes written to the output + * @return Menu */ - public function visitOnePagerSection(OnePagerSection $section) + private function convertPageTreeToMenu($page) { - $this->preRenderChildElements($section); + $menu = new Menu( + $page->title, + $this->expandUrl($page->url, $page) + ); - return $this->applyLayout('onepagerSection.php', $section); + foreach ($page->children->getAll() as $child) + { + $menu->add($this->convertPageTreeToMenu($child)); + } + + return $menu; } /** - * Render an icon + * @param string $url The URL + * @param Page $page The page * - * @param Icon $icon The icon - * - * @return integer Number of bytes written to the output + * @return string */ - public function visitIcon(Icon $icon) + private function expandUrl($url, $page) { - return $this->applyLayout('icon.php', $icon); + if (empty($url)) + { + return '/index.php'; + } + + while ($url[0] != '/' && !empty($page->parent)) + { + // @todo refactor + if ($page->parent instanceof Layout) + { + break; + } + + $page = $page->parent; + $url = $page->url . '/' . $url; + } + + if ($url[0] != '/') + { + $url = '/' . $url; + } + + return '/index.php' . $url; } /** - * Render an image + * Dump an item * - * @param Image $image The image + * @param Dump $dump The dump * - * @return integer Number of bytes written to the output + * @return void */ - public function visitImage(Image $image) + public function visitDump(Dump $dump) { - return $this->applyLayout('image.php', $image); + $this->write('
' . $this->dumpEntity($dump->item) . '
'); } /** - * Render a link + * Render a headline. * - * @param Link $link + * @param Headline $headline The headline * - * @return int Number of bytes written to the output + * @return void */ - public function visitLink(Link $link) + public function visitHeadline(Headline $headline) { - return $this->applyLayout('link.php', $link); + $this->applyLayout('headline.php', $headline); } /** - * Render an slider + * Render an image * - * @param Slider $slider The slider + * @param Image $image The image * - * @return integer Number of bytes written to the output + * @return void */ - public function visitSlider(Slider $slider) + public function visitImage(Image $image) { - $slider->setId('slider-' . spl_object_hash($slider)); - - $this->preRenderChildElements($slider); - - return $this->applyLayout('slider.php', $slider); + $this->applyLayout('image.php', $image); } /** - * Render an accordion + * Render a link * - * @param Accordion $accordion The accordion + * @param Link $link * - * @return integer Number of bytes written to the output + * @return void */ - public function visitAccordion(Accordion $accordion) + public function visitLink(Link $link) { - $accordion->setId('accordion-' . spl_object_hash($accordion)); - - $this->preRenderChildElements($accordion); - - return $this->applyLayout('accordion.php', $accordion); + $this->applyLayout('link.php', $link); } /** - * Render a tree + * Render an OnePager * - * @param Tree $tree The tree + * @param OnePager $page The page * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTree(Tree $tree) + public function visitOnePager(OnePager $page) { - $tree->setId('tree-' . spl_object_hash($tree)); - - $this->preRenderChildElements($tree); + $this->preRenderChildElements($page); - return $this->applyLayout('tree.php', $tree); + $this->applyLayout('onepager.php', $page); } /** - * Render tabs + * Render an OnePager section * - * @param Tabs $tabs The tabs + * @param OnePagerSection $section The page * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTabs(Tabs $tabs) + public function visitOnePagerSection(OnePagerSection $section) { - $tabs->setId('tabs-' . spl_object_hash($tabs)); - - $this->preRenderChildElements($tabs); + $this->preRenderChildElements($section); - return $this->applyLayout('tabs.php', $tabs); + $this->applyLayout('onepagerSection.php', $section); } /** - * Dump an item + * Render a paragraph * - * @param ContentTypeInterface $dump The dump + * @param Paragraph $paragraph The paragraph * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDump(ContentTypeInterface $dump) + public function visitParagraph(Paragraph $paragraph) { - return $this->write('
' . $this->dumpEntity($dump->item) . '
'); + $this->applyLayout('paragraph.php', $paragraph); } /** @@ -411,179 +359,216 @@ public function visitDump(ContentTypeInterface $dump) * * @param Rows $rows The rows * - * @return integer Number of bytes written to the output + * @return void */ public function visitRows(Rows $rows) { $this->preRenderChildElements($rows); - return $this->applyLayout('rows.php', $rows); + $this->applyLayout('rows.php', $rows); } /** - * Render columns + * Render an slider * - * @param Columns $columns The columns + * @param Slider $slider The slider * - * @return integer Number of bytes written to the output + * @return void */ - public function visitColumns(Columns $columns) + public function visitSlider(Slider $slider) { - $this->preRenderChildElements($columns); + $slider->setId('slider-' . spl_object_hash($slider)); + + $this->preRenderChildElements($slider); - return $this->applyLayout('columns.php', $columns); + $this->applyLayout('slider.php', $slider); } /** - * Render an article + * Render a span element * - * @param Article $article The article + * @param Span $span The text * - * @return integer Number of bytes written to the output + * @return void */ - public function visitArticle(Article $article) + public function visitSpan(Span $span) { - return $this->applyLayout('article.php', $article); + $this->applyLayout('span.php', $span); } /** - * Render a teaser + * Render tabs * - * @param Teaser $teaser The teaser + * @param Tabs $tabs The tabs * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTeaser(Teaser $teaser) + public function visitTabs(Tabs $tabs) { - $teaser->url = $this->getFullUrl($teaser->article); + $tabs->setId('tabs-' . spl_object_hash($tabs)); - return $this->applyLayout('teaser.php', $teaser); + $this->preRenderChildElements($tabs); + + $this->applyLayout('tabs.php', $tabs); } /** - * Render a defaultMenu + * Render a teaser * - * @param DefaultMenu $defaultMenu The defaultMenu + * @param Teaser $teaser The teaser * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) + public function visitTeaser(Teaser $teaser) { - $menu = $this->convertPageTreeToMenu($defaultMenu->item); - $defaultMenu->item = $menu; + $teaser->url = $this->getFullUrl($teaser->article); - return $this->applyLayout('defaultMenu.php', $defaultMenu); + $this->applyLayout('teaser.php', $teaser); } /** - * @param Page $page The page + * @param object $object The content object * - * @return Menu + * @return string */ - private function convertPageTreeToMenu($page) + private function getFullUrl($object) { - $menu = new Menu( - $page->title, - $this->expandUrl($page->url, $page) - ); + $repository = $this->container->get('Repository')->forEntity('Content'); + $entityType = explode('\\', get_class($object)); + $entityType = array_pop($entityType); + $contentItems = $repository->findAll()->with('component', Operator::EQUAL, $entityType)->getItems(); - foreach ($page->children->getAll() as $child) + $candidates = []; + + foreach ($contentItems as $item) { - $menu->add($this->convertPageTreeToMenu($child)); + if (!empty($item->selection) && !empty($item->selection->alias)) + { + $candidates[] = $this->expandUrl($object->alias, $item->page); + } } - return $menu; + if (empty($candidates)) + { + throw new NotFoundException('Unable to find a URL'); + } + + if (count($candidates) > 1) + { + // @todo Warn about ambiguosity + } + + return $candidates[0]; } /** - * @param ContentTypeInterface $content The content element + * Render a tree + * + * @param Tree $tree The tree * * @return void */ - private function preRenderChildElements(ContentTypeInterface $content) + public function visitTree(Tree $tree) { - if (!isset($content->elements)) - { - return; - } - - $stash = $this->output; + $tree->setId('tree-' . spl_object_hash($tree)); - foreach ($content->elements as $key => $item) - { - $this->output = ''; - $item->accept($this); - $item->html = $this->output; - } + $this->preRenderChildElements($tree); - $this->output = $stash; + $this->applyLayout('tree.php', $tree); } /** - * @param string $url The URL - * @param Page $page The page + * Render a horizontal line. * - * @return string + * @param HorizontalLine $headline The horizontal line + * + * @return void */ - private function expandUrl($url, $page) + public function visitHorizontalLine(HorizontalLine $headline) { - if (empty($url)) - { - return '/index.php'; - } - - while ($url[0] != '/' && !empty($page->parent)) - { - // @todo refactor - if ($page->parent instanceof Layout) - { - break; - } - - $page = $page->parent; - $url = $page->url . '/' . $url; - } + $this->write("
\n"); + } - if ($url[0] != '/') - { - $url = '/' . $url; - } + /** + * Render an icon + * + * @param Icon $icon The icon + * + * @return void + */ + public function visitIcon(Icon $icon) + { + $this->applyLayout('icon.php', $icon); + } - return '/index.php' . $url; + /** + * @param ScriptStrategyInterface $strategy The scripting strategy (library) to use + * + * @return void + */ + public function setScriptStrategy(ScriptStrategyInterface $strategy) + { + $this->clientScript = $strategy; } /** - * @param object $object The content object + * Sets the template * - * @return string + * @param string $template The template + * + * @return void */ - private function getFullUrl($object) + public function setTemplate($template) { - $repository = $this->container->get('Repository')->forEntity('Content'); - $entityType = explode('\\', get_class($object)); - $entityType = array_pop($entityType); - $contentItems = $repository->findAll()->with('component', Operator::EQUAL, $entityType)->getItems(); + $this->template = $template; + } - $candidates = []; + /** + * @param string $label An identifier + * @param string $code The code associated with that identifier + * + * @return void + */ + public function addJavascript($label, $code) + { + $this->javascript[$label] = $code; + } - foreach ($contentItems as $item) - { - if (!empty($item->selection) && !empty($item->selection->alias)) + /** + * @param string $namespace + * @param string $css + * + * @return void + */ + public function addCss($namespace, $css) + { + $this->style[] = preg_replace_callback( + '~([^{\s]*\s?\{[^{]*?\})~sm', + function ($match) use ($namespace) { - $candidates[] = $this->expandUrl($object->alias, $item->page); - } - } - - if (empty($candidates)) - { - throw new NotFoundException('Unable to find a URL'); - } + return "#{$namespace} {$match[0]}"; + }, + $css + ); + } - if (count($candidates) > 1) - { - // @todo Warn about ambiguosity - } + /** + * @return void + */ + public function writeJavascript() + { + $this->write(''); + } - return $candidates[0]; + /** + * @return void + */ + public function writeCss() + { + $this->write(''); } } diff --git a/libraries/incubator/Renderer/JsonRenderer.php b/libraries/incubator/Renderer/JsonRenderer.php index 71cdf3b83f..d8853cec0b 100644 --- a/libraries/incubator/Renderer/JsonRenderer.php +++ b/libraries/incubator/Renderer/JsonRenderer.php @@ -9,6 +9,7 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; +use Joomla\Content\ContentTypeVisitorTrait; use Joomla\Content\Type\Accordion; use Joomla\Content\Type\Article; use Joomla\Content\Type\Attribution; @@ -17,9 +18,13 @@ use Joomla\Content\Type\DefaultMenu; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -42,33 +47,41 @@ class JsonRenderer extends Renderer /** @var int The current output buffer length */ protected $len = 0; + use ContentTypeVisitorTrait; + /** - * Update the content + * Common handler for different ContentTypes. + * + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer + * @return mixed */ - private function updateContent() + public function visit($method, $content) { - $this->output = json_encode($this->data, JSON_PRETTY_PRINT); - $total = strlen($this->output); - $len = $total - $this->len; - $this->len = $total; + throw new \LogicException($method . ' is not implemented.'); + } - return $len; + /** + * Get the content from the buffer + * + * @return string + */ + public function __toString() + { + return json_encode($this->data, JSON_PRETTY_PRINT); } /** - * Render a headline. + * Render an attribution to an author * - * @param Headline $headline The headline + * @param Attribution $attribution The attribution * - * @return integer Number of bytes written to the output + * @return void */ - public function visitHeadline(Headline $headline) + public function visitAttribution(Attribution $attribution) { - $this->data[] = ['headline' => ['text' => $headline->text, 'level' => $headline->level]]; - - return $this->updateContent(); + $this->data[] = ['attribution' => ['label' => $attribution->label, 'name' => $attribution->name]]; } /** @@ -76,7 +89,7 @@ public function visitHeadline(Headline $headline) * * @param Compound $compound The compound * - * @return integer Number of bytes written to the output + * @return void */ public function visitCompound(Compound $compound) { @@ -90,22 +103,18 @@ public function visitCompound(Compound $compound) $stash[] = [$compound->type => $this->data]; $this->data = $stash; - - return $this->updateContent(); } /** - * Render an attribution to an author + * Render a headline. * - * @param Attribution $attribution The attribution + * @param Headline $headline The headline * - * @return integer Number of bytes written to the output + * @return void */ - public function visitAttribution(Attribution $attribution) + public function visitHeadline(Headline $headline) { - $this->data[] = ['attribution' => ['label' => $attribution->label, 'name' => $attribution->name]]; - - return $this->updateContent(); + $this->data[] = ['headline' => ['text' => $headline->text, 'level' => $headline->level]]; } /** @@ -113,166 +122,10 @@ public function visitAttribution(Attribution $attribution) * * @param Paragraph $paragraph The paragraph * - * @return integer Number of bytes written to the output + * @return void */ public function visitParagraph(Paragraph $paragraph) { $this->data[] = ['paragraph' => ['text' => $paragraph->text, 'variant' => $paragraph->variant]]; - - return $this->updateContent(); - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Dump an item - * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a defaultMenu - * - * @param DefaultMenu $defaultMenu The defaultMenu - * - * @return integer Number of bytes written to the output - */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; } } diff --git a/libraries/incubator/Renderer/PdfRenderer.php b/libraries/incubator/Renderer/PdfRenderer.php index 54ecc10ae2..5ef56fb4ff 100644 --- a/libraries/incubator/Renderer/PdfRenderer.php +++ b/libraries/incubator/Renderer/PdfRenderer.php @@ -9,6 +9,7 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; +use Joomla\Content\ContentTypeVisitorTrait; use Joomla\Content\Type\Accordion; use Joomla\Content\Type\Article; use Joomla\Content\Type\Attribution; @@ -17,9 +18,13 @@ use Joomla\Content\Type\DefaultMenu; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -36,213 +41,18 @@ class PdfRenderer extends Renderer /** @var string The MIME type */ protected $mediatype = 'application/pdf'; - /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a compound (block) element - * - * @param Compound $compound The compound - * - * @return integer Number of bytes written to the output - */ - public function visitCompound(Compound $compound) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an attribution to an author - * - * @param Attribution $attribution The attribution - * - * @return integer Number of bytes written to the output - */ - public function visitAttribution(Attribution $attribution) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a paragraph - * - * @param Paragraph $paragraph The paragraph - * - * @return integer Number of bytes written to the output - */ - public function visitParagraph(Paragraph $paragraph) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Dump an item - * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } + use ContentTypeVisitorTrait; /** - * Render a defaultMenu + * Common handler for different ContentTypes. * - * @param DefaultMenu $defaultMenu The defaultMenu + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer Number of bytes written to the output + * @return mixed */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) + public function visit($method, $content) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + throw new \LogicException($method . ' is not implemented.'); } } diff --git a/libraries/incubator/Renderer/PlainRenderer.php b/libraries/incubator/Renderer/PlainRenderer.php index 0cdb3301e8..d80caa0f34 100644 --- a/libraries/incubator/Renderer/PlainRenderer.php +++ b/libraries/incubator/Renderer/PlainRenderer.php @@ -9,17 +9,23 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; +use Joomla\Content\ContentTypeVisitorTrait; use Joomla\Content\Type\Accordion; use Joomla\Content\Type\Article; use Joomla\Content\Type\Attribution; use Joomla\Content\Type\Columns; use Joomla\Content\Type\Compound; use Joomla\Content\Type\DefaultMenu; +use Joomla\Content\Type\Dump; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -36,58 +42,19 @@ class PlainRenderer extends Renderer /** @var string The MIME type */ protected $mediatype = 'text/plain'; - /** - * Write data to the stream. - * - * @param ContentTypeInterface|string $content The string that is to be written. - * - * @return integer Returns the number of bytes written to the stream. - * @throws \RuntimeException on failure. - */ - public function write($content) - { - if ($content instanceof ContentTypeInterface) - { - $len = $content->accept($this); - } - else - { - echo $content; - $len = strlen($content); - } - - return $len; - } + use ContentTypeVisitorTrait; /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - return $this->write($headline->text . "\n" . str_repeat('=', strlen($headline->text)) . "\n\n"); - } - - /** - * Render a compound (block) element + * Common handler for different ContentTypes. * - * @param Compound $compound The compound + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer Number of bytes written to the output + * @return mixed */ - public function visitCompound(Compound $compound) + public function visit($method, $content) { - $len = 0; - - foreach ($compound->elements as $item) - { - $len += $item->content->accept($this); - } - - return $len; + throw new \LogicException($method . ' is not implemented.'); } /** @@ -95,103 +62,105 @@ public function visitCompound(Compound $compound) * * @param Attribution $attribution The attribution * - * @return integer Number of bytes written to the output + * @return void */ public function visitAttribution(Attribution $attribution) { - return $this->write($attribution->label . ' ' . $attribution->text . "\n\n"); + $this->write($attribution->label . ' ' . $attribution->text . "\n\n"); } /** - * Render a paragraph + * Write data to the output. * - * @param Paragraph $paragraph The paragraph + * @param ContentTypeInterface|string $content The string that is to be written. * - * @return integer Number of bytes written to the output + * @return void */ - public function visitParagraph(Paragraph $paragraph) + public function write($content) { - return $this->write($paragraph->text . "\n\n"); + if ($content instanceof ContentTypeInterface) + { + $content->accept($this); + } + else + { + echo $content; + } } /** - * Render an image + * Render columns * - * @param Image $image The image + * @param Columns $columns The columns * - * @return integer Number of bytes written to the output + * @return void */ - public function visitImage(Image $image) + public function visitColumns(Columns $columns) { - return $this->write("![{$image->alt}]({$image->url})"); + $this->visitCompound($columns); } /** - * Render an slider + * Render a compound (block) element * - * @param Slider $slider The slider + * @param Compound $compound The compound * - * @return integer Number of bytes written to the output + * @return void */ - public function visitSlider(Slider $slider) + public function visitCompound(Compound $compound) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + foreach ($compound->elements as $item) + { + $item->content->accept($this); + } } /** - * Render an accordion + * Dump an item * - * @param Accordion $accordion The accordion + * @param Dump $dump The dump * - * @return integer Number of bytes written to the output + * @return void */ - public function visitAccordion(Accordion $accordion) + public function visitDump(Dump $dump) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + $this->write(print_r($dump->item, true)); } /** - * Render a tree + * Render a headline. * - * @param Tree $tree The tree + * @param Headline $headline The headline * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTree(Tree $tree) + public function visitHeadline(Headline $headline) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + $this->write($headline->text . "\n" . str_repeat('=', strlen($headline->text)) . "\n\n"); } /** - * Render tabs + * Render an image * - * @param Tabs $tabs The tabs + * @param Image $image The image * - * @return integer Number of bytes written to the output + * @return void */ - public function visitTabs(Tabs $tabs) + public function visitImage(Image $image) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + $this->write("![{$image->alt}]({$image->url})"); } /** - * Dump an item + * Render a paragraph * - * @param ContentTypeInterface $dump The dump + * @param Paragraph $paragraph The paragraph * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDump(ContentTypeInterface $dump) + public function visitParagraph(Paragraph $paragraph) { - return $this->write(print_r($dump->item, true)); + $this->write($paragraph->text . "\n\n"); } /** @@ -199,64 +168,10 @@ public function visitDump(ContentTypeInterface $dump) * * @param Rows $rows The rows * - * @return integer Number of bytes written to the output + * @return void */ public function visitRows(Rows $rows) { - return $this->visitCompound($rows); - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - return $this->visitCompound($columns); - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a defaultMenu - * - * @param DefaultMenu $defaultMenu The defaultMenu - * - * @return integer Number of bytes written to the output - */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + $this->visitCompound($rows); } } diff --git a/libraries/incubator/Renderer/Renderer.php b/libraries/incubator/Renderer/Renderer.php index 617d3c4b2d..c5f8a9cfdd 100644 --- a/libraries/incubator/Renderer/Renderer.php +++ b/libraries/incubator/Renderer/Renderer.php @@ -36,14 +36,11 @@ abstract class Renderer implements RendererInterface /** @var callable[] Content type handlers */ private $handlers = []; - /** @var int Internal cursor */ - private $pointer = 0; - /** * Renderer constructor. * - * @param array $options Accepted range, ie., MIME type ('token') and quality ('q') - * @param ContainerInterface $container The container + * @param array $options Accepted range, ie., MIME type ('token') and quality ('q') + * @param ContainerInterface $container The container */ public function __construct(array $options, ContainerInterface $container) { @@ -53,6 +50,23 @@ public function __construct(array $options, ContainerInterface $container) $this->registerFallback(); } + /** + * Define a fallback for non-registered content types. + * The fallback will just ignore the content type. + * + * @return void + */ + private function registerFallback() + { + $this->registerContentType( + 'default', + function () + { + return ''; + } + ); + } + /** * Register a content type * @@ -65,13 +79,15 @@ public function registerContentType($type, $handler) { if (is_string($handler)) { - $handler = function (ContentTypeInterface $contentItem) use ($handler) { + $handler = function (ContentTypeInterface $contentItem) use ($handler) + { return call_user_func([$contentItem, $handler]); }; } elseif (is_array($handler)) { - $handler = function (ContentTypeInterface $contentItem) use ($handler) { + $handler = function (ContentTypeInterface $contentItem) use ($handler) + { return call_user_func($handler, $contentItem); }; } @@ -88,313 +104,68 @@ public function getClass() } /** - * @param string $method Method name; must start with 'visit' - * @param array $arguments Method arguments - * - * @return void - */ - public function __call($method, $arguments) - { - if (preg_match('~^visit(.+)~', $method, $match)) - { - $type = strtolower($match[1]); - - if (!isset($this->handlers[$type])) - { - $type = 'default'; - } - - if (isset($this->handlers[$type])) - { - $handler = $this->handlers[$type]; - $this->output .= $handler($arguments[0]); - } - else - { - throw new NotFoundException("Unknown content type {$match[1]}, no default\n"); - } - } - } - - /** - * Reads all data from the stream into a string, from the beginning to end. - * - * This method MUST attempt to seek to the beginning of the stream before - * reading data and read the stream until the end is reached. - * - * Warning: This could attempt to load a large amount of data into memory. - * - * This method MUST NOT raise an exception in order to conform with PHP's - * string casting operations. - * - * @see http://php.net/manual/en/language.oop5.magic.php#object.tostring - * - * @return string - */ - public function __toString() - { - return $this->output; - } - - /** - * Closes the stream and any underlying resources. - * - * @return void - */ - public function close() - { - $this->output = ''; - $this->pointer = 0; - } - - /** - * Separates any underlying resources from the stream. - * - * After the stream has been detached, the stream is in an unusable state. - * - * @return resource|null Underlying PHP stream, if any - */ - public function detach() - { - return null; - } - - /** - * Get the size of the stream if known. - * - * @return integer|null Returns the size in bytes if known, or null if unknown. - */ - public function getSize() - { - return strlen($this->output); - } - - /** - * Returns the current position of the file read/write pointer - * - * @return int Position of the file pointer - * @throws \RuntimeException on error. - */ - public function tell() - { - return $this->pointer; - } - - /** - * Returns true if the stream is at the end of the stream. - * - * @return boolean - */ - public function eof() - { - return $this->pointer >= strlen($this->output); - } - - /** - * Seek to the beginning of the stream. - * - * If the stream is not seekable, this method will raise an exception; - * otherwise, it will perform a seek(0). - * - * @see seek() - * @link http://www.php.net/manual/en/function.fseek.php - * - * @return void - * @throws \RuntimeException on failure. - */ - public function rewind() - { - $this->seek(0); - } - - /** - * /** - * Seek to a position in the stream. - * - * @link http://www.php.net/manual/en/function.fseek.php - * - * @param int $offset Stream offset - * @param int $whence Specifies how the cursor position will be calculated - * based on the seek offset. Valid values are identical to the built-in - * PHP $whence values for `fseek()`. - * SEEK_SET: Set position equal to offset bytes - * SEEK_CUR: Set position to current location plus offset - * SEEK_END: Set position to end-of-stream plus offset. - * - * @return void - * @throws \RuntimeException on failure. + * @return string */ - public function seek($offset, $whence = SEEK_SET) + public function getMediaType() { - if ($whence == SEEK_SET) - { - $this->pointer = $offset; - } - elseif ($whence == SEEK_CUR) - { - $this->pointer += $offset; - } - elseif ($whence == SEEK_END) - { - $this->pointer = strlen($this->output) + $offset; - } - else - { - throw new \RuntimeException('Unknown mode. Expected one of SEEK_SET, SEEK_CUR, or SEEK_END'); - } + return $this->mediatype; } /** - * Write data to the stream. + * Write data to the output. * * @param ContentTypeInterface|string $content The string that is to be written. * - * @return integer Returns the number of bytes written to the stream. - * @throws \RuntimeException on failure. + * @return void */ public function write($content) { if ($content instanceof ContentTypeInterface) { - $len = $content->accept($this); + $content->accept($this); } else { $this->output .= $content; - $len = strlen($content); } - - return $len; - } - - /** - * Returns whether or not the stream is readable. - * - * @return boolean - */ - public function isReadable() - { - return true; - } - - /** - * Read data from the stream. - * - * @param int $length Read up to $length bytes from the object and return - * them. Fewer than $length bytes may be returned if underlying stream - * call returns fewer bytes. - * - * @return string Returns the data read from the stream, or an empty string - * if no bytes are available. - * @throws \RuntimeException if an error occurs. - */ - public function read($length) - { - $currentPos = $this->pointer; - $this->seek($length, SEEK_CUR); - - return substr($this->output, $currentPos, $length); } /** - * Returns the remaining contents in a string + * Get the content from the buffer * - * @return string - * @throws \RuntimeException if unable to read or an error occurs while - * reading. + * @return string */ - public function getContents() + public function __toString() { - $currentPos = $this->pointer; - $this->seek(1, SEEK_END); - - return substr($this->output, $currentPos); + return $this->output; } /** - * Get stream metadata as an associative array or retrieve a specific key. - * - * The keys returned are identical to the keys returned from PHP's - * stream_get_meta_data() function. - * - * @link http://php.net/manual/en/function.stream-get-meta-data.php - * - * @param string $key Specific metadata to retrieve. + * @param string $method Method name; must start with 'visit' + * @param array $arguments Method arguments * - * @return array|mixed|null Returns an associative array if no key is - * provided. Returns a specific key value if a key is provided and the - * value is found, or null if the key is not found. + * @return void */ - public function getMetadata($key = null) + public function __call($method, $arguments) { - $metaData = $this->collectMetadata(); - - if (is_null($key)) - { - return $metaData; - } - - if (isset($metaData[$key])) + if (preg_match('~^visit(.+)~', $method, $match)) { - return $metaData[$key]; - } - - return null; - } - - /** - * @return array - */ - protected function collectMetadata() - { - return [ - 'wrapper_data' => [ - 'renderer' => get_class($this), - ], - 'wrapper_type' => 'RFC2397', - 'stream_type' => 'RFC2397', - 'mode' => $this->isWritable() ? 'r+' : 'r', - 'unread_bytes' => strlen($this->output) - $this->pointer, - 'seekable' => $this->isSeekable(), - 'uri' => 'data://' . $this->mediatype . ',' . urlencode($this->output), - 'mediatype' => $this->mediatype, - 'base64' => false, - ]; - } - - /** - * Returns whether or not the stream is writable. - * - * @return boolean - */ - public function isWritable() - { - return true; - } + $type = strtolower($match[1]); - /** - * Returns whether or not the stream is seekable. - * - * @return boolean - */ - public function isSeekable() - { - return true; - } + if (!isset($this->handlers[$type])) + { + $type = 'default'; + } - /** - * Define a fallback for non-registered content types. - * The fallback will just ignore the content type. - * - * @return void - */ - private function registerFallback() - { - $this->registerContentType( - 'default', - function () { - return ''; + if (isset($this->handlers[$type])) + { + $handler = $this->handlers[$type]; + $this->output .= $handler($arguments[0]); } - ); + else + { + throw new NotFoundException("Unknown content type {$match[1]}, no default\n"); + } + } } } diff --git a/libraries/incubator/Renderer/RendererInterface.php b/libraries/incubator/Renderer/RendererInterface.php index ff3d0c11fd..cd17e09321 100644 --- a/libraries/incubator/Renderer/RendererInterface.php +++ b/libraries/incubator/Renderer/RendererInterface.php @@ -8,8 +8,8 @@ namespace Joomla\Renderer; +use Joomla\Content\ContentTypeInterface; use Joomla\Content\ContentTypeVisitorInterface; -use Psr\Http\Message\StreamInterface; /** * Renderer Interface @@ -18,9 +18,11 @@ * * @since __DEPLOY_VERSION__ */ -interface RendererInterface extends ContentTypeVisitorInterface, StreamInterface +interface RendererInterface extends ContentTypeVisitorInterface { /** + * Register a handler for a content type. + * * @param string $type The content type * @param callable|array|string $handler The handler for that type * @@ -29,7 +31,32 @@ interface RendererInterface extends ContentTypeVisitorInterface, StreamInterface public function registerContentType($type, $handler); /** + * Get the (inner) class of this renderer. + * * @return string */ public function getClass(); + + /** + * Get the media (MIME) type for this renderer. + * + * @return string + */ + public function getMediaType(); + + /** + * Write data to the output. + * + * @param ContentTypeInterface|string $content The string that is to be written. + * + * @return void + */ + public function write($content); + + /** + * Get the content from the buffer + * + * @return string + */ + public function __toString(); } diff --git a/libraries/incubator/Renderer/XmlRenderer.php b/libraries/incubator/Renderer/XmlRenderer.php index 890d96e249..1bc1b0caa3 100644 --- a/libraries/incubator/Renderer/XmlRenderer.php +++ b/libraries/incubator/Renderer/XmlRenderer.php @@ -9,6 +9,7 @@ namespace Joomla\Renderer; use Joomla\Content\ContentTypeInterface; +use Joomla\Content\ContentTypeVisitorTrait; use Joomla\Content\Type\Accordion; use Joomla\Content\Type\Article; use Joomla\Content\Type\Attribution; @@ -17,9 +18,13 @@ use Joomla\Content\Type\DefaultMenu; use Joomla\Content\Type\Headline; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Paragraph; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -36,213 +41,18 @@ class XmlRenderer extends Renderer /** @var string The MIME type */ protected $mediatype = 'application/xml'; - /** - * Render a headline. - * - * @param Headline $headline The headline - * - * @return integer Number of bytes written to the output - */ - public function visitHeadline(Headline $headline) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a compound (block) element - * - * @param Compound $compound The compound - * - * @return integer Number of bytes written to the output - */ - public function visitCompound(Compound $compound) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an attribution to an author - * - * @param Attribution $attribution The attribution - * - * @return integer Number of bytes written to the output - */ - public function visitAttribution(Attribution $attribution) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a paragraph - * - * @param Paragraph $paragraph The paragraph - * - * @return integer Number of bytes written to the output - */ - public function visitParagraph(Paragraph $paragraph) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an image - * - * @param Image $image The image - * - * @return integer Number of bytes written to the output - */ - public function visitImage(Image $image) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an slider - * - * @param Slider $slider The slider - * - * @return integer Number of bytes written to the output - */ - public function visitSlider(Slider $slider) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an accordion - * - * @param Accordion $accordion The accordion - * - * @return integer Number of bytes written to the output - */ - public function visitAccordion(Accordion $accordion) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a tree - * - * @param Tree $tree The tree - * - * @return integer Number of bytes written to the output - */ - public function visitTree(Tree $tree) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render tabs - * - * @param Tabs $tabs The tabs - * - * @return integer Number of bytes written to the output - */ - public function visitTabs(Tabs $tabs) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Dump an item - * - * @param ContentTypeInterface $dump The dump - * - * @return integer Number of bytes written to the output - */ - public function visitDump(ContentTypeInterface $dump) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render rows - * - * @param Rows $rows The rows - * - * @return integer Number of bytes written to the output - */ - public function visitRows(Rows $rows) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render columns - * - * @param Columns $columns The columns - * - * @return integer Number of bytes written to the output - */ - public function visitColumns(Columns $columns) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render an article - * - * @param Article $article The article - * - * @return integer Number of bytes written to the output - */ - public function visitArticle(Article $article) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } - - /** - * Render a teaser - * - * @param Teaser $teaser The teaser - * - * @return integer Number of bytes written to the output - */ - public function visitTeaser(Teaser $teaser) - { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; - } + use ContentTypeVisitorTrait; /** - * Render a defaultMenu + * Common handler for different ContentTypes. * - * @param DefaultMenu $defaultMenu The defaultMenu + * @param string $method The name of the originally called method + * @param ContentTypeInterface $content The content * - * @return integer Number of bytes written to the output + * @return mixed */ - public function visitDefaultMenu(DefaultMenu $defaultMenu) + public function visit($method, $content) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); - - return 0; + throw new \LogicException($method . ' is not implemented.'); } } diff --git a/tests/unit/Http/RendererCest.php b/tests/unit/Http/RendererCest.php index 6c579cbe78..e8ff8fe6eb 100644 --- a/tests/unit/Http/RendererCest.php +++ b/tests/unit/Http/RendererCest.php @@ -41,11 +41,11 @@ public function RendererAddsTheEventDecorator(UnitTester $I) $app = new Application([ new RendererMiddleware(new Dispatcher(), $container), - function (ServerRequestInterface $request, ResponseInterface $response, callable $next) use ($I) + function (ServerRequestInterface $request, ResponseInterface $response, callable $next) use ($I, $container) { - $body = $response->getBody(); + $renderer = $container->get('Renderer'); - $I->assertEquals(EventDecorator::class, get_class($body)); + $I->assertEquals(EventDecorator::class, get_class($renderer)); return $next($request, $response); } diff --git a/tests/unit/Renderer/DynamicRendererCest.php b/tests/unit/Renderer/DynamicRendererCest.php index eb5694f260..414ca7b6cd 100644 --- a/tests/unit/Renderer/DynamicRendererCest.php +++ b/tests/unit/Renderer/DynamicRendererCest.php @@ -51,12 +51,12 @@ public function DynamicRendererUsesCallbacks(UnitTester $I) }); /** @var ContentTypeInterface[] $content */ - $content = array( + $content = [ new ContentType('ContentType'), new NewContentType('NewContentType'), new OtherContentType('OtherContentType'), new UnregisteredContentType('UnregisteredContentType'), - ); + ]; foreach ($content as $c) { @@ -68,7 +68,7 @@ public function DynamicRendererUsesCallbacks(UnitTester $I) "static: NewContentType\n" . "dynamic: OtherContentType\n" . "default: UnregisteredContentType\n", - $renderer->getContents() + (string) $renderer ); } diff --git a/tests/unit/Renderer/EventDecoratorCest.php b/tests/unit/Renderer/EventDecoratorCest.php index 97d7ce5101..a0589ffa78 100644 --- a/tests/unit/Renderer/EventDecoratorCest.php +++ b/tests/unit/Renderer/EventDecoratorCest.php @@ -42,21 +42,8 @@ function () }, null ], - 'close' => [null], - 'detach' => [null], - 'rewind' => [null], - 'seek' => [0, null], - 'getMetadata' => [null], '__toString' => ['content'], - 'read' => [8192, 'content'], - 'getContents' => ['content'], - 'getSize' => [6], - 'tell' => [0], - 'write' => ['content', 6], - 'eof' => [false], - 'isReadable' => [true], - 'isWritable' => [true], - 'isSeekable' => [true], + 'write' => ['content', null], ]; foreach ($mockMethods as $method => $arguments) diff --git a/tests/unit/Renderer/Mock/Renderer.php b/tests/unit/Renderer/Mock/Renderer.php index bfa678fcbc..a42b0147a9 100644 --- a/tests/unit/Renderer/Mock/Renderer.php +++ b/tests/unit/Renderer/Mock/Renderer.php @@ -9,8 +9,12 @@ use Joomla\Content\Type\DefaultMenu; use Joomla\Content\Type\Dump; use Joomla\Content\Type\Image; +use Joomla\Content\Type\Link; +use Joomla\Content\Type\OnePager; +use Joomla\Content\Type\OnePagerSection; use Joomla\Content\Type\Rows; use Joomla\Content\Type\Slider; +use Joomla\Content\Type\Span; use Joomla\Content\Type\Tabs; use Joomla\Content\Type\Teaser; use Joomla\Content\Type\Tree; @@ -30,11 +34,10 @@ public function visitContent(ContentType $content) * * @param \Joomla\Content\Type\Headline $headline The headline * - * @return integer Number of bytes written to the output + * @return void */ public function visitHeadline(\Joomla\Content\Type\Headline $headline) { - return 0; } /** @@ -42,11 +45,10 @@ public function visitHeadline(\Joomla\Content\Type\Headline $headline) * * @param \Joomla\Content\Type\Compound $compound The compound * - * @return integer Number of bytes written to the output + * @return void */ public function visitCompound(\Joomla\Content\Type\Compound $compound) { - return 0; } /** @@ -54,11 +56,10 @@ public function visitCompound(\Joomla\Content\Type\Compound $compound) * * @param \Joomla\Content\Type\Attribution $attribution The attribution * - * @return integer Number of bytes written to the output + * @return void */ public function visitAttribution(\Joomla\Content\Type\Attribution $attribution) { - return 0; } /** @@ -66,11 +67,10 @@ public function visitAttribution(\Joomla\Content\Type\Attribution $attribution) * * @param \Joomla\Content\Type\Paragraph $paragraph The paragraph * - * @return integer Number of bytes written to the output + * @return void */ public function visitParagraph(\Joomla\Content\Type\Paragraph $paragraph) { - return 0; } /** @@ -78,11 +78,10 @@ public function visitParagraph(\Joomla\Content\Type\Paragraph $paragraph) * * @param Image $image The image * - * @return integer Number of bytes written to the output + * @return void */ public function visitImage(Image $image) { - return 0; } /** @@ -90,11 +89,10 @@ public function visitImage(Image $image) * * @param Slider $slider The slider * - * @return integer Number of bytes written to the output + * @return void */ public function visitSlider(Slider $slider) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -102,11 +100,10 @@ public function visitSlider(Slider $slider) * * @param Accordion $accordion The accordion * - * @return integer Number of bytes written to the output + * @return void */ public function visitAccordion(Accordion $accordion) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -114,11 +111,10 @@ public function visitAccordion(Accordion $accordion) * * @param Tree $tree The tree * - * @return integer Number of bytes written to the output + * @return void */ public function visitTree(Tree $tree) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -126,11 +122,10 @@ public function visitTree(Tree $tree) * * @param Tabs $tabs The tabs * - * @return integer Number of bytes written to the output + * @return void */ public function visitTabs(Tabs $tabs) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -138,11 +133,10 @@ public function visitTabs(Tabs $tabs) * * @param Dump $dump The dump * - * @return integer Number of bytes written to the output + * @return void */ - public function visitDump(ContentTypeInterface $dump) + public function visitDump(Dump $dump) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -150,11 +144,10 @@ public function visitDump(ContentTypeInterface $dump) * * @param Rows $rows The rows * - * @return integer Number of bytes written to the output + * @return void */ public function visitRows(Rows $rows) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -162,11 +155,10 @@ public function visitRows(Rows $rows) * * @param Columns $columns The columns * - * @return integer Number of bytes written to the output + * @return void */ public function visitColumns(Columns $columns) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -174,11 +166,10 @@ public function visitColumns(Columns $columns) * * @param Article $article The article * - * @return integer Number of bytes written to the output + * @return void */ public function visitArticle(Article $article) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -186,11 +177,10 @@ public function visitArticle(Article $article) * * @param Teaser $teaser The teaser * - * @return integer Number of bytes written to the output + * @return void */ public function visitTeaser(Teaser $teaser) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); } /** @@ -198,10 +188,53 @@ public function visitTeaser(Teaser $teaser) * * @param DefaultMenu $defaultMenu The defaultMenu * - * @return integer Number of bytes written to the output + * @return void */ public function visitDefaultMenu(DefaultMenu $defaultMenu) { - throw new \LogicException(__METHOD__ . ' is not implemented.'); + } + + /** + * Render a link + * + * @param Link $link The link + * + * @return void + */ + public function visitLink(Link $link) + { + } + + /** + * Render a one-pager + * + * @param OnePager $onePager The one-pager + * + * @return void + */ + public function visitOnePager(OnePager $onePager) + { + } + + /** + * Render a one-pager section + * + * @param OnePagerSection $onePagerSection The one-pager section + * + * @return void + */ + public function visitOnePagerSection(OnePagerSection $onePagerSection) + { + } + + /** + * Render an span + * + * @param Span $span The span + * + * @return void + */ + public function visitSpan(Span $span) + { } } diff --git a/tests/unit/Renderer/RendererStreamCest.php b/tests/unit/Renderer/RendererStreamCest.php deleted file mode 100644 index f4bc985eb5..0000000000 --- a/tests/unit/Renderer/RendererStreamCest.php +++ /dev/null @@ -1,294 +0,0 @@ - '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $I->assertEquals("standard: This is the content.\n", (string) $renderer); - } - - /** - * @testdox close() resets the buffer - */ - public function Close(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - $renderer->close(); - - $I->assertEquals('', (string) $renderer); - $I->assertEquals(0, $renderer->tell()); - } - - /** - * @testdox detach() always returns null - */ - public function Detach(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - - $I->assertEquals(null, $renderer->detach()); - } - - /** - * @testdox getSize() returns the length of the buffer - */ - public function getSize(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $I->assertEquals(strlen("standard: This is the content.\n"), $renderer->getSize()); - } - - /** - * @testdox Stream is seekable by default - */ - public function IsSeekable(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - - $I->assertTrue($renderer->isSeekable(), 'Expected isSeekable() to be true'); - } - - /** - * @testdox Stream is readable by default - */ - public function IsReadable(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - - $I->assertTrue($renderer->isReadable(), 'Expected isReadable() to be true'); - } - - /** - * @testdox Stream is writable by default - */ - public function IsWritable(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - - $I->assertTrue($renderer->isWritable(), 'Expected isWritable() to be true'); - } - - /** - * @testdox Stream pointer is reset on rewind() - */ - public function StreamPointerIsReset(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->rewind(); - $I->assertEquals(0, $renderer->tell()); - } - - /** - * @testdox Stream pointer is forwarded on read - */ - public function StreamPointerForwarding(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->rewind(); - $I->assertEquals('sta', $renderer->read(3)); - $I->assertEquals(3, $renderer->tell()); - } - - /** - * @testdox Stream pointer can be set relatively - */ - public function StreamPointerCanBeSetRelatively(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $I->assertEquals('sta', $renderer->read(3)); - $renderer->seek(2, SEEK_CUR); - $I->assertEquals(5, $renderer->tell()); - $I->assertEquals('ard', $renderer->read(3)); - } - - /** - * @testdox Stream pointer can be set absolutely - */ - public function StreamPointerCanBeSetAbsolutely(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->seek(2, SEEK_SET); - $I->assertEquals('and', $renderer->read(3)); - $I->assertEquals(5, $renderer->tell()); - } - - /** - * @testdox Stream pointer can be set relative to the stream's end - */ - public function StreamPointerCanBeSetRelativeToTheStreamsEnd(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->seek(-3, SEEK_END); - $I->assertEquals(28, $renderer->tell()); - $I->assertEquals("t.\n", $renderer->read(3)); - } - - /** - * @testdox EOF is set, when the end of the stream is reached - */ - public function EofIsSetWhenTheEndOfTheStreamIsReached(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->seek(0, SEEK_END); - - $I->assertTrue($renderer->eof()); - } - - /** - * @testdox Exception is thrown on illegal whence value - */ - public function ExceptionIsThrownOnIllegalWhenceValue(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - try - { - $renderer->seek(0, 5); - $I->fail('Expected RuntimeException was not thrown'); - } - catch (\Exception $e) - { - $I->assertTrue($e instanceof \RuntimeException); - } - } - - /** - * @testdox write() appends string to the output - */ - public function WriteAppendsToTheOutput(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - - $content->accept($renderer); - - $renderer->write("More of this."); - - $I->assertEquals("standard: This is the content.\nMore of this.", (string) $renderer); - } - - /** - * @testdox write() accepts content type elements - */ - public function WriteAcceptsContentTypeElements(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $content = new ContentType('This is the content.'); - $more = new ContentType('More of this.'); - - $content->accept($renderer); - - $renderer->write($more); - - $I->assertEquals("standard: This is the content.\nstandard: More of this.\n", (string) $renderer); - } - - /** - * @testdox The meta data has the defined structure - */ - public function Metadata(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $meta = $renderer->getMetadata(); - - $I->assertEquals([ - 'wrapper_data', - 'wrapper_type', - 'stream_type', - 'mode', - 'unread_bytes', - 'seekable', - 'uri', - 'mediatype', - 'base64' - ], - array_keys($meta) - ); - } - - /** - * @testdox Stream type is RFC2397 - */ - public function MetadataStreamType(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $meta = $renderer->getMetadata('stream_type'); - - $I->assertEquals('RFC2397', $meta); - } - - /** - * @testdox Unknown meta data is set to null - */ - public function MetadataUnknown(UnitTester $I) - { - $renderer = new Renderer(['token' => '*/*'], new Container()); - $meta = $renderer->getMetadata('foo'); - - $I->assertEquals(null, $meta); - } -}