diff --git a/.gitignore b/.gitignore index a911c60..4d5a643 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,7 @@ .idea/ composer.json.bak +composer.lock vendor/ config/* -web/* \ No newline at end of file +web/* +tests/var/* \ No newline at end of file diff --git a/composer.json b/composer.json index 6d6ed9d..48aa270 100644 --- a/composer.json +++ b/composer.json @@ -15,12 +15,20 @@ } ], "autoload": { + "files": [ + "src/Framework/helpers.php" + ], "psr-4": { "TastPHP\\": [ "src/" ] } }, + "autoload-dev": { + "psr-4": { + "TastPHP\\Tests\\": "tests/src" + } + }, "require": { "doctrine/dbal": "2.5.4", "pimple/pimple": "~3.0", diff --git a/composer.lock b/composer.lock deleted file mode 100644 index d833429..0000000 --- a/composer.lock +++ /dev/null @@ -1,3363 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", - "This file is @generated automatically" - ], - "content-hash": "a7a704342ef25e2861bc5cf4af7c3126", - "packages": [ - { - "name": "doctrine/annotations", - "version": "v1.3.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "bd4461328621bde0ae6b1b2675fbc6aca4ceb558" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/bd4461328621bde0ae6b1b2675fbc6aca4ceb558", - "reference": "bd4461328621bde0ae6b1b2675fbc6aca4ceb558", - "shasum": "" - }, - "require": { - "doctrine/lexer": "1.*", - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "^5.6.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "docblock", - "parser" - ], - "time": "2016-12-30T15:59:45+00:00" - }, - { - "name": "doctrine/cache", - "version": "v1.6.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "b6f544a20f4807e81f7044d31e679ccbb1866dc3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/b6f544a20f4807e81f7044d31e679ccbb1866dc3", - "reference": "b6f544a20f4807e81f7044d31e679ccbb1866dc3", - "shasum": "" - }, - "require": { - "php": "~5.5|~7.0" - }, - "conflict": { - "doctrine/common": ">2.2,<2.4" - }, - "require-dev": { - "phpunit/phpunit": "~4.8|~5.0", - "predis/predis": "~1.0", - "satooshi/php-coveralls": "~0.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Caching library offering an object-oriented API for many cache backends", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "cache", - "caching" - ], - "time": "2016-10-29T11:16:17+00:00" - }, - { - "name": "doctrine/collections", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/6c1e4eef75f310ea1b3e30945e9f06e652128b8a", - "reference": "6c1e4eef75f310ea1b3e30945e9f06e652128b8a", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Collections\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Collections Abstraction library", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "array", - "collections", - "iterator" - ], - "time": "2015-04-14T22:21:58+00:00" - }, - { - "name": "doctrine/common", - "version": "v2.6.2", - "source": { - "type": "git", - "url": "https://github.com/doctrine/common.git", - "reference": "7bce00698899aa2c06fe7365c76e4d78ddb15fa3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/7bce00698899aa2c06fe7365c76e4d78ddb15fa3", - "reference": "7bce00698899aa2c06fe7365c76e4d78ddb15fa3", - "shasum": "" - }, - "require": { - "doctrine/annotations": "1.*", - "doctrine/cache": "1.*", - "doctrine/collections": "1.*", - "doctrine/inflector": "1.*", - "doctrine/lexer": "1.*", - "php": "~5.5|~7.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.8|~5.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Common Library for Doctrine projects", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "collections", - "eventmanager", - "persistence", - "spl" - ], - "time": "2016-11-30T16:50:46+00:00" - }, - { - "name": "doctrine/dbal", - "version": "v2.5.4", - "source": { - "type": "git", - "url": "https://github.com/doctrine/dbal.git", - "reference": "abbdfd1cff43a7b99d027af3be709bc8fc7d4769" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/abbdfd1cff43a7b99d027af3be709bc8fc7d4769", - "reference": "abbdfd1cff43a7b99d027af3be709bc8fc7d4769", - "shasum": "" - }, - "require": { - "doctrine/common": ">=2.4,<2.7-dev", - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "4.*", - "symfony/console": "2.*" - }, - "suggest": { - "symfony/console": "For helpful console commands such as SQL execution and import of files." - }, - "bin": [ - "bin/doctrine-dbal" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.5.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\DBAL\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - } - ], - "description": "Database Abstraction Layer", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "database", - "dbal", - "persistence", - "queryobject" - ], - "time": "2016-01-05T22:11:12+00:00" - }, - { - "name": "doctrine/inflector", - "version": "v1.1.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/inflector.git", - "reference": "90b2128806bfde671b6952ab8bea493942c1fdae" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/inflector/zipball/90b2128806bfde671b6952ab8bea493942c1fdae", - "reference": "90b2128806bfde671b6952ab8bea493942c1fdae", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "4.*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Inflector\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Common String Manipulations with regard to casing and singular/plural rules.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "inflection", - "pluralize", - "singularize", - "string" - ], - "time": "2015-11-06T14:35:42+00:00" - }, - { - "name": "doctrine/lexer", - "version": "v1.0.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/83893c552fd2045dd78aef794c31e694c37c0b8c", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "Doctrine\\Common\\Lexer\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "lexer", - "parser" - ], - "time": "2014-09-09T13:34:57+00:00" - }, - { - "name": "doctrine/migrations", - "version": "v1.5.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/migrations.git", - "reference": "c81147c0f2938a6566594455367e095150547f72" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/migrations/zipball/c81147c0f2938a6566594455367e095150547f72", - "reference": "c81147c0f2938a6566594455367e095150547f72", - "shasum": "" - }, - "require": { - "doctrine/dbal": "~2.2", - "ocramius/proxy-manager": "^1.0|^2.0", - "php": "^5.5|^7.0", - "symfony/console": "~2.3|~3.0", - "symfony/yaml": "~2.3|~3.0" - }, - "require-dev": { - "doctrine/coding-standard": "dev-master", - "doctrine/orm": "2.*", - "jdorn/sql-formatter": "~1.1", - "johnkary/phpunit-speedtrap": "~1.0@dev", - "mikey179/vfsstream": "^1.6", - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "~4.7", - "satooshi/php-coveralls": "^1.0" - }, - "suggest": { - "jdorn/sql-formatter": "Allows to generate formatted SQL with the diff command." - }, - "bin": [ - "bin/doctrine-migrations" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "v1.6.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\DBAL\\Migrations\\": "lib/Doctrine/DBAL/Migrations" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-2.1" - ], - "authors": [ - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Michael Simonson", - "email": "contact@mikesimonson.com" - } - ], - "description": "Database Schema migrations using Doctrine DBAL", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "database", - "migrations" - ], - "time": "2016-12-25T22:54:00+00:00" - }, - { - "name": "jeremykendall/php-domain-parser", - "version": "2.0.3", - "source": { - "type": "git", - "url": "https://github.com/jeremykendall/php-domain-parser.git", - "reference": "29c8dfd8fc55bb90c98fb531eab6c138093e7bbe" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/jeremykendall/php-domain-parser/zipball/29c8dfd8fc55bb90c98fb531eab6c138093e7bbe", - "reference": "29c8dfd8fc55bb90c98fb531eab6c138093e7bbe", - "shasum": "" - }, - "require": { - "ext-curl": "*", - "ext-intl": "*", - "ext-mbstring": "*", - "php": ">=5.3.0" - }, - "require-dev": { - "mikey179/vfsstream": "~1.4", - "phpunit/phpunit": "~4.4" - }, - "bin": [ - "bin/parse", - "bin/pdp-psl" - ], - "type": "library", - "autoload": { - "psr-0": { - "Pdp\\": "src/" - }, - "files": [ - "src/pdp-parse-url.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jeremy Kendall", - "homepage": "http://about.me/jeremykendall", - "role": "Developer" - }, - { - "name": "Contributors", - "homepage": "https://github.com/jeremykendall/php-domain-parser/graphs/contributors" - } - ], - "description": "Public Suffix List based URL parsing implemented in PHP.", - "homepage": "https://github.com/jeremykendall/php-domain-parser", - "keywords": [ - "Public Suffix List", - "domain parsing", - "url parsing" - ], - "time": "2015-02-16T12:45:33+00:00" - }, - { - "name": "lcobucci/jwt", - "version": "3.2.1", - "source": { - "type": "git", - "url": "https://github.com/lcobucci/jwt.git", - "reference": "ddce703826f9c5229781933b1a39069e38e6a0f3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/lcobucci/jwt/zipball/ddce703826f9c5229781933b1a39069e38e6a0f3", - "reference": "ddce703826f9c5229781933b1a39069e38e6a0f3", - "shasum": "" - }, - "require": { - "ext-openssl": "*", - "php": ">=5.5" - }, - "require-dev": { - "mdanter/ecc": "~0.3.1", - "mikey179/vfsstream": "~1.5", - "phpmd/phpmd": "~2.2", - "phpunit/php-invoker": "~1.1", - "phpunit/phpunit": "~4.5", - "squizlabs/php_codesniffer": "~2.3" - }, - "suggest": { - "mdanter/ecc": "Required to use Elliptic Curves based algorithms." - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev" - } - }, - "autoload": { - "psr-4": { - "Lcobucci\\JWT\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Luís Otávio Cobucci Oblonczyk", - "email": "lcobucci@gmail.com", - "role": "Developer" - } - ], - "description": "A simple library to work with JSON Web Token and JSON Web Signature", - "keywords": [ - "JWS", - "jwt" - ], - "time": "2016-10-31T20:09:32+00:00" - }, - { - "name": "maximebf/debugbar", - "version": "1.13.1", - "source": { - "type": "git", - "url": "https://github.com/maximebf/php-debugbar.git", - "reference": "afee79a236348e39a44cb837106b7c5b4897ac2a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/maximebf/php-debugbar/zipball/afee79a236348e39a44cb837106b7c5b4897ac2a", - "reference": "afee79a236348e39a44cb837106b7c5b4897ac2a", - "shasum": "" - }, - "require": { - "php": ">=5.3.0", - "psr/log": "^1.0", - "symfony/var-dumper": "^2.6|^3.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.0|^5.0" - }, - "suggest": { - "kriswallsmith/assetic": "The best way to manage assets", - "monolog/monolog": "Log using Monolog", - "predis/predis": "Redis storage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.13-dev" - } - }, - "autoload": { - "psr-4": { - "DebugBar\\": "src/DebugBar/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Maxime Bouroumeau-Fuseau", - "email": "maxime.bouroumeau@gmail.com", - "homepage": "http://maximebf.com" - }, - { - "name": "Barry vd. Heuvel", - "email": "barryvdh@gmail.com" - } - ], - "description": "Debug bar in the browser for php application", - "homepage": "https://github.com/maximebf/php-debugbar", - "keywords": [ - "debug", - "debugbar" - ], - "time": "2017-01-05T08:46:19+00:00" - }, - { - "name": "monolog/monolog", - "version": "1.22.0", - "source": { - "type": "git", - "url": "https://github.com/Seldaek/monolog.git", - "reference": "bad29cb8d18ab0315e6c477751418a82c850d558" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bad29cb8d18ab0315e6c477751418a82c850d558", - "reference": "bad29cb8d18ab0315e6c477751418a82c850d558", - "shasum": "" - }, - "require": { - "php": ">=5.3.0", - "psr/log": "~1.0" - }, - "provide": { - "psr/log-implementation": "1.0.0" - }, - "require-dev": { - "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", - "php-amqplib/php-amqplib": "~2.4", - "php-console/php-console": "^3.1.3", - "phpunit/phpunit": "~4.5", - "phpunit/phpunit-mock-objects": "2.3.0", - "ruflin/elastica": ">=0.90 <3.0", - "sentry/sentry": "^0.13", - "swiftmailer/swiftmailer": "~5.3" - }, - "suggest": { - "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", - "doctrine/couchdb": "Allow sending log messages to a CouchDB server", - "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", - "ext-mongo": "Allow sending log messages to a MongoDB server", - "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", - "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", - "rollbar/rollbar": "Allow sending log messages to Rollbar", - "ruflin/elastica": "Allow sending log messages to an Elastic Search server", - "sentry/sentry": "Allow sending log messages to a Sentry server" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Monolog\\": "src/Monolog" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "Sends your logs to files, sockets, inboxes, databases and various web services", - "homepage": "http://github.com/Seldaek/monolog", - "keywords": [ - "log", - "logging", - "psr-3" - ], - "time": "2016-11-26T00:15:39+00:00" - }, - { - "name": "mtdowling/cron-expression", - "version": "v1.1.0", - "source": { - "type": "git", - "url": "https://github.com/mtdowling/cron-expression.git", - "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/mtdowling/cron-expression/zipball/c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", - "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.0|~5.0" - }, - "type": "library", - "autoload": { - "psr-0": { - "Cron": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - } - ], - "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", - "keywords": [ - "cron", - "schedule" - ], - "time": "2016-01-26T21:23:30+00:00" - }, - { - "name": "ocramius/proxy-manager", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/Ocramius/ProxyManager.git", - "reference": "57e9272ec0e8deccf09421596e0e2252df440e11" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Ocramius/ProxyManager/zipball/57e9272ec0e8deccf09421596e0e2252df440e11", - "reference": "57e9272ec0e8deccf09421596e0e2252df440e11", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "zendframework/zend-code": ">2.2.5,<3.0" - }, - "require-dev": { - "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "1.5.*" - }, - "suggest": { - "ocramius/generated-hydrator": "To have very fast object to array to object conversion for ghost objects", - "zendframework/zend-json": "To have the JsonRpc adapter (Remote Object feature)", - "zendframework/zend-soap": "To have the Soap adapter (Remote Object feature)", - "zendframework/zend-stdlib": "To use the hydrator proxy", - "zendframework/zend-xmlrpc": "To have the XmlRpc adapter (Remote Object feature)" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "ProxyManager\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" - } - ], - "description": "A library providing utilities to generate, instantiate and generally operate with Object Proxies", - "homepage": "https://github.com/Ocramius/ProxyManager", - "keywords": [ - "aop", - "lazy loading", - "proxy", - "proxy pattern", - "service proxies" - ], - "time": "2015-08-09T04:28:19+00:00" - }, - { - "name": "pda/pheanstalk", - "version": "v3.1.0", - "source": { - "type": "git", - "url": "https://github.com/pda/pheanstalk.git", - "reference": "430e77c551479aad0c6ada0450ee844cf656a18b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/pda/pheanstalk/zipball/430e77c551479aad0c6ada0450ee844cf656a18b", - "reference": "430e77c551479aad0c6ada0450ee844cf656a18b", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "psr-4": { - "Pheanstalk\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Paul Annesley", - "email": "paul@annesley.cc", - "homepage": "http://paul.annesley.cc/", - "role": "Developer" - } - ], - "description": "PHP client for beanstalkd queue", - "homepage": "https://github.com/pda/pheanstalk", - "keywords": [ - "beanstalkd" - ], - "time": "2015-08-07T21:42:41+00:00" - }, - { - "name": "pimple/pimple", - "version": "v3.0.2", - "source": { - "type": "git", - "url": "https://github.com/silexphp/Pimple.git", - "reference": "a30f7d6e57565a2e1a316e1baf2a483f788b258a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/silexphp/Pimple/zipball/a30f7d6e57565a2e1a316e1baf2a483f788b258a", - "reference": "a30f7d6e57565a2e1a316e1baf2a483f788b258a", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "Pimple": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Pimple, a simple Dependency Injection Container", - "homepage": "http://pimple.sensiolabs.org", - "keywords": [ - "container", - "dependency injection" - ], - "time": "2015-09-11T15:10:35+00:00" - }, - { - "name": "psr/log", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d" - }, - "dist": { - "type": "zip", - "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-4": { - "Psr\\Log\\": "Psr/Log/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", - "keywords": [ - "log", - "psr", - "psr-3" - ], - "time": "2016-10-10T12:19:37+00:00" - }, - { - "name": "schnittstabil/csrf-tokenservice", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/schnittstabil/csrf-tokenservice.git", - "reference": "e23d09cb235589fda3b42b36aaa21aa19bd833ec" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/schnittstabil/csrf-tokenservice/zipball/e23d09cb235589fda3b42b36aaa21aa19bd833ec", - "reference": "e23d09cb235589fda3b42b36aaa21aa19bd833ec", - "shasum": "" - }, - "require": { - "php": ">=5.6.0", - "spomky-labs/base64url": "^1.0" - }, - "require-dev": { - "codeclimate/php-test-reporter": "^0.3.0", - "fabpot/php-cs-fixer": "^1.10", - "halleck45/phpmetrics": "^1.8", - "phpmd/phpmd": "^2.3", - "satooshi/php-coveralls": "^1.0.1", - "schnittstabil/sugared-phpunit": "^0.2.0", - "squizlabs/php_codesniffer": "^2.5", - "vladahejda/phpunit-assert-exception": "^1.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Schnittstabil\\Csrf\\TokenService\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Mayer", - "email": "michael@schnittstabil.de" - } - ], - "description": "Stateless CSRF (Cross-Site Request Forgery) token service.", - "homepage": "https://github.com/schnittstabil/csrf-tokenservice", - "keywords": [ - "URL-safe", - "cross-site request forgery", - "csrf", - "generator", - "hmac", - "service", - "session riding", - "stateless", - "token", - "validator", - "xsrf" - ], - "time": "2016-04-08T16:15:05+00:00" - }, - { - "name": "spomky-labs/base64url", - "version": "v1.0.2", - "source": { - "type": "git", - "url": "https://github.com/Spomky-Labs/base64url.git", - "reference": "ef6d5fb93894063d9cee996022259fd08d6646ea" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Spomky-Labs/base64url/zipball/ef6d5fb93894063d9cee996022259fd08d6646ea", - "reference": "ef6d5fb93894063d9cee996022259fd08d6646ea", - "shasum": "" - }, - "require": { - "php": "^5.3|^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.0|^5.0", - "satooshi/php-coveralls": "^1.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Base64Url\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Florent Morselli", - "homepage": "https://github.com/Spomky-Labs/base64url/contributors" - } - ], - "description": "Base 64 URL Safe Encoding/decoding PHP Library", - "homepage": "https://github.com/Spomky-Labs/base64url", - "keywords": [ - "base64", - "rfc4648", - "safe", - "url" - ], - "time": "2016-01-21T19:50:30+00:00" - }, - { - "name": "swiftmailer/swiftmailer", - "version": "v5.4.5", - "source": { - "type": "git", - "url": "https://github.com/swiftmailer/swiftmailer.git", - "reference": "cd142238a339459b10da3d8234220963f392540c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/cd142238a339459b10da3d8234220963f392540c", - "reference": "cd142238a339459b10da3d8234220963f392540c", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "mockery/mockery": "~0.9.1", - "symfony/phpunit-bridge": "~3.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.4-dev" - } - }, - "autoload": { - "files": [ - "lib/swift_required.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Chris Corbyn" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Swiftmailer, free feature-rich PHP mailer", - "homepage": "http://swiftmailer.org", - "keywords": [ - "email", - "mail", - "mailer" - ], - "time": "2016-12-29T10:02:40+00:00" - }, - { - "name": "symfony/console", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/console.git", - "reference": "4f9e449e76996adf310498a8ca955c6deebe29dd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/4f9e449e76996adf310498a8ca955c6deebe29dd", - "reference": "4f9e449e76996adf310498a8ca955c6deebe29dd", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "symfony/debug": "~2.8|~3.0", - "symfony/polyfill-mbstring": "~1.0" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/event-dispatcher": "~2.8|~3.0", - "symfony/filesystem": "~2.8|~3.0", - "symfony/process": "~2.8|~3.0" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "", - "symfony/filesystem": "", - "symfony/process": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Console\\": "" - }, - "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 Console Component", - "homepage": "https://symfony.com", - "time": "2017-01-08T20:47:33+00:00" - }, - { - "name": "symfony/debug", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/debug.git", - "reference": "810ba5c1c5352a4ddb15d4719e8936751dff0b05" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/810ba5c1c5352a4ddb15d4719e8936751dff0b05", - "reference": "810ba5c1c5352a4ddb15d4719e8936751dff0b05", - "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.2-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": "2017-01-02T20:32:22+00:00" - }, - { - "name": "symfony/event-dispatcher", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "9137eb3a3328e413212826d63eeeb0217836e2b6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/9137eb3a3328e413212826d63eeeb0217836e2b6", - "reference": "9137eb3a3328e413212826d63eeeb0217836e2b6", - "shasum": "" - }, - "require": { - "php": ">=5.5.9" - }, - "require-dev": { - "psr/log": "~1.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": "", - "symfony/http-kernel": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\EventDispatcher\\": "" - }, - "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 EventDispatcher Component", - "homepage": "https://symfony.com", - "time": "2017-01-02T20:32:22+00:00" - }, - { - "name": "symfony/filesystem", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/filesystem.git", - "reference": "a0c6ef2dc78d33b58d91d3a49f49797a184d06f4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/a0c6ef2dc78d33b58d91d3a49f49797a184d06f4", - "reference": "a0c6ef2dc78d33b58d91d3a49f49797a184d06f4", - "shasum": "" - }, - "require": { - "php": ">=5.5.9" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Filesystem\\": "" - }, - "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 Filesystem Component", - "homepage": "https://symfony.com", - "time": "2017-01-08T20:47:33+00:00" - }, - { - "name": "symfony/finder", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/finder.git", - "reference": "8c71141cae8e2957946b403cc71a67213c0380d6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/8c71141cae8e2957946b403cc71a67213c0380d6", - "reference": "8c71141cae8e2957946b403cc71a67213c0380d6", - "shasum": "" - }, - "require": { - "php": ">=5.5.9" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Finder\\": "" - }, - "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 Finder Component", - "homepage": "https://symfony.com", - "time": "2017-01-02T20:32:22+00:00" - }, - { - "name": "symfony/http-foundation", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/http-foundation.git", - "reference": "33eb76bf1d833c705433e5361a646c164696394b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/33eb76bf1d833c705433e5361a646c164696394b", - "reference": "33eb76bf1d833c705433e5361a646c164696394b", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "symfony/polyfill-mbstring": "~1.1" - }, - "require-dev": { - "symfony/expression-language": "~2.8|~3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\HttpFoundation\\": "" - }, - "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 HttpFoundation Component", - "homepage": "https://symfony.com", - "time": "2017-01-08T20:47:33+00:00" - }, - { - "name": "symfony/polyfill-iconv", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-iconv.git", - "reference": "cba36f3616d9866b3e52662e88da5c090fac1e97" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/cba36f3616d9866b3e52662e88da5c090fac1e97", - "reference": "cba36f3616d9866b3e52662e88da5c090fac1e97", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-iconv": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Iconv\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Iconv extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "iconv", - "polyfill", - "portable", - "shim" - ], - "time": "2016-11-14T01:06:16+00:00" - }, - { - "name": "symfony/polyfill-mbstring", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/e79d363049d1c2128f133a2667e4f4190904f7f4", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Mbstring extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ], - "time": "2016-11-14T01:06:16+00:00" - }, - { - "name": "symfony/translation", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/translation.git", - "reference": "6520f3d4cce604d9dd1e86cac7af954984dd9bda" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/6520f3d4cce604d9dd1e86cac7af954984dd9bda", - "reference": "6520f3d4cce604d9dd1e86cac7af954984dd9bda", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "symfony/polyfill-mbstring": "~1.0" - }, - "conflict": { - "symfony/config": "<2.8" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~2.8|~3.0", - "symfony/intl": "~2.8|~3.0", - "symfony/yaml": "~2.8|~3.0" - }, - "suggest": { - "psr/log": "To use logging capability in translator", - "symfony/config": "", - "symfony/yaml": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Translation\\": "" - }, - "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 Translation Component", - "homepage": "https://symfony.com", - "time": "2017-01-02T20:32:22+00:00" - }, - { - "name": "symfony/validator", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/validator.git", - "reference": "506e0fe69ecdc595850c76081137116c0537d6e9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/validator/zipball/506e0fe69ecdc595850c76081137116c0537d6e9", - "reference": "506e0fe69ecdc595850c76081137116c0537d6e9", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "symfony/polyfill-mbstring": "~1.0", - "symfony/translation": "~2.8|~3.0" - }, - "require-dev": { - "doctrine/annotations": "~1.0", - "doctrine/cache": "~1.0", - "egulias/email-validator": "~1.2,>=1.2.8|~2.0", - "symfony/cache": "~3.1", - "symfony/config": "~2.8|~3.0", - "symfony/expression-language": "~2.8|~3.0", - "symfony/http-foundation": "~2.8|~3.0", - "symfony/intl": "~2.8|~3.0", - "symfony/yaml": "~2.8|~3.0" - }, - "suggest": { - "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", - "doctrine/cache": "For using the default cached annotation reader and metadata cache.", - "egulias/email-validator": "Strict (RFC compliant) email validation", - "psr/cache-implementation": "For using the metadata cache.", - "symfony/config": "", - "symfony/expression-language": "For using the Expression validator", - "symfony/http-foundation": "", - "symfony/intl": "", - "symfony/property-access": "For using the Expression validator", - "symfony/yaml": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Validator\\": "" - }, - "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 Validator Component", - "homepage": "https://symfony.com", - "time": "2017-01-12T19:27:47+00:00" - }, - { - "name": "symfony/var-dumper", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/var-dumper.git", - "reference": "b54b23f9a19b465e76fdaac0f6732410467c83b2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/b54b23f9a19b465e76fdaac0f6732410467c83b2", - "reference": "b54b23f9a19b465e76fdaac0f6732410467c83b2", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "symfony/polyfill-mbstring": "~1.0" - }, - "require-dev": { - "twig/twig": "~1.20|~2.0" - }, - "suggest": { - "ext-symfony_debug": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev" - } - }, - "autoload": { - "files": [ - "Resources/functions/dump.php" - ], - "psr-4": { - "Symfony\\Component\\VarDumper\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony mechanism for exploring and dumping PHP variables", - "homepage": "https://symfony.com", - "keywords": [ - "debug", - "dump" - ], - "time": "2017-01-03T08:53:57+00:00" - }, - { - "name": "symfony/yaml", - "version": "v3.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "50eadbd7926e31842893c957eca362b21592a97d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/50eadbd7926e31842893c957eca362b21592a97d", - "reference": "50eadbd7926e31842893c957eca362b21592a97d", - "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.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Yaml\\": "" - }, - "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 Yaml Component", - "homepage": "https://symfony.com", - "time": "2017-01-03T13:51:32+00:00" - }, - { - "name": "twig/twig", - "version": "v1.24.2", - "source": { - "type": "git", - "url": "https://github.com/twigphp/Twig.git", - "reference": "33093f6e310e6976baeac7b14f3a6ec02f2d79b7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/33093f6e310e6976baeac7b14f3a6ec02f2d79b7", - "reference": "33093f6e310e6976baeac7b14f3a6ec02f2d79b7", - "shasum": "" - }, - "require": { - "php": ">=5.2.7" - }, - "require-dev": { - "symfony/debug": "~2.7", - "symfony/phpunit-bridge": "~2.7" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.24-dev" - } - }, - "autoload": { - "psr-0": { - "Twig_": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com", - "homepage": "http://fabien.potencier.org", - "role": "Lead Developer" - }, - { - "name": "Armin Ronacher", - "email": "armin.ronacher@active-4.com", - "role": "Project Founder" - }, - { - "name": "Twig Team", - "homepage": "http://twig.sensiolabs.org/contributors", - "role": "Contributors" - } - ], - "description": "Twig, the flexible, fast, and secure template language for PHP", - "homepage": "http://twig.sensiolabs.org", - "keywords": [ - "templating" - ], - "time": "2016-09-01T17:50:53+00:00" - }, - { - "name": "zendframework/zend-code", - "version": "2.6.3", - "source": { - "type": "git", - "url": "https://github.com/zendframework/zend-code.git", - "reference": "95033f061b083e16cdee60530ec260d7d628b887" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-code/zipball/95033f061b083e16cdee60530ec260d7d628b887", - "reference": "95033f061b083e16cdee60530ec260d7d628b887", - "shasum": "" - }, - "require": { - "php": "^5.5 || 7.0.0 - 7.0.4 || ^7.0.6", - "zendframework/zend-eventmanager": "^2.6 || ^3.0" - }, - "require-dev": { - "doctrine/annotations": "~1.0", - "fabpot/php-cs-fixer": "1.7.*", - "phpunit/phpunit": "^4.8.21", - "zendframework/zend-stdlib": "^2.7 || ^3.0" - }, - "suggest": { - "doctrine/annotations": "Doctrine\\Common\\Annotations >=1.0 for annotation features", - "zendframework/zend-stdlib": "Zend\\Stdlib component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.6-dev", - "dev-develop": "2.7-dev" - } - }, - "autoload": { - "psr-4": { - "Zend\\Code\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides facilities to generate arbitrary code using an object oriented interface", - "homepage": "https://github.com/zendframework/zend-code", - "keywords": [ - "code", - "zf2" - ], - "time": "2016-04-20T17:26:42+00:00" - }, - { - "name": "zendframework/zend-eventmanager", - "version": "3.1.0", - "source": { - "type": "git", - "url": "https://github.com/zendframework/zend-eventmanager.git", - "reference": "c3bce7b7d47c54040b9ae51bc55491c72513b75d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-eventmanager/zipball/c3bce7b7d47c54040b9ae51bc55491c72513b75d", - "reference": "c3bce7b7d47c54040b9ae51bc55491c72513b75d", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "athletic/athletic": "^0.1", - "container-interop/container-interop": "^1.1.0", - "phpunit/phpunit": "^5.6", - "zendframework/zend-coding-standard": "~1.0.0", - "zendframework/zend-stdlib": "^2.7.3 || ^3.0" - }, - "suggest": { - "container-interop/container-interop": "^1.1.0, to use the lazy listeners feature", - "zendframework/zend-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev", - "dev-develop": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Zend\\EventManager\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Trigger and listen to events within a PHP application", - "homepage": "https://github.com/zendframework/zend-eventmanager", - "keywords": [ - "event", - "eventmanager", - "events", - "zf2" - ], - "time": "2016-12-19T21:47:12+00:00" - } - ], - "packages-dev": [ - { - "name": "doctrine/instantiator", - "version": "1.0.5", - "source": { - "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/doctrine/instantiator/8e884e78f9f0eb1329e445619e04456e64d8051d.zip", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", - "shasum": "" - }, - "require": { - "php": ">=5.3,<8.0-DEV" - }, - "require-dev": { - "athletic/athletic": "~0.1.8", - "ext-pdo": "*", - "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~2.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" - } - ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://github.com/doctrine/instantiator", - "keywords": [ - "constructor", - "instantiate" - ], - "time": "2015-06-14T21:17:01+00:00" - }, - { - "name": "myclabs/deep-copy", - "version": "1.5.5", - "source": { - "type": "git", - "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "399c1f9781e222f6eb6cc238796f5200d1b7f108" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/myclabs/DeepCopy/399c1f9781e222f6eb6cc238796f5200d1b7f108.zip", - "reference": "399c1f9781e222f6eb6cc238796f5200d1b7f108", - "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": "2016-10-31T17:19:45+00:00" - }, - { - "name": "phpdocumentor/reflection-common", - "version": "1.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "144c307535e82c8fdcaacbcfc1d6d8eeb896687c" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/phpDocumentor/ReflectionCommon/144c307535e82c8fdcaacbcfc1d6d8eeb896687c.zip", - "reference": "144c307535e82c8fdcaacbcfc1d6d8eeb896687c", - "shasum": "" - }, - "require": { - "php": ">=5.5" - }, - "require-dev": { - "phpunit/phpunit": "^4.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src" - ] - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jaap van Otterdijk", - "email": "opensource@ijaap.nl" - } - ], - "description": "Common reflection classes used by phpdocumentor to reflect the code structure", - "homepage": "http://www.phpdoc.org", - "keywords": [ - "FQSEN", - "phpDocumentor", - "phpdoc", - "reflection", - "static analysis" - ], - "time": "2015-12-27T11:43:31+00:00" - }, - { - "name": "phpdocumentor/reflection-docblock", - "version": "3.1.1", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/phpDocumentor/ReflectionDocBlock/8331b5efe816ae05461b7ca1e721c01b46bafb3e.zip", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e", - "shasum": "" - }, - "require": { - "php": ">=5.5", - "phpdocumentor/reflection-common": "^1.0@dev", - "phpdocumentor/type-resolver": "^0.2.0", - "webmozart/assert": "^1.0" - }, - "require-dev": { - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^4.4" - }, - "type": "library", - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "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-09-30T07:12:33+00:00" - }, - { - "name": "phpdocumentor/type-resolver", - "version": "0.2.1", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/phpDocumentor/TypeResolver/e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb.zip", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", - "shasum": "" - }, - "require": { - "php": ">=5.5", - "phpdocumentor/reflection-common": "^1.0" - }, - "require-dev": { - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^5.2||^4.8.24" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "time": "2016-11-25T06:54:22+00:00" - }, - { - "name": "phpspec/prophecy", - "version": "v1.6.2", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "6c52c2722f8460122f96f86346600e1077ce22cb" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/phpspec/prophecy/6c52c2722f8460122f96f86346600e1077ce22cb.zip", - "reference": "6c52c2722f8460122f96f86346600e1077ce22cb", - "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|^2.0" - }, - "require-dev": { - "phpspec/phpspec": "^2.0", - "phpunit/phpunit": "^4.8 || ^5.6.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6.x-dev" - } - }, - "autoload": { - "psr-0": { - "Prophecy\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "time": "2016-11-21T14:58:47+00:00" - }, - { - "name": "phpunit/php-code-coverage", - "version": "4.0.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "c14196e64a78570034afd0b7a9f3757ba71c2a0a" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/php-code-coverage/c14196e64a78570034afd0b7a9f3757ba71c2a0a.zip", - "reference": "c14196e64a78570034afd0b7a9f3757ba71c2a0a", - "shasum": "" - }, - "require": { - "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 || ^2.0", - "sebastian/version": "~1.0|~2.0" - }, - "require-dev": { - "ext-xdebug": ">=2.1.4", - "phpunit/phpunit": "^5.4" - }, - "suggest": { - "ext-dom": "*", - "ext-xdebug": ">=2.4.0", - "ext-xmlwriter": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", - "homepage": "https://github.com/sebastianbergmann/php-code-coverage", - "keywords": [ - "coverage", - "testing", - "xunit" - ], - "time": "2016-12-20T15:22:42+00:00" - }, - { - "name": "phpunit/php-file-iterator", - "version": "1.4.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/php-file-iterator/3cc8f69b3028d0f96a9078e6295d86e9bf019be5.zip", - "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "FilterIterator implementation that filters files based on a list of suffixes.", - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" - ], - "time": "2016-10-03T07:40:28+00:00" - }, - { - "name": "phpunit/php-text-template", - "version": "1.2.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/php-text-template/31f8b717e51d9a2afca6c9f046f5d69fc27c8686.zip", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" - ], - "time": "2015-06-21T13:50:34+00:00" - }, - { - "name": "phpunit/php-timer", - "version": "1.0.8", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "38e9124049cf1a164f1e4537caf19c99bf1eb260" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/php-timer/38e9124049cf1a164f1e4537caf19c99bf1eb260.zip", - "reference": "38e9124049cf1a164f1e4537caf19c99bf1eb260", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4|~5" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", - "keywords": [ - "timer" - ], - "time": "2016-05-12T18:03:57+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "1.4.9", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "3b402f65a4cc90abf6e1104e388b896ce209631b" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/php-token-stream/3b402f65a4cc90abf6e1104e388b896ce209631b.zip", - "reference": "3b402f65a4cc90abf6e1104e388b896ce209631b", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "time": "2016-11-15T14:06:22+00:00" - }, - { - "name": "phpunit/phpunit", - "version": "5.5.7", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "3f67cee782c9abfaee5e32fd2f57cdd54bc257ba" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/phpunit/3f67cee782c9abfaee5e32fd2f57cdd54bc257ba.zip", - "reference": "3f67cee782c9abfaee5e32fd2f57cdd54bc257ba", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-json": "*", - "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.1", - "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/diff": "~1.2", - "sebastian/environment": "^1.3 || ^2.0", - "sebastian/exporter": "~1.2", - "sebastian/global-state": "~1.0", - "sebastian/object-enumerator": "~1.0", - "sebastian/resource-operations": "~1.0", - "sebastian/version": "~1.0|~2.0", - "symfony/yaml": "~2.1|~3.0" - }, - "conflict": { - "phpdocumentor/reflection-docblock": "3.0.2" - }, - "require-dev": { - "ext-pdo": "*" - }, - "suggest": { - "ext-tidy": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "~1.1" - }, - "bin": [ - "phpunit" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.5.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "The PHP Unit Testing framework.", - "homepage": "https://phpunit.de/", - "keywords": [ - "phpunit", - "testing", - "xunit" - ], - "time": "2016-10-03T13:04:15+00:00" - }, - { - "name": "phpunit/phpunit-mock-objects", - "version": "3.4.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/phpunit-mock-objects/3ab72b65b39b491e0c011e2e09bb2206c2aa8e24.zip", - "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.6 || ^7.0", - "phpunit/php-text-template": "^1.2", - "sebastian/exporter": "^1.2 || ^2.0" - }, - "conflict": { - "phpunit/phpunit": "<5.4.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.4" - }, - "suggest": { - "ext-soap": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "Mock Object library for PHPUnit", - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", - "keywords": [ - "mock", - "xunit" - ], - "time": "2016-12-08T20:27:08+00:00" - }, - { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/code-unit-reverse-lookup/c36f5e7cfce482fde5bf8d10d41a53591e0198fe.zip", - "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe", - "shasum": "" - }, - "require": { - "php": ">=5.6" - }, - "require-dev": { - "phpunit/phpunit": "~5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "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-13T06:45:14+00:00" - }, - { - "name": "sebastian/comparator", - "version": "1.2.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "6a1ed12e8b2409076ab22e3897126211ff8b1f7f" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/comparator/6a1ed12e8b2409076ab22e3897126211ff8b1f7f.zip", - "reference": "6a1ed12e8b2409076ab22e3897126211ff8b1f7f", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "sebastian/diff": "~1.2", - "sebastian/exporter": "~1.2 || ~2.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" - ], - "time": "2016-11-19T09:18:40+00:00" - }, - { - "name": "sebastian/diff", - "version": "1.4.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "13edfd8706462032c2f52b4b862974dd46b71c9e" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/diff/13edfd8706462032c2f52b4b862974dd46b71c9e.zip", - "reference": "13edfd8706462032c2f52b4b862974dd46b71c9e", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.8" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Diff implementation", - "homepage": "https://github.com/sebastianbergmann/diff", - "keywords": [ - "diff" - ], - "time": "2015-12-08T07:14:41+00:00" - }, - { - "name": "sebastian/environment", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/environment/5795ffe5dc5b02460c3e34222fee8cbe245d8fac.zip", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" - ], - "time": "2016-11-26T07:53:53+00:00" - }, - { - "name": "sebastian/exporter", - "version": "1.2.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "42c4c2eec485ee3e159ec9884f95b431287edde4" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/exporter/42c4c2eec485ee3e159ec9884f95b431287edde4.zip", - "reference": "42c4c2eec485ee3e159ec9884f95b431287edde4", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "sebastian/recursion-context": "~1.0" - }, - "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "~4.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - } - ], - "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" - ], - "time": "2016-06-17T09:04:28+00:00" - }, - { - "name": "sebastian/global-state", - "version": "1.1.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/global-state/bc37d50fea7d017d3d340f230811c9f1d7280af4.zip", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.2" - }, - "suggest": { - "ext-uopz": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" - ], - "time": "2015-10-12T03:26:01+00:00" - }, - { - "name": "sebastian/object-enumerator", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "d4ca2fb70344987502567bc50081c03e6192fb26" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/object-enumerator/d4ca2fb70344987502567bc50081c03e6192fb26.zip", - "reference": "d4ca2fb70344987502567bc50081c03e6192fb26", - "shasum": "" - }, - "require": { - "php": ">=5.6", - "sebastian/recursion-context": "~1.0" - }, - "require-dev": { - "phpunit/phpunit": "~5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Traverses array structures and object graphs to enumerate all referenced objects", - "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2016-01-28T13:25:10+00:00" - }, - { - "name": "sebastian/recursion-context", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "913401df809e99e4f47b27cdd781f4a258d58791" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/recursion-context/913401df809e99e4f47b27cdd781f4a258d58791.zip", - "reference": "913401df809e99e4f47b27cdd781f4a258d58791", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - } - ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2015-11-11T19:50:13+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/resource-operations/ce990bb21759f94aeafd30209e8cfcdfa8bc3f52.zip", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52", - "shasum": "" - }, - "require": { - "php": ">=5.6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2015-07-28T20:34:47+00:00" - }, - { - "name": "sebastian/version", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/sebastianbergmann/version/99732be0ddb3361e16ad77b68ba41efc8e979019.zip", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", - "shasum": "" - }, - "require": { - "php": ">=5.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Library that helps with managing the version number of Git-hosted PHP projects", - "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f" - }, - "dist": { - "type": "zip", - "url": "https://packagist.phpcomposer.com/files/webmozart/assert/2db61e59ff05fe5126d152bd0655c9ea113e550f.zip", - "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.6", - "sebastian/version": "^1.0.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "time": "2016-11-23T20:04:58+00:00" - } - ], - "aliases": [], - "minimum-stability": "stable", - "stability-flags": [], - "prefer-stable": false, - "prefer-lowest": false, - "platform": [], - "platform-dev": [] -} diff --git a/src/Framework/Cache/Cache.php b/src/Framework/Cache/Cache.php index c253967..b825249 100644 --- a/src/Framework/Cache/Cache.php +++ b/src/Framework/Cache/Cache.php @@ -20,6 +20,6 @@ public static function getMap() */ public static function redis() { - return \Kernel::getInstance()->singleton('redisCache'); + return app()->singleton('redisCache'); } } diff --git a/src/Framework/Container/Container.php b/src/Framework/Container/Container.php index 2c024d2..1ad7fc0 100644 --- a/src/Framework/Container/Container.php +++ b/src/Framework/Container/Container.php @@ -8,5 +8,52 @@ */ class Container extends \Pimple\Container { + public function buildReflector($class) + { + if (!class_exists($class)) { + throw new \Exception("Class " . $class . " not found !"); + } -} \ No newline at end of file + $reflector = new \ReflectionClass($class); + + return $reflector; + } + + /** + * 设置response object + * + */ + public function setResponse($response) + { + $this['Response'] = $response; + } + + /** + * 获取设置的response object + * + *@return object + */ + public function getResponse() + { + return $this['Response']; + } + + /** + * 设置request object + * + */ + public function setRequest($request) + { + $this['Request'] = $request; + } + + /** + * 获取设置的request object + * + *@return object + */ + public function getRequest() + { + return $this['Request']; + } +} diff --git a/src/Framework/Controller/Controller.php b/src/Framework/Controller/Controller.php new file mode 100644 index 0000000..fa49a5d --- /dev/null +++ b/src/Framework/Controller/Controller.php @@ -0,0 +1,97 @@ +container = $container; + } + + /** + * @param $html + * @param array $parameters + * @return Response + */ + protected function render($html, $parameters = []) + { + if ($this->container['debug']) { + if ($this->container->singleton('debugbar')->hasCollector('view')) { + $parameters['模板地址'] = $html; + $this->container->singleton('debugbar')->getCollector('view')->setData($parameters); + } else { + $parameters['模板地址'] = $html; + $this->container->singleton('debugbar')->addCollector(new VarCollector($parameters)); + } + } + + $content = $this->container['twig']->render($html, $parameters); + return new Response($content, 200); + } + + protected function renderView($html, $parameters = []) + { + $content = $this->container['twig']->render($html, $parameters); + return $content; + } + + /** + * Returns a RedirectResponse to the given URL. + * + * @param string $targetUrl The URL to redirect to + * @param int $status The status code to use for the Response + * @param array headers + * + * @return RedirectResponse + */ + protected function redirect($targetUrl, $status = 302, $headers = array()) + { + return new RedirectResponse($targetUrl, $status, $headers); + } + + + /** + * @param $routeName An route name + * @param array $path An array of path parameters + * @param array $query An array of query parameters + * @throws callable|\Exception + */ + protected function forward($routeName, array $path = [], array $query = []) + { + $allRoutes = app('allRoutes'); + if (!$allRoutes[$routeName]) { + throw new \Exception('routeName error.'); + } + $routeConfig = $allRoutes[$routeName]; + $blankRoute = app('blankRoute'); + $blankRoute->url = $routeConfig['pattern']; + $blankRoute->config = $routeConfig['parameters']; + $blankRoute->parameters = $path; + $blankRoute->query = $query; + $blankRoute->dispatch($this->container); + } + + /** + * return jsonResponse content + * @param $data + * @param int $status + * @param array $header + * @return JsonResponse + */ + protected function json($data, $status = 200, array $header = [], $options = 0) + { + return json($data, $status, $header, $options); + } +} \ No newline at end of file diff --git a/src/Framework/Event/AppEvent.php b/src/Framework/Event/AppEvent.php index 9b0da23..c6fd167 100644 --- a/src/Framework/Event/AppEvent.php +++ b/src/Framework/Event/AppEvent.php @@ -17,4 +17,6 @@ final class AppEvent extends Event const NOTFOUND = "app.notfound"; const HTTPFINISH = "app.httpfinish"; + + const MIDDLEWARE = "app.middleware"; } diff --git a/src/Framework/Event/ExceptionEvent.php b/src/Framework/Event/ExceptionEvent.php index 5586f9a..81f4193 100644 --- a/src/Framework/Event/ExceptionEvent.php +++ b/src/Framework/Event/ExceptionEvent.php @@ -7,17 +7,10 @@ class ExceptionEvent extends Symfony_Event { protected $error; - protected $container; - public function __construct($error, $container) + public function __construct($error) { $this->error = $error; - $this->container = $container; - } - - public function getContainer() - { - return $this->container; } public function getError() diff --git a/src/Framework/Event/FilterControllerEvent.php b/src/Framework/Event/FilterControllerEvent.php index fff8af4..6c4279f 100644 --- a/src/Framework/Event/FilterControllerEvent.php +++ b/src/Framework/Event/FilterControllerEvent.php @@ -6,7 +6,7 @@ class FilterControllerEvent extends Event { - const NAME = 'filter.controller'; + const NAME = 'app.middleware'; private static $container = null; diff --git a/src/Framework/Handler/ExceptionsHandler.php b/src/Framework/Handler/ExceptionsHandler.php index 5d8fca0..684a734 100644 --- a/src/Framework/Handler/ExceptionsHandler.php +++ b/src/Framework/Handler/ExceptionsHandler.php @@ -137,6 +137,7 @@ protected function renderHttpResponse($e) } if ($this->container['env'] == 'prod') { + $this->record($e); $this->container['eventDispatcher']->dispatch(AppEvent::EXCEPTION, new ExceptionEvent($e, $this->container)); } diff --git a/src/Framework/Kernel.php b/src/Framework/Kernel.php index 367ea7e..6dc1f63 100644 --- a/src/Framework/Kernel.php +++ b/src/Framework/Kernel.php @@ -25,6 +25,7 @@ class Kernel extends Container 'Kernel' => 'TastPHP\Framework\Kernel', 'Config' => 'TastPHP\Framework\Config\Config', 'Cache' => 'TastPHP\Framework\Cache\Cache', + 'Controller' => 'TastPHP\Framework\Controller\Controller', 'FileCache' => 'TastPHP\Framework\Cache\FileCache', 'ServiceProvider' => 'TastPHP\Framework\Service\ServiceProvider', 'Logger' => 'TastPHP\Framework\Logger\Logger', @@ -48,7 +49,6 @@ class Kernel extends Container 'FileCache' => 'TastPHP\Framework\Cache\FileCacheServiceProvider', 'Logger' => 'TastPHP\Framework\Logger\LoggerServiceProvider', 'EventDispatcher' => 'TastPHP\Framework\EventDispatcher\EventDispatcherServiceProvider', - 'Twig' => 'TastPHP\Framework\Twig\TwigServiceProvider', 'Doctrine' => 'TastPHP\Framework\Doctrine\DoctrineServiceProvider', 'CsrfToken' => 'TastPHP\Framework\CsrfToken\CsrfTokenServiceProvider', 'Jwt' => 'TastPHP\Framework\Jwt\JwtServiceProvider', @@ -56,6 +56,7 @@ class Kernel extends Container 'SwiftMailer' => 'TastPHP\Framework\SwiftMailer\SwiftMailerServiceProvider', 'Queue' => 'TastPHP\Framework\Queue\QueueServiceProvider', 'Router' => 'TastPHP\Framework\Router\RouterServiceProvider', + 'Twig' => 'TastPHP\Framework\Twig\TwigServiceProvider', ]; use KernelListeners; @@ -78,6 +79,8 @@ public function __construct(array $values = []) $exception = new ExceptionsHandler(); $exception->bootstrap($this); + + $this['router']->matchCurrentRequest(); } use KernelTrait; diff --git a/src/Framework/Listener/ExceptionListener.php b/src/Framework/Listener/ExceptionListener.php index b3183c8..50097e0 100644 --- a/src/Framework/Listener/ExceptionListener.php +++ b/src/Framework/Listener/ExceptionListener.php @@ -6,7 +6,6 @@ use TastPHP\Framework\Event\AppEvent; use TastPHP\Framework\Event\HttpEvent; use TastPHP\Framework\Event\ExceptionEvent; -use Symfony\Component\HttpFoundation\Request; class ExceptionListener { @@ -17,15 +16,12 @@ public function setMethod() public function onExceptionAction(ExceptionEvent $event) { - $app = \Kernel::getInstance(); - - if ($app['env'] == 'prod') { - $app['Request'] = Request::createFromGlobals(); - $response = $app['twig']->render('errors/500.html'); + if (app('env') == 'prod') { + $response = app('twig')->render('errors/500.html'); } else { $response = new Response($event->getTrace(), 500); } - $event->getContainer()->singleton('eventDispatcher')->dispatch(AppEvent::RESPONSE, new HttpEvent(null, $response)); + app('eventDispatcher')->dispatch(AppEvent::RESPONSE, new HttpEvent(null, $response)); } } diff --git a/src/Framework/Listener/MailListener.php b/src/Framework/Listener/MailListener.php index 36e9d18..08dde18 100644 --- a/src/Framework/Listener/MailListener.php +++ b/src/Framework/Listener/MailListener.php @@ -9,6 +9,6 @@ public function onSendMailAction(MailEvent $event) { $data = $event->parameters; - \Queue::put(\Kernel::getInstance()->singleton('tube'), json_encode($data)); + \Queue::put(app('tube'), json_encode($data)); } } \ No newline at end of file diff --git a/src/Framework/Listener/NotFoundListener.php b/src/Framework/Listener/NotFoundListener.php index 78eb9ba..2f0d48a 100644 --- a/src/Framework/Listener/NotFoundListener.php +++ b/src/Framework/Listener/NotFoundListener.php @@ -3,15 +3,13 @@ namespace TastPHP\Framework\Listener; use TastPHP\Framework\Event\HttpEvent; -use TastPHP\Framework\Event\AppEvent; +use Symfony\Component\HttpFoundation\Response; class NotFoundListener { public function onNotFoundPageAction(HttpEvent $event) { - $app = \Kernel::getInstance(); - $app['Request'] = $event->getRequest(); - $response = $app['twig']->render('errors/404.html'); - $app['eventDispatcher']->dispatch(AppEvent::RESPONSE, new HttpEvent(null, $response)); + $response = app('twig')->render('errors/404.html'); + app()->setResponse(new Response($response, 404)); } } diff --git a/src/Framework/Listener/RequestListener.php b/src/Framework/Listener/RequestListener.php deleted file mode 100644 index 3cd4ebf..0000000 --- a/src/Framework/Listener/RequestListener.php +++ /dev/null @@ -1,13 +0,0 @@ -dispatch(AppEvent::HTTPFINISH, new HttpEvent($event->getRequest(), $response)); exit; } } \ No newline at end of file diff --git a/src/Framework/ListenerRegister/ListenerRegisterService.php b/src/Framework/ListenerRegister/ListenerRegisterService.php index 96c3905..d96520d 100644 --- a/src/Framework/ListenerRegister/ListenerRegisterService.php +++ b/src/Framework/ListenerRegister/ListenerRegisterService.php @@ -28,7 +28,7 @@ public function register(Container $app) private function registerKernelListeners($app) { - $listeners = \Kernel::getInstance()->getListeners(); + $listeners = app()->getListeners(); foreach ($listeners as $eventName => $listener) { list($listener, $callback) = explode('@', $listener); diff --git a/src/Framework/Router/RouterService.php b/src/Framework/Router/RouterService.php index 27572eb..fed6a88 100644 --- a/src/Framework/Router/RouterService.php +++ b/src/Framework/Router/RouterService.php @@ -3,6 +3,7 @@ namespace TastPHP\Framework\Router; use Symfony\Component\HttpFoundation\ParameterBag; +use TastPHP\Framework\Event\AppEvent; /** * Class Route @@ -120,22 +121,6 @@ public function getParameterByName($name) return $this->parameters[$name]; } - /** - * @param $class - * @return \ReflectionClass - * @throws \Exception - */ - private function buildMoudle($class) - { - if (!class_exists($class)) { - throw new \Exception("Class " . $class . " not found !"); - } - - $reflector = new \ReflectionClass($class); - - return $reflector; - } - public function dispatch($container) { $action = explode('::', $this->config['_controller']); @@ -152,7 +137,7 @@ public function dispatch($container) } $class = "{$namespaceDir}\\{$bundleName}Bundle\\Controller\\{$module}Controller"; - $reflector = $this->buildMoudle($class); + $reflector = app()->buildReflector($class); $action = $action[1] . "Action"; if (!$reflector->hasMethod($action)) { throw new \Exception("Class " . $class . " exist ,But the Action " . $action . " not found"); @@ -264,7 +249,12 @@ public function matchCurrentRequest() return; } - return $this->match($pathInfo, $requestMethod); + $response = $this->match($pathInfo, $requestMethod); + if ($response) { + app()->setResponse($response); + } else { + self::$parameters['eventDispatcher']->dispatch(AppEvent::NOTFOUND, new \TastPHP\Framework\Event\HttpEvent()); + } } /** @@ -313,9 +303,6 @@ public function match($requestUrl, $requestMethod = 'GET') self::$parameters['CurrentRoute'] = $route; return $route->dispatch(self::$parameters); } - $request = self::$parameters['Request']; - - self::$parameters['eventDispatcher']->dispatch('app.notfound', new \TastPHP\Framework\Event\HttpEvent($request)); } /** diff --git a/src/Framework/Router/RouterServiceProvider.php b/src/Framework/Router/RouterServiceProvider.php index 391d32e..661fd21 100644 --- a/src/Framework/Router/RouterServiceProvider.php +++ b/src/Framework/Router/RouterServiceProvider.php @@ -13,7 +13,7 @@ class RouterServiceProvider extends ServiceProvider public function register() { $request = Request::createFromGlobals(); - $this->app['Request'] = $request; + $this->app->setRequest($request); $this->app->singleton('eventDispatcher')->dispatch(AppEvent::REQUEST, new \TastPHP\Framework\Event\HttpEvent($request)); $router = new TastRouter(); diff --git a/src/Framework/Router/TastRouter.php b/src/Framework/Router/TastRouter.php index 3614b3d..8071a8b 100644 --- a/src/Framework/Router/TastRouter.php +++ b/src/Framework/Router/TastRouter.php @@ -14,16 +14,22 @@ class TastRouter { public function register(Container $app) - { + { + $isMobile = $app['isMobile']; + $routeConfigAll = []; $routeCacheDir = __BASEDIR__ . "/var/cache/config/routes"; - $routeCacheFile = $routeCacheDir . "/routeConfigAll.php"; + if ($isMobile) { + $routeCacheFile = $routeCacheDir . "/routeConfigMobile.php"; + } else { + $routeCacheFile = $routeCacheDir . "/routeConfigAll.php"; + } if (file_exists($routeCacheFile) && (!$app['debug'])) { $routeConfigAll = require $routeCacheFile; } else { - $routeConfigAll = $this->parseAllRoutes($app,$routeConfigAll); + $routeConfigAll = $this->parseAllRoutes($app, $routeConfigAll); if (!$app['debug']) { $fs = new Filesystem(); @@ -43,22 +49,26 @@ public function register(Container $app) RouterService::setParameters($app); } - private function parseAllRoutes($app,$routeConfigAll = []) + private function parseAllRoutes($app, $routeConfigAll = []) { - $routeConfigAll = $this->parseRoutesConfig(__BASEDIR__ . '/config/routes.yml', $routeConfigAll); + $routeConfigAll = $this->parseRoutesConfig(__BASEDIR__ . '/config/routes.yml', $routeConfigAll, $app); if ($app['debug']) { - $routeConfigAll = $this->parseRoutesConfig(__BASEDIR__ . '/config/routes_test.yml', $routeConfigAll); + $routeConfigAll = $this->parseRoutesConfig(__BASEDIR__ . '/config/routes_test.yml', $routeConfigAll, $app); } return $routeConfigAll; } - private function parseRoutesConfig($routesFile, $routeConfigAll) + private function parseRoutesConfig($routesFile, $routeConfigAll, $app) { $array = []; $routesConfigs = \Yaml::parse(file_get_contents($routesFile)); - foreach ($routesConfigs as $routeConfig) { + foreach ($routesConfigs as $key => $routeConfig) { + //手机版只加载手机的route + if (($app['isMobile'] && $key != 'mobile') || (!$app['isMobile'] && $key == 'mobile')) { + continue; + } $resource = ($routeConfig['resource']); if (is_file(__BASEDIR__ . "/src/" . $resource) && file_exists(__BASEDIR__ . "/src/" . $resource)) { $array = \Yaml::parse(file_get_contents(__BASEDIR__ . "/src/" . $resource)); diff --git a/src/Framework/Service/ServiceMap.php b/src/Framework/Service/ServiceMap.php index 000ee0f..1825593 100644 --- a/src/Framework/Service/ServiceMap.php +++ b/src/Framework/Service/ServiceMap.php @@ -19,7 +19,7 @@ public static function getMap() public static function __callStatic($method, $parameters) { $map = static::getMap(); - $object = \Kernel::getInstance()->singleton($map); + $object = app()->singleton($map); if (!is_object($object)) throw new \RuntimeException($map.' can not be loaded , check your service provider config!'); diff --git a/src/Framework/Traits/KernelListeners.php b/src/Framework/Traits/KernelListeners.php index 07ff3e9..5de57d0 100644 --- a/src/Framework/Traits/KernelListeners.php +++ b/src/Framework/Traits/KernelListeners.php @@ -1,7 +1,6 @@ 'TastPHP\Framework\Listener\RequestListener@onRequestAction', - FilterControllerEvent::NAME => 'TastPHP\Framework\Listener\MiddlewareListener@onMiddlewareAction', AppEvent::RESPONSE => 'TastPHP\Framework\Listener\ResponseListener@onResponseAction', AppEvent::EXCEPTION => 'TastPHP\Framework\Listener\ExceptionListener@onExceptionAction', MailEvent::MAIlSEND => 'TastPHP\Framework\Listener\MailListener@onSendMailAction', diff --git a/src/Framework/Traits/KernelTrait.php b/src/Framework/Traits/KernelTrait.php index 4bf0967..ab575a9 100644 --- a/src/Framework/Traits/KernelTrait.php +++ b/src/Framework/Traits/KernelTrait.php @@ -3,21 +3,13 @@ use TastPHP\Framework\Handler\AliasLoaderHandler; use TastPHP\Framework\Event\AppEvent; - +use TastPHP\Framework\Event\HttpEvent; /** * Class KernelTrait * @package TastPHP\Framework\Traits */ trait KernelTrait { - /** - * run app - */ - public function run() - { - $this['eventDispatcher']->dispatch(AppEvent::RESPONSE, new \TastPHP\Framework\Event\HttpEvent(null, $this['router']->matchCurrentRequest())); - } - /** * @param $name * @param null $callable @@ -141,4 +133,38 @@ public function getListeners($key = '') return $this->listeners; } + + /** + * 处理一个抽象对象 + * @param string $abstract + * @return mixed + */ + public function make($abstract) + { + //如果是已经注册的单例对象 + if (isset($this[$abstract])) { + return $this[$abstract]; + } + + $reflector = $this->buildReflector($abstract); + //有单例 + if ($reflector->hasMethod('getInstance')) { + $object = $abstract::getInstance(); + $this[$abstract] = $object; + return $object; + } + + return new $abstract; + } + + /** + * 处理响应请求 + * + */ + public function run() + { + $response = $this->getResponse(); + $request = $this->getRequest(); + \EventDispatcher::dispatch(AppEvent::RESPONSE, new HttpEvent($request, $response)); + } } \ No newline at end of file diff --git a/src/Framework/Twig/TwigService.php b/src/Framework/Twig/TwigService.php index f6e3805..f9c476d 100644 --- a/src/Framework/Twig/TwigService.php +++ b/src/Framework/Twig/TwigService.php @@ -10,9 +10,11 @@ public function register(Container $app) { $app->singleton('twig', function () use ($app) { + $defaultBundle = $app['isMobile'] ? __BASEDIR__ . '/web/views/mobileBundle' : __BASEDIR__ . '/web/views/frontBundle'; + $loader = new \Twig_Loader_Filesystem([ __BASEDIR__ . '/web/views/', - __BASEDIR__ . '/web/views/frontBundle', + $defaultBundle, ]); $env = array( @@ -28,6 +30,5 @@ public function register(Container $app) } return $twig; }); - } } \ No newline at end of file diff --git a/src/Framework/helpers.php b/src/Framework/helpers.php new file mode 100644 index 0000000..f2b17cb --- /dev/null +++ b/src/Framework/helpers.php @@ -0,0 +1,56 @@ +make($abstract); + } +} + +if (!function_exists('ajax')) { + /** + * ajax return.返回一个json数组,并结束整个请求。 + * + * @param string $message + * @param array $data + * @param int $code + * @return void + * + */ + function ajax($message = '', $data = [], $code = 200) + { + app()->setResponse(new JsonResponse(['message' => $message, 'data' => $data, 'code' => $code], 200)); + app()->run(); + exit; + } +} + +if (!function_exists('json')) { + /** + * 返回一个json response + * + * @param array $data + * @param int $status + * @param array $headers + * @param int $options + * @return object \JsonResponse + * + */ + function json($data = [], $status = 200, array $headers = [], $options = 0) + { + return new JsonResponse($data, $status, $headers, $options); + } +} diff --git a/tests/config/app.yml b/tests/config/app.yml index 4b76f83..4721062 100644 --- a/tests/config/app.yml +++ b/tests/config/app.yml @@ -2,5 +2,6 @@ version: v1.0.0 debug: true secret: tastphp-framework # dev | test | prod -env: dev -timezone: UTC \ No newline at end of file +env: test +timezone: UTC +name: tast \ No newline at end of file diff --git a/tests/index.php b/tests/index.php new file mode 100644 index 0000000..6f6979f --- /dev/null +++ b/tests/index.php @@ -0,0 +1,8 @@ +run(); + diff --git a/tests/src/FrontBundle/Config/routes.yml b/tests/src/FrontBundle/Config/routes.yml new file mode 100644 index 0000000..c1fc23f --- /dev/null +++ b/tests/src/FrontBundle/Config/routes.yml @@ -0,0 +1,6 @@ +home: + pattern: / + parameters: + _controller: Front@Home::index + methods: [GET,POST] + routeName: home \ No newline at end of file diff --git a/tests/src/FrontBundle/Controller/HomeController.php b/tests/src/FrontBundle/Controller/HomeController.php new file mode 100644 index 0000000..21eeecf --- /dev/null +++ b/tests/src/FrontBundle/Controller/HomeController.php @@ -0,0 +1,14 @@ +render('home/index.html.twig', [ + ]); + } +} \ No newline at end of file diff --git a/tests/web/views/errors/404.html b/tests/web/views/errors/404.html new file mode 100644 index 0000000..75908b5 --- /dev/null +++ b/tests/web/views/errors/404.html @@ -0,0 +1,33 @@ + + +
+ + + +