diff --git a/composer.json b/composer.json
index e9fd186..6815020 100644
--- a/composer.json
+++ b/composer.json
@@ -26,8 +26,11 @@
},
"require": {
"php": "^7.4 || ~8.0.0 || ~8.1.0",
- "laminas/laminas-http": "^2.15",
+ "laminas/laminas-http": "^2.15.1",
+ "laminas/laminas-mvc": "^3.3.3",
+ "laminas/laminas-router": "^3.7.0",
"laminas/laminas-servicemanager": "^3.16.0",
+ "laminas/laminas-stdlib": "^3.11",
"laminas/laminas-view": "^2.22.0",
"psr/container": "^1 || ^2",
"webmozart/assert": "^1.11.0"
diff --git a/composer.lock b/composer.lock
index 4c1c070..ed8068e 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,8 +4,125 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "1787c715b2f93009e4894d132a3de23f",
+ "content-hash": "a59befc7b96df3a9a3ecd520b3c272b0",
"packages": [
+ {
+ "name": "brick/varexporter",
+ "version": "0.3.7",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/brick/varexporter.git",
+ "reference": "3e263cd718d242594c52963760fee2059fd5833c"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/brick/varexporter/zipball/3e263cd718d242594c52963760fee2059fd5833c",
+ "reference": "3e263cd718d242594c52963760fee2059fd5833c",
+ "shasum": ""
+ },
+ "require": {
+ "nikic/php-parser": "^4.0",
+ "php": "^7.2 || ^8.0"
+ },
+ "require-dev": {
+ "php-coveralls/php-coveralls": "^2.2",
+ "phpunit/phpunit": "^8.5 || ^9.0",
+ "vimeo/psalm": "4.23.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Brick\\VarExporter\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "description": "A powerful alternative to var_export(), which can export closures and objects without __set_state()",
+ "keywords": [
+ "var_export"
+ ],
+ "support": {
+ "issues": "https://github.com/brick/varexporter/issues",
+ "source": "https://github.com/brick/varexporter/tree/0.3.7"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/BenMorel",
+ "type": "github"
+ }
+ ],
+ "time": "2022-06-29T23:37:57+00:00"
+ },
+ {
+ "name": "laminas/laminas-config",
+ "version": "3.7.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-config.git",
+ "reference": "e43d13dcfc273d4392812eb395ce636f73f34dfd"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-config/zipball/e43d13dcfc273d4392812eb395ce636f73f34dfd",
+ "reference": "e43d13dcfc273d4392812eb395ce636f73f34dfd",
+ "shasum": ""
+ },
+ "require": {
+ "ext-json": "*",
+ "laminas/laminas-stdlib": "^3.6",
+ "php": "^7.3 || ~8.0.0 || ~8.1.0",
+ "psr/container": "^1.0"
+ },
+ "conflict": {
+ "container-interop/container-interop": "<1.2.0",
+ "zendframework/zend-config": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~1.0.0",
+ "laminas/laminas-filter": "^2.7.2",
+ "laminas/laminas-i18n": "^2.10.3",
+ "laminas/laminas-servicemanager": "^3.7",
+ "phpunit/phpunit": "^9.5.5"
+ },
+ "suggest": {
+ "laminas/laminas-filter": "^2.7.2; install if you want to use the Filter processor",
+ "laminas/laminas-i18n": "^2.7.4; install if you want to use the Translator processor",
+ "laminas/laminas-servicemanager": "^2.7.8 || ^3.3; if you need an extensible plugin manager for use with the Config Factory"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Laminas\\Config\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "provides a nested object property based user interface for accessing this configuration data within application code",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "config",
+ "laminas"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-config/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-config/issues",
+ "rss": "https://github.com/laminas/laminas-config/releases.atom",
+ "source": "https://github.com/laminas/laminas-config"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2021-10-01T16:07:46+00:00"
+ },
{
"name": "laminas/laminas-escaper",
"version": "2.10.0",
@@ -68,6 +185,73 @@
],
"time": "2022-03-08T20:15:36+00:00"
},
+ {
+ "name": "laminas/laminas-eventmanager",
+ "version": "3.5.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-eventmanager.git",
+ "reference": "41f7209428f37cab9573365e361f4078209aaafa"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/41f7209428f37cab9573365e361f4078209aaafa",
+ "reference": "41f7209428f37cab9573365e361f4078209aaafa",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.4 || ~8.0.0 || ~8.1.0"
+ },
+ "conflict": {
+ "container-interop/container-interop": "<1.2",
+ "zendframework/zend-eventmanager": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~2.2.1",
+ "laminas/laminas-stdlib": "^3.6",
+ "phpbench/phpbench": "^1.1",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5.5",
+ "psr/container": "^1.1.2 || ^2.0.2"
+ },
+ "suggest": {
+ "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature",
+ "psr/container": "^1.1.2 || ^2.0.2, to use the lazy listeners feature"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Laminas\\EventManager\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Trigger and listen to events within a PHP application",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "event",
+ "eventmanager",
+ "events",
+ "laminas"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-eventmanager/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-eventmanager/issues",
+ "rss": "https://github.com/laminas/laminas-eventmanager/releases.atom",
+ "source": "https://github.com/laminas/laminas-eventmanager"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-04-06T21:05:17+00:00"
+ },
{
"name": "laminas/laminas-http",
"version": "2.15.1",
@@ -133,6 +317,67 @@
],
"time": "2021-12-03T10:17:11+00:00"
},
+ {
+ "name": "laminas/laminas-json",
+ "version": "3.3.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-json.git",
+ "reference": "9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-json/zipball/9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f",
+ "reference": "9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.3 || ~8.0.0 || ~8.1.0"
+ },
+ "conflict": {
+ "zendframework/zend-json": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~2.2.1",
+ "laminas/laminas-stdlib": "^2.7.7 || ^3.1",
+ "phpunit/phpunit": "^9.3"
+ },
+ "suggest": {
+ "laminas/laminas-json-server": "For implementing JSON-RPC servers",
+ "laminas/laminas-xml2json": "For converting XML documents to JSON"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Laminas\\Json\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "provides convenience methods for serializing native PHP to JSON and decoding JSON to native PHP",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "json",
+ "laminas"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-json/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-json/issues",
+ "rss": "https://github.com/laminas/laminas-json/releases.atom",
+ "source": "https://github.com/laminas/laminas-json"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2021-09-02T18:02:31+00:00"
+ },
{
"name": "laminas/laminas-loader",
"version": "2.8.0",
@@ -190,87 +435,66 @@
"time": "2021-09-02T18:30:53+00:00"
},
{
- "name": "laminas/laminas-servicemanager",
- "version": "3.16.0",
+ "name": "laminas/laminas-modulemanager",
+ "version": "2.11.0",
"source": {
"type": "git",
- "url": "https://github.com/laminas/laminas-servicemanager.git",
- "reference": "863c66733740cd36ebf5e700f4258ef2c68a2a24"
+ "url": "https://github.com/laminas/laminas-modulemanager.git",
+ "reference": "6acf5991d10b0b38a2edb08729ed48981b2a5dad"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/863c66733740cd36ebf5e700f4258ef2c68a2a24",
- "reference": "863c66733740cd36ebf5e700f4258ef2c68a2a24",
+ "url": "https://api.github.com/repos/laminas/laminas-modulemanager/zipball/6acf5991d10b0b38a2edb08729ed48981b2a5dad",
+ "reference": "6acf5991d10b0b38a2edb08729ed48981b2a5dad",
"shasum": ""
},
"require": {
- "laminas/laminas-stdlib": "^3.2.1",
- "php": "~7.4.0 || ~8.0.0 || ~8.1.0",
- "psr/container": "^1.0"
+ "brick/varexporter": "^0.3.2",
+ "laminas/laminas-config": "^3.7",
+ "laminas/laminas-eventmanager": "^3.4",
+ "laminas/laminas-stdlib": "^3.6",
+ "php": "^7.3 || ~8.0.0 || ~8.1.0",
+ "webimpress/safe-writer": "^1.0.2 || ^2.1"
},
"conflict": {
- "ext-psr": "*",
- "laminas/laminas-code": "<3.3.1",
- "zendframework/zend-code": "<3.3.1",
- "zendframework/zend-servicemanager": "*"
- },
- "provide": {
- "psr/container-implementation": "^1.0"
- },
- "replace": {
- "container-interop/container-interop": "^1.2.0"
+ "zendframework/zend-modulemanager": "*"
},
"require-dev": {
- "composer/package-versions-deprecated": "^1.0",
- "laminas/laminas-coding-standard": "~2.3.0",
- "laminas/laminas-container-config-test": "^0.7",
- "laminas/laminas-dependency-plugin": "^2.1.2",
- "mikey179/vfsstream": "^1.6.10@alpha",
- "ocramius/proxy-manager": "^2.11",
- "phpbench/phpbench": "^1.1",
- "phpspec/prophecy-phpunit": "^2.0",
- "phpunit/phpunit": "^9.5.5",
- "psalm/plugin-phpunit": "^0.17.0",
- "vimeo/psalm": "^4.8"
+ "laminas/laminas-coding-standard": "^2.3",
+ "laminas/laminas-loader": "^2.8",
+ "laminas/laminas-mvc": "^3.1.1",
+ "laminas/laminas-servicemanager": "^3.7",
+ "phpunit/phpunit": "^9.5.5"
},
"suggest": {
- "ocramius/proxy-manager": "ProxyManager ^2.1.1 to handle lazy initialization of services"
+ "laminas/laminas-console": "Laminas\\Console component",
+ "laminas/laminas-loader": "Laminas\\Loader component if you are not using Composer autoloading for your modules",
+ "laminas/laminas-mvc": "Laminas\\Mvc component",
+ "laminas/laminas-servicemanager": "Laminas\\ServiceManager component"
},
- "bin": [
- "bin/generate-deps-for-config-factory",
- "bin/generate-factory-for-class"
- ],
"type": "library",
"autoload": {
- "files": [
- "src/autoload.php"
- ],
"psr-4": {
- "Laminas\\ServiceManager\\": "src/"
+ "Laminas\\ModuleManager\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
],
- "description": "Factory-Driven Dependency Injection Container",
+ "description": "Modular application system for laminas-mvc applications",
"homepage": "https://laminas.dev",
"keywords": [
- "PSR-11",
- "dependency-injection",
- "di",
- "dic",
"laminas",
- "service-manager",
- "servicemanager"
+ "modulemanager"
],
"support": {
"chat": "https://laminas.dev/chat",
- "docs": "https://docs.laminas.dev/laminas-servicemanager/",
+ "docs": "https://docs.laminas.dev/laminas-modulemanager/",
"forum": "https://discourse.laminas.dev",
- "issues": "https://github.com/laminas/laminas-servicemanager/issues",
- "rss": "https://github.com/laminas/laminas-servicemanager/releases.atom",
- "source": "https://github.com/laminas/laminas-servicemanager"
+ "issues": "https://github.com/laminas/laminas-modulemanager/issues",
+ "rss": "https://github.com/laminas/laminas-modulemanager/releases.atom",
+ "source": "https://github.com/laminas/laminas-modulemanager"
},
"funding": [
{
@@ -278,58 +502,81 @@
"type": "community_bridge"
}
],
- "time": "2022-07-27T14:58:17+00:00"
+ "time": "2021-10-13T17:05:17+00:00"
},
{
- "name": "laminas/laminas-stdlib",
- "version": "3.11.0",
+ "name": "laminas/laminas-mvc",
+ "version": "3.3.3",
"source": {
"type": "git",
- "url": "https://github.com/laminas/laminas-stdlib.git",
- "reference": "aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f"
+ "url": "https://github.com/laminas/laminas-mvc.git",
+ "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f",
- "reference": "aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f",
+ "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/7ff2bfbe64048aa83c6d1c7edcbab849123f0150",
+ "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150",
"shasum": ""
},
"require": {
+ "container-interop/container-interop": "^1.2",
+ "laminas/laminas-eventmanager": "^3.4",
+ "laminas/laminas-http": "^2.15",
+ "laminas/laminas-modulemanager": "^2.8",
+ "laminas/laminas-router": "^3.5",
+ "laminas/laminas-servicemanager": "^3.7",
+ "laminas/laminas-stdlib": "^3.6",
+ "laminas/laminas-view": "^2.14",
"php": "^7.3 || ~8.0.0 || ~8.1.0"
},
"conflict": {
- "zendframework/zend-stdlib": "*"
+ "zendframework/zend-mvc": "*"
},
"require-dev": {
- "laminas/laminas-coding-standard": "~2.3.0",
- "phpbench/phpbench": "^1.0",
- "phpunit/phpunit": "^9.3.7",
- "psalm/plugin-phpunit": "^0.17.0",
- "vimeo/psalm": "^4.7"
+ "http-interop/http-middleware": "^0.4.1",
+ "laminas/laminas-coding-standard": "^1.0.0",
+ "laminas/laminas-json": "^3.3",
+ "laminas/laminas-psr7bridge": "^1.0",
+ "laminas/laminas-stratigility": ">=2.0.1 <2.2",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5.5"
+ },
+ "suggest": {
+ "laminas/laminas-json": "(^2.6.1 || ^3.0) To auto-deserialize JSON body content in AbstractRestfulController extensions, when json_decode is unavailable",
+ "laminas/laminas-log": "^2.9.1 To provide log functionality via LogFilterManager, LogFormatterManager, and LogProcessorManager",
+ "laminas/laminas-mvc-console": "laminas-mvc-console provides the ability to expose laminas-mvc as a console application",
+ "laminas/laminas-mvc-i18n": "laminas-mvc-i18n provides integration with laminas-i18n, including a translation bridge and translatable route segments",
+ "laminas/laminas-mvc-middleware": "To dispatch middleware in your laminas-mvc application",
+ "laminas/laminas-mvc-plugin-fileprg": "To provide Post/Redirect/Get functionality around forms that container file uploads",
+ "laminas/laminas-mvc-plugin-flashmessenger": "To provide flash messaging capabilities between requests",
+ "laminas/laminas-mvc-plugin-identity": "To access the authenticated identity (per laminas-authentication) in controllers",
+ "laminas/laminas-mvc-plugin-prg": "To provide Post/Redirect/Get functionality within controllers",
+ "laminas/laminas-paginator": "^2.7 To provide pagination functionality via PaginatorPluginManager",
+ "laminas/laminas-servicemanager-di": "laminas-servicemanager-di provides utilities for integrating laminas-di and laminas-servicemanager in your laminas-mvc application"
},
"type": "library",
"autoload": {
"psr-4": {
- "Laminas\\Stdlib\\": "src/"
+ "Laminas\\Mvc\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
],
- "description": "SPL extensions, array utilities, error handlers, and more",
+ "description": "Laminas's event-driven MVC layer, including MVC Applications, Controllers, and Plugins",
"homepage": "https://laminas.dev",
"keywords": [
"laminas",
- "stdlib"
+ "mvc"
],
"support": {
"chat": "https://laminas.dev/chat",
- "docs": "https://docs.laminas.dev/laminas-stdlib/",
+ "docs": "https://docs.laminas.dev/laminas-mvc/",
"forum": "https://discourse.laminas.dev",
- "issues": "https://github.com/laminas/laminas-stdlib/issues",
- "rss": "https://github.com/laminas/laminas-stdlib/releases.atom",
- "source": "https://github.com/laminas/laminas-stdlib"
+ "issues": "https://github.com/laminas/laminas-mvc/issues",
+ "rss": "https://github.com/laminas/laminas-mvc/releases.atom",
+ "source": "https://github.com/laminas/laminas-mvc"
},
"funding": [
{
@@ -337,29 +584,250 @@
"type": "community_bridge"
}
],
- "time": "2022-07-27T12:28:58+00:00"
+ "time": "2022-02-21T20:21:58+00:00"
},
{
- "name": "laminas/laminas-uri",
- "version": "2.9.1",
+ "name": "laminas/laminas-router",
+ "version": "3.7.0",
"source": {
"type": "git",
- "url": "https://github.com/laminas/laminas-uri.git",
- "reference": "7e837dc15c8fd3949df7d1213246fd7c8640032b"
+ "url": "https://github.com/laminas/laminas-router.git",
+ "reference": "0227cc29f62583dd1ca50d17d117b832edaa8cd8"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laminas/laminas-uri/zipball/7e837dc15c8fd3949df7d1213246fd7c8640032b",
- "reference": "7e837dc15c8fd3949df7d1213246fd7c8640032b",
+ "url": "https://api.github.com/repos/laminas/laminas-router/zipball/0227cc29f62583dd1ca50d17d117b832edaa8cd8",
+ "reference": "0227cc29f62583dd1ca50d17d117b832edaa8cd8",
"shasum": ""
},
"require": {
- "laminas/laminas-escaper": "^2.9",
- "laminas/laminas-validator": "^2.15",
- "php": "^7.3 || ~8.0.0 || ~8.1.0"
+ "laminas/laminas-http": "^2.15",
+ "laminas/laminas-servicemanager": "^3.14.0",
+ "laminas/laminas-stdlib": "^3.10.1",
+ "php": "^7.4 || ~8.0.0 || ~8.1.0"
},
"conflict": {
- "zendframework/zend-uri": "*"
+ "zendframework/zend-router": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~2.2.1",
+ "laminas/laminas-i18n": "^2.15.0",
+ "phpunit/phpunit": "^9.5.5",
+ "psalm/plugin-phpunit": "^0.17.0",
+ "vimeo/psalm": "^4.24.0"
+ },
+ "suggest": {
+ "laminas/laminas-i18n": "^2.15.0 if defining translatable HTTP path segments"
+ },
+ "type": "library",
+ "extra": {
+ "laminas": {
+ "component": "Laminas\\Router",
+ "config-provider": "Laminas\\Router\\ConfigProvider"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Laminas\\Router\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Flexible routing system for HTTP and console applications",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "laminas",
+ "routing"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-router/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-router/issues",
+ "rss": "https://github.com/laminas/laminas-router/releases.atom",
+ "source": "https://github.com/laminas/laminas-router"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-07-18T01:39:51+00:00"
+ },
+ {
+ "name": "laminas/laminas-servicemanager",
+ "version": "3.16.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-servicemanager.git",
+ "reference": "863c66733740cd36ebf5e700f4258ef2c68a2a24"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/863c66733740cd36ebf5e700f4258ef2c68a2a24",
+ "reference": "863c66733740cd36ebf5e700f4258ef2c68a2a24",
+ "shasum": ""
+ },
+ "require": {
+ "laminas/laminas-stdlib": "^3.2.1",
+ "php": "~7.4.0 || ~8.0.0 || ~8.1.0",
+ "psr/container": "^1.0"
+ },
+ "conflict": {
+ "ext-psr": "*",
+ "laminas/laminas-code": "<3.3.1",
+ "zendframework/zend-code": "<3.3.1",
+ "zendframework/zend-servicemanager": "*"
+ },
+ "provide": {
+ "psr/container-implementation": "^1.0"
+ },
+ "replace": {
+ "container-interop/container-interop": "^1.2.0"
+ },
+ "require-dev": {
+ "composer/package-versions-deprecated": "^1.0",
+ "laminas/laminas-coding-standard": "~2.3.0",
+ "laminas/laminas-container-config-test": "^0.7",
+ "laminas/laminas-dependency-plugin": "^2.1.2",
+ "mikey179/vfsstream": "^1.6.10@alpha",
+ "ocramius/proxy-manager": "^2.11",
+ "phpbench/phpbench": "^1.1",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5.5",
+ "psalm/plugin-phpunit": "^0.17.0",
+ "vimeo/psalm": "^4.8"
+ },
+ "suggest": {
+ "ocramius/proxy-manager": "ProxyManager ^2.1.1 to handle lazy initialization of services"
+ },
+ "bin": [
+ "bin/generate-deps-for-config-factory",
+ "bin/generate-factory-for-class"
+ ],
+ "type": "library",
+ "autoload": {
+ "files": [
+ "src/autoload.php"
+ ],
+ "psr-4": {
+ "Laminas\\ServiceManager\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Factory-Driven Dependency Injection Container",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "PSR-11",
+ "dependency-injection",
+ "di",
+ "dic",
+ "laminas",
+ "service-manager",
+ "servicemanager"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-servicemanager/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-servicemanager/issues",
+ "rss": "https://github.com/laminas/laminas-servicemanager/releases.atom",
+ "source": "https://github.com/laminas/laminas-servicemanager"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-07-27T14:58:17+00:00"
+ },
+ {
+ "name": "laminas/laminas-stdlib",
+ "version": "3.11.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-stdlib.git",
+ "reference": "aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f",
+ "reference": "aad7d2b11ba0069ba0d9b40f6dde3c2fa664b57f",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.3 || ~8.0.0 || ~8.1.0"
+ },
+ "conflict": {
+ "zendframework/zend-stdlib": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~2.3.0",
+ "phpbench/phpbench": "^1.0",
+ "phpunit/phpunit": "^9.3.7",
+ "psalm/plugin-phpunit": "^0.17.0",
+ "vimeo/psalm": "^4.7"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Laminas\\Stdlib\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "SPL extensions, array utilities, error handlers, and more",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "laminas",
+ "stdlib"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-stdlib/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-stdlib/issues",
+ "rss": "https://github.com/laminas/laminas-stdlib/releases.atom",
+ "source": "https://github.com/laminas/laminas-stdlib"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-07-27T12:28:58+00:00"
+ },
+ {
+ "name": "laminas/laminas-uri",
+ "version": "2.9.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-uri.git",
+ "reference": "7e837dc15c8fd3949df7d1213246fd7c8640032b"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-uri/zipball/7e837dc15c8fd3949df7d1213246fd7c8640032b",
+ "reference": "7e837dc15c8fd3949df7d1213246fd7c8640032b",
+ "shasum": ""
+ },
+ "require": {
+ "laminas/laminas-escaper": "^2.9",
+ "laminas/laminas-validator": "^2.15",
+ "php": "^7.3 || ~8.0.0 || ~8.1.0"
+ },
+ "conflict": {
+ "zendframework/zend-uri": "*"
},
"require-dev": {
"laminas/laminas-coding-standard": "~2.2.1",
@@ -370,140 +838,423 @@
"psr-4": {
"Laminas\\Uri\\": "src/"
}
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "BSD-3-Clause"
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "A component that aids in manipulating and validating » Uniform Resource Identifiers (URIs)",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "laminas",
+ "uri"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-uri/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-uri/issues",
+ "rss": "https://github.com/laminas/laminas-uri/releases.atom",
+ "source": "https://github.com/laminas/laminas-uri"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2021-09-09T18:37:15+00:00"
+ },
+ {
+ "name": "laminas/laminas-validator",
+ "version": "2.23.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-validator.git",
+ "reference": "6d61b6cc3b222f13807a18d9247cdfb084958b03"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/6d61b6cc3b222f13807a18d9247cdfb084958b03",
+ "reference": "6d61b6cc3b222f13807a18d9247cdfb084958b03",
+ "shasum": ""
+ },
+ "require": {
+ "laminas/laminas-servicemanager": "^3.12.0",
+ "laminas/laminas-stdlib": "^3.10",
+ "php": "^7.4 || ~8.0.0 || ~8.1.0"
+ },
+ "conflict": {
+ "zendframework/zend-validator": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-coding-standard": "~2.3.0",
+ "laminas/laminas-db": "^2.7",
+ "laminas/laminas-filter": "^2.14.0",
+ "laminas/laminas-http": "^2.14.2",
+ "laminas/laminas-i18n": "^2.15.0",
+ "laminas/laminas-session": "^2.12.1",
+ "laminas/laminas-uri": "^2.9.1",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5.21",
+ "psalm/plugin-phpunit": "^0.17.0",
+ "psr/http-client": "^1.0",
+ "psr/http-factory": "^1.0",
+ "psr/http-message": "^1.0",
+ "vimeo/psalm": "^4.24.0"
+ },
+ "suggest": {
+ "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator",
+ "laminas/laminas-filter": "Laminas\\Filter component, required by the Digits validator",
+ "laminas/laminas-i18n": "Laminas\\I18n component to allow translation of validation error messages",
+ "laminas/laminas-i18n-resources": "Translations of validator messages",
+ "laminas/laminas-servicemanager": "Laminas\\ServiceManager component to allow using the ValidatorPluginManager and validator chains",
+ "laminas/laminas-session": "Laminas\\Session component, ^2.8; required by the Csrf validator",
+ "laminas/laminas-uri": "Laminas\\Uri component, required by the Uri and Sitemap\\Loc validators",
+ "psr/http-message": "psr/http-message, required when validating PSR-7 UploadedFileInterface instances via the Upload and UploadFile validators"
+ },
+ "type": "library",
+ "extra": {
+ "laminas": {
+ "component": "Laminas\\Validator",
+ "config-provider": "Laminas\\Validator\\ConfigProvider"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Laminas\\Validator\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Validation classes for a wide range of domains, and the ability to chain validators to create complex validation criteria",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "laminas",
+ "validator"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-validator/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-validator/issues",
+ "rss": "https://github.com/laminas/laminas-validator/releases.atom",
+ "source": "https://github.com/laminas/laminas-validator"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-07-27T19:17:59+00:00"
+ },
+ {
+ "name": "laminas/laminas-view",
+ "version": "2.22.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laminas/laminas-view.git",
+ "reference": "ae32391bdec45ca9fc73dd0882cd7301ab07ecf3"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laminas/laminas-view/zipball/ae32391bdec45ca9fc73dd0882cd7301ab07ecf3",
+ "reference": "ae32391bdec45ca9fc73dd0882cd7301ab07ecf3",
+ "shasum": ""
+ },
+ "require": {
+ "container-interop/container-interop": "^1.2",
+ "ext-dom": "*",
+ "ext-filter": "*",
+ "ext-json": "*",
+ "laminas/laminas-escaper": "^2.5",
+ "laminas/laminas-eventmanager": "^3.4",
+ "laminas/laminas-json": "^3.3",
+ "laminas/laminas-servicemanager": "^3.14.0",
+ "laminas/laminas-stdlib": "^3.10.1",
+ "php": "^7.4 || ~8.0.0 || ~8.1.0",
+ "psr/container": "^1 || ^2"
+ },
+ "conflict": {
+ "container-interop/container-interop": "<1.2",
+ "laminas/laminas-router": "<3.0.1",
+ "laminas/laminas-servicemanager": "<3.3",
+ "laminas/laminas-session": "<2.12",
+ "zendframework/zend-view": "*"
+ },
+ "require-dev": {
+ "laminas/laminas-authentication": "^2.5",
+ "laminas/laminas-coding-standard": "~2.3.0",
+ "laminas/laminas-console": "^2.6",
+ "laminas/laminas-feed": "^2.15",
+ "laminas/laminas-filter": "^2.13.0",
+ "laminas/laminas-http": "^2.15",
+ "laminas/laminas-i18n": "^2.6",
+ "laminas/laminas-modulemanager": "^2.7.1",
+ "laminas/laminas-mvc": "^3.0",
+ "laminas/laminas-mvc-i18n": "^1.1",
+ "laminas/laminas-mvc-plugin-flashmessenger": "^1.5.0",
+ "laminas/laminas-navigation": "^2.13.1",
+ "laminas/laminas-paginator": "^2.11.0",
+ "laminas/laminas-permissions-acl": "^2.6",
+ "laminas/laminas-router": "^3.0.1",
+ "laminas/laminas-uri": "^2.5",
+ "phpspec/prophecy": "^1.12",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5.5",
+ "psalm/plugin-phpunit": "^0.17.0",
+ "vimeo/psalm": "^4.10"
+ },
+ "suggest": {
+ "laminas/laminas-authentication": "Laminas\\Authentication component",
+ "laminas/laminas-escaper": "Laminas\\Escaper component",
+ "laminas/laminas-feed": "Laminas\\Feed component",
+ "laminas/laminas-filter": "Laminas\\Filter component",
+ "laminas/laminas-http": "Laminas\\Http component",
+ "laminas/laminas-i18n": "Laminas\\I18n component",
+ "laminas/laminas-mvc": "Laminas\\Mvc component",
+ "laminas/laminas-mvc-plugin-flashmessenger": "laminas-mvc-plugin-flashmessenger component, if you want to use the FlashMessenger view helper with laminas-mvc versions 3 and up",
+ "laminas/laminas-navigation": "Laminas\\Navigation component",
+ "laminas/laminas-paginator": "Laminas\\Paginator component",
+ "laminas/laminas-permissions-acl": "Laminas\\Permissions\\Acl component",
+ "laminas/laminas-servicemanager": "Laminas\\ServiceManager component",
+ "laminas/laminas-uri": "Laminas\\Uri component"
+ },
+ "bin": [
+ "bin/templatemap_generator.php"
+ ],
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Laminas\\View\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Flexible view layer supporting and providing multiple view layers, helpers, and more",
+ "homepage": "https://laminas.dev",
+ "keywords": [
+ "laminas",
+ "view"
+ ],
+ "support": {
+ "chat": "https://laminas.dev/chat",
+ "docs": "https://docs.laminas.dev/laminas-view/",
+ "forum": "https://discourse.laminas.dev",
+ "issues": "https://github.com/laminas/laminas-view/issues",
+ "rss": "https://github.com/laminas/laminas-view/releases.atom",
+ "source": "https://github.com/laminas/laminas-view"
+ },
+ "funding": [
+ {
+ "url": "https://funding.communitybridge.org/projects/laminas-project",
+ "type": "community_bridge"
+ }
+ ],
+ "time": "2022-07-19T09:25:16+00:00"
+ },
+ {
+ "name": "nikic/php-parser",
+ "version": "v4.14.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/nikic/PHP-Parser.git",
+ "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/34bea19b6e03d8153165d8f30bba4c3be86184c1",
+ "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1",
+ "shasum": ""
+ },
+ "require": {
+ "ext-tokenizer": "*",
+ "php": ">=7.0"
+ },
+ "require-dev": {
+ "ircmaxell/php-yacc": "^0.0.7",
+ "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0"
+ },
+ "bin": [
+ "bin/php-parse"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "4.9-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "PhpParser\\": "lib/PhpParser"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Nikita Popov"
+ }
+ ],
+ "description": "A PHP parser written in PHP",
+ "keywords": [
+ "parser",
+ "php"
+ ],
+ "support": {
+ "issues": "https://github.com/nikic/PHP-Parser/issues",
+ "source": "https://github.com/nikic/PHP-Parser/tree/v4.14.0"
+ },
+ "time": "2022-05-31T20:59:12+00:00"
+ },
+ {
+ "name": "psr/container",
+ "version": "1.1.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/container.git",
+ "reference": "513e0666f7216c7459170d56df27dfcefe1689ea"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/container/zipball/513e0666f7216c7459170d56df27dfcefe1689ea",
+ "reference": "513e0666f7216c7459170d56df27dfcefe1689ea",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.4.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Container\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
],
- "description": "A component that aids in manipulating and validating » Uniform Resource Identifiers (URIs)",
- "homepage": "https://laminas.dev",
+ "description": "Common Container Interface (PHP FIG PSR-11)",
+ "homepage": "https://github.com/php-fig/container",
"keywords": [
- "laminas",
- "uri"
+ "PSR-11",
+ "container",
+ "container-interface",
+ "container-interop",
+ "psr"
],
"support": {
- "chat": "https://laminas.dev/chat",
- "docs": "https://docs.laminas.dev/laminas-uri/",
- "forum": "https://discourse.laminas.dev",
- "issues": "https://github.com/laminas/laminas-uri/issues",
- "rss": "https://github.com/laminas/laminas-uri/releases.atom",
- "source": "https://github.com/laminas/laminas-uri"
+ "issues": "https://github.com/php-fig/container/issues",
+ "source": "https://github.com/php-fig/container/tree/1.1.2"
},
- "funding": [
- {
- "url": "https://funding.communitybridge.org/projects/laminas-project",
- "type": "community_bridge"
- }
- ],
- "time": "2021-09-09T18:37:15+00:00"
+ "time": "2021-11-05T16:50:12+00:00"
},
{
- "name": "laminas/laminas-validator",
- "version": "2.23.0",
+ "name": "webimpress/safe-writer",
+ "version": "2.2.0",
"source": {
"type": "git",
- "url": "https://github.com/laminas/laminas-validator.git",
- "reference": "6d61b6cc3b222f13807a18d9247cdfb084958b03"
+ "url": "https://github.com/webimpress/safe-writer.git",
+ "reference": "9d37cc8bee20f7cb2f58f6e23e05097eab5072e6"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/6d61b6cc3b222f13807a18d9247cdfb084958b03",
- "reference": "6d61b6cc3b222f13807a18d9247cdfb084958b03",
+ "url": "https://api.github.com/repos/webimpress/safe-writer/zipball/9d37cc8bee20f7cb2f58f6e23e05097eab5072e6",
+ "reference": "9d37cc8bee20f7cb2f58f6e23e05097eab5072e6",
"shasum": ""
},
"require": {
- "laminas/laminas-servicemanager": "^3.12.0",
- "laminas/laminas-stdlib": "^3.10",
- "php": "^7.4 || ~8.0.0 || ~8.1.0"
- },
- "conflict": {
- "zendframework/zend-validator": "*"
+ "php": "^7.3 || ^8.0"
},
"require-dev": {
- "laminas/laminas-coding-standard": "~2.3.0",
- "laminas/laminas-db": "^2.7",
- "laminas/laminas-filter": "^2.14.0",
- "laminas/laminas-http": "^2.14.2",
- "laminas/laminas-i18n": "^2.15.0",
- "laminas/laminas-session": "^2.12.1",
- "laminas/laminas-uri": "^2.9.1",
- "phpspec/prophecy-phpunit": "^2.0",
- "phpunit/phpunit": "^9.5.21",
- "psalm/plugin-phpunit": "^0.17.0",
- "psr/http-client": "^1.0",
- "psr/http-factory": "^1.0",
- "psr/http-message": "^1.0",
- "vimeo/psalm": "^4.24.0"
- },
- "suggest": {
- "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator",
- "laminas/laminas-filter": "Laminas\\Filter component, required by the Digits validator",
- "laminas/laminas-i18n": "Laminas\\I18n component to allow translation of validation error messages",
- "laminas/laminas-i18n-resources": "Translations of validator messages",
- "laminas/laminas-servicemanager": "Laminas\\ServiceManager component to allow using the ValidatorPluginManager and validator chains",
- "laminas/laminas-session": "Laminas\\Session component, ^2.8; required by the Csrf validator",
- "laminas/laminas-uri": "Laminas\\Uri component, required by the Uri and Sitemap\\Loc validators",
- "psr/http-message": "psr/http-message, required when validating PSR-7 UploadedFileInterface instances via the Upload and UploadFile validators"
+ "phpunit/phpunit": "^9.5.4",
+ "vimeo/psalm": "^4.7",
+ "webimpress/coding-standard": "^1.2.2"
},
"type": "library",
"extra": {
- "laminas": {
- "component": "Laminas\\Validator",
- "config-provider": "Laminas\\Validator\\ConfigProvider"
+ "branch-alias": {
+ "dev-master": "2.2.x-dev",
+ "dev-develop": "2.3.x-dev",
+ "dev-release-1.0": "1.0.x-dev"
}
},
"autoload": {
"psr-4": {
- "Laminas\\Validator\\": "src/"
+ "Webimpress\\SafeWriter\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
- "BSD-3-Clause"
+ "BSD-2-Clause"
],
- "description": "Validation classes for a wide range of domains, and the ability to chain validators to create complex validation criteria",
- "homepage": "https://laminas.dev",
+ "description": "Tool to write files safely, to avoid race conditions",
"keywords": [
- "laminas",
- "validator"
+ "concurrent write",
+ "file writer",
+ "race condition",
+ "safe writer",
+ "webimpress"
],
"support": {
- "chat": "https://laminas.dev/chat",
- "docs": "https://docs.laminas.dev/laminas-validator/",
- "forum": "https://discourse.laminas.dev",
- "issues": "https://github.com/laminas/laminas-validator/issues",
- "rss": "https://github.com/laminas/laminas-validator/releases.atom",
- "source": "https://github.com/laminas/laminas-validator"
+ "issues": "https://github.com/webimpress/safe-writer/issues",
+ "source": "https://github.com/webimpress/safe-writer/tree/2.2.0"
},
"funding": [
{
- "url": "https://funding.communitybridge.org/projects/laminas-project",
- "type": "community_bridge"
+ "url": "https://github.com/michalbundyra",
+ "type": "github"
}
],
- "time": "2022-07-27T19:17:59+00:00"
+ "time": "2021-04-19T16:34:45+00:00"
},
{
- "name": "psr/container",
- "version": "1.1.2",
+ "name": "webmozart/assert",
+ "version": "1.11.0",
"source": {
"type": "git",
- "url": "https://github.com/php-fig/container.git",
- "reference": "513e0666f7216c7459170d56df27dfcefe1689ea"
+ "url": "https://github.com/webmozarts/assert.git",
+ "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/php-fig/container/zipball/513e0666f7216c7459170d56df27dfcefe1689ea",
- "reference": "513e0666f7216c7459170d56df27dfcefe1689ea",
+ "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991",
+ "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991",
"shasum": ""
},
"require": {
- "php": ">=7.4.0"
+ "ext-ctype": "*",
+ "php": "^7.2 || ^8.0"
+ },
+ "conflict": {
+ "phpstan/phpstan": "<0.12.20",
+ "vimeo/psalm": "<4.6.1 || 4.6.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^8.5.13"
},
"type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.10-dev"
+ }
+ },
"autoload": {
"psr-4": {
- "Psr\\Container\\": "src/"
+ "Webmozart\\Assert\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
@@ -512,24 +1263,21 @@
],
"authors": [
{
- "name": "PHP-FIG",
- "homepage": "https://www.php-fig.org/"
+ "name": "Bernhard Schussek",
+ "email": "bschussek@gmail.com"
}
],
- "description": "Common Container Interface (PHP FIG PSR-11)",
- "homepage": "https://github.com/php-fig/container",
+ "description": "Assertions to validate method input/output with nice error messages.",
"keywords": [
- "PSR-11",
- "container",
- "container-interface",
- "container-interop",
- "psr"
+ "assert",
+ "check",
+ "validate"
],
"support": {
- "issues": "https://github.com/php-fig/container/issues",
- "source": "https://github.com/php-fig/container/tree/1.1.2"
+ "issues": "https://github.com/webmozarts/assert/issues",
+ "source": "https://github.com/webmozarts/assert/tree/1.11.0"
},
- "time": "2021-11-05T16:50:12+00:00"
+ "time": "2022-06-03T18:03:27+00:00"
}
],
"packages-dev": [
@@ -1516,62 +2264,6 @@
},
"time": "2020-12-01T19:48:11+00:00"
},
- {
- "name": "nikic/php-parser",
- "version": "v4.14.0",
- "source": {
- "type": "git",
- "url": "https://github.com/nikic/PHP-Parser.git",
- "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/34bea19b6e03d8153165d8f30bba4c3be86184c1",
- "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1",
- "shasum": ""
- },
- "require": {
- "ext-tokenizer": "*",
- "php": ">=7.0"
- },
- "require-dev": {
- "ircmaxell/php-yacc": "^0.0.7",
- "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0"
- },
- "bin": [
- "bin/php-parse"
- ],
- "type": "library",
- "extra": {
- "branch-alias": {
- "dev-master": "4.9-dev"
- }
- },
- "autoload": {
- "psr-4": {
- "PhpParser\\": "lib/PhpParser"
- }
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "BSD-3-Clause"
- ],
- "authors": [
- {
- "name": "Nikita Popov"
- }
- ],
- "description": "A PHP parser written in PHP",
- "keywords": [
- "parser",
- "php"
- ],
- "support": {
- "issues": "https://github.com/nikic/PHP-Parser/issues",
- "source": "https://github.com/nikic/PHP-Parser/tree/v4.14.0"
- },
- "time": "2022-05-31T20:59:12+00:00"
- },
{
"name": "openlss/lib-array2xml",
"version": "1.0.0",
@@ -4658,64 +5350,6 @@
],
"time": "2022-02-15T19:52:12+00:00"
},
- {
- "name": "webmozart/assert",
- "version": "1.11.0",
- "source": {
- "type": "git",
- "url": "https://github.com/webmozarts/assert.git",
- "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991",
- "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991",
- "shasum": ""
- },
- "require": {
- "ext-ctype": "*",
- "php": "^7.2 || ^8.0"
- },
- "conflict": {
- "phpstan/phpstan": "<0.12.20",
- "vimeo/psalm": "<4.6.1 || 4.6.2"
- },
- "require-dev": {
- "phpunit/phpunit": "^8.5.13"
- },
- "type": "library",
- "extra": {
- "branch-alias": {
- "dev-master": "1.10-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"
- ],
- "support": {
- "issues": "https://github.com/webmozarts/assert/issues",
- "source": "https://github.com/webmozarts/assert/tree/1.11.0"
- },
- "time": "2022-06-03T18:03:27+00:00"
- },
{
"name": "webmozart/glob",
"version": "4.6.0",
@@ -4827,7 +5461,7 @@
},
"platform-dev": [],
"platform-overrides": {
- "php": "7.4"
+ "php": "7.4.99"
},
"plugin-api-version": "2.3.0"
}
diff --git a/psalm-baseline.xml b/psalm-baseline.xml
new file mode 100644
index 0000000..b452b87
--- /dev/null
+++ b/psalm-baseline.xml
@@ -0,0 +1,8 @@
+
+
+
+
+ (string) $this->routeMatch->getMatchedRouteName()
+
+
+
diff --git a/psalm.xml b/psalm.xml
index d0e3638..0d10f54 100644
--- a/psalm.xml
+++ b/psalm.xml
@@ -4,6 +4,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://getpsalm.org/schema/config"
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
+ errorBaseline="psalm-baseline.xml"
>
diff --git a/src/ConfigProvider.php b/src/ConfigProvider.php
index 933ef37..1fb5b28 100644
--- a/src/ConfigProvider.php
+++ b/src/ConfigProvider.php
@@ -53,6 +53,7 @@ public function getViewHelperConfig(): array
return [
'factories' => [
Helper\ServerUrl::class => Helper\Factory\ServerUrlFactory::class,
+ Helper\Url::class => Helper\Factory\UrlFactory::class,
/**
* Factories for helpers in Laminas\View
*/
@@ -60,6 +61,7 @@ public function getViewHelperConfig(): array
],
'aliases' => [
'serverUrl' => Helper\ServerUrl::class,
+ 'url' => Helper\Url::class,
],
];
}
diff --git a/src/Exception/RouteNotMatchedException.php b/src/Exception/RouteNotMatchedException.php
new file mode 100644
index 0000000..cd14629
--- /dev/null
+++ b/src/Exception/RouteNotMatchedException.php
@@ -0,0 +1,15 @@
+get('HttpRouter');
+ Assert::isInstanceOf($router, RouteStackInterface::class);
+
+ /**
+ * The RouteMatch instance must be retrieved from the MVC Event
+ */
+ $mvcApplication = $container->get('Application');
+ assert($mvcApplication instanceof Application);
+ $routeMatch = $mvcApplication->getMvcEvent()->getRouteMatch();
+ Assert::isInstanceOf($routeMatch, RouteMatch::class);
+
+ return new Url(
+ $routeMatch,
+ $router
+ );
+ }
+}
diff --git a/src/Helper/Url.php b/src/Helper/Url.php
new file mode 100644
index 0000000..64eeedc
--- /dev/null
+++ b/src/Helper/Url.php
@@ -0,0 +1,95 @@
+routeMatch = $routeMatch;
+ $this->router = $router;
+ }
+
+ /**
+ * Generates an url given the name of a route.
+ *
+ * @see RouteInterface::assemble()
+ *
+ * @param string|null $name Name of the route
+ * @param iterable $params Parameters for the link
+ * @param iterable|bool $options Options for the route, or bool $reuseMatchedParams to skip the 4th argument
+ * @param bool $reuseMatchedParams Whether to reuse matched parameters
+ * @return string Url For the link href attribute
+ * @throws RouteNotMatchedException If RouteMatch didn't contain a matched route name.
+ */
+ public function __invoke(
+ ?string $name = null,
+ iterable $params = [],
+ $options = [],
+ bool $reuseMatchedParams = false
+ ): string {
+ $name = $name ?? (string) $this->routeMatch->getMatchedRouteName();
+ if ($name === '') {
+ throw RouteNotMatchedException::withEmptyRouteName();
+ }
+
+ if (is_object($params)) {
+ $params = ArrayUtils::iteratorToArray($params);
+ }
+
+ if (is_object($options)) {
+ $options = ArrayUtils::iteratorToArray($options);
+ }
+
+ if (func_num_args() === 3 && is_bool($options)) {
+ $reuseMatchedParams = $options;
+ $options = [];
+ }
+
+ assert(is_array($options));
+
+ if ($reuseMatchedParams) {
+ $routeMatchParams = $this->routeMatch->getParams();
+
+ /** @var mixed $controller */
+ $controller = $routeMatchParams[ModuleRouteListener::ORIGINAL_CONTROLLER] ?? null;
+
+ if (is_string($controller)) {
+ $routeMatchParams['controller'] = $controller;
+ unset($routeMatchParams[ModuleRouteListener::ORIGINAL_CONTROLLER]);
+ }
+
+ if (isset($routeMatchParams[ModuleRouteListener::MODULE_NAMESPACE])) {
+ unset($routeMatchParams[ModuleRouteListener::MODULE_NAMESPACE]);
+ }
+
+ $params = array_merge($routeMatchParams, $params);
+ }
+
+ $options['name'] = $name;
+
+ return (string) $this->router->assemble($params, $options);
+ }
+}
diff --git a/test/Helper/Factory/UrlFactoryTest.php b/test/Helper/Factory/UrlFactoryTest.php
new file mode 100644
index 0000000..6d9ba6a
--- /dev/null
+++ b/test/Helper/Factory/UrlFactoryTest.php
@@ -0,0 +1,44 @@
+setRouteMatch($match);
+
+ $application = $this->createMock(Application::class);
+ $application->expects(self::once())
+ ->method('getMvcEvent')
+ ->willReturn($event);
+
+ $container = $this->createMock(ContainerInterface::class);
+ $container->expects(self::exactly(2))
+ ->method('get')
+ ->willReturnMap([
+ ['HttpRouter', $router],
+ ['Application', $application],
+ ]);
+
+ (new UrlFactory())->__invoke($container);
+ }
+}
diff --git a/test/Helper/UrlTest.php b/test/Helper/UrlTest.php
new file mode 100644
index 0000000..866be47
--- /dev/null
+++ b/test/Helper/UrlTest.php
@@ -0,0 +1,199 @@
+router = new TreeRouteStack();
+ $this->router->addRoute('home', [
+ 'type' => Literal::class,
+ 'options' => [
+ 'route' => '/',
+ ],
+ ]);
+ $this->router->addRoute('default', [
+ 'type' => Segment::class,
+ 'options' => [
+ 'route' => '/:controller[/:action]',
+ ],
+ ]);
+
+ $this->routeMatch = new RouteMatch([]);
+ $this->helper = new Url($this->routeMatch, $this->router);
+ }
+
+ public function testNamedStaticRouteCanBeRetrieved(): void
+ {
+ self::assertEquals('/', $this->helper->__invoke('home'));
+ }
+
+ public function testItIsExceptionalToCallTheHelperWithoutARouteName(): void
+ {
+ $this->expectException(RouteNotMatchedException::class);
+ $this->expectExceptionMessage(
+ 'A route name was not provided or RouteMatch does not contain a matched route name'
+ );
+ $this->helper->__invoke();
+ }
+
+ public function testDefaultModuleRouting(): void
+ {
+ self::assertEquals(
+ '/my/route',
+ $this->helper->__invoke('default', ['controller' => 'my', 'action' => 'route'])
+ );
+ }
+
+ public function testDefaultModuleRoutingWithTraversable(): void
+ {
+ $arrayObject = new ArrayObject(['controller' => 'my', 'action' => 'route']);
+ self::assertEquals(
+ '/my/route',
+ $this->helper->__invoke('default', $arrayObject)
+ );
+ }
+
+ public function testThatMatchedRouteParametersCanBeReused(): void
+ {
+ $this->routeMatch->setMatchedRouteName('replace');
+ $this->routeMatch->setParam('controller', 'groovy');
+
+ $this->router->addRoute('replace', [
+ 'type' => Segment::class,
+ 'options' => [
+ 'route' => '/:controller/:action',
+ 'defaults' => [
+ 'controller' => 'default',
+ ],
+ ],
+ ]);
+
+ self::assertEquals(
+ '/groovy/bar',
+ $this->helper->__invoke('replace', ['action' => 'bar'], [], true)
+ );
+ }
+
+ public function testThatOptionsAreUsed(): void
+ {
+ self::assertEquals(
+ '/#foo',
+ $this->helper->__invoke('home', [], ['fragment' => 'foo'], false)
+ );
+ }
+
+ public function testThatOptionsCanBeTraversable(): void
+ {
+ $options = new ArrayObject(['fragment' => 'foo']);
+ self::assertEquals(
+ '/#foo',
+ $this->helper->__invoke('home', [], $options, false)
+ );
+ }
+
+ public function testThatReuseMatchedRouteParamsCanBeProvidedAsTheThirdArgument(): void
+ {
+ $this->routeMatch->setMatchedRouteName('replace');
+ $this->routeMatch->setParam('controller', 'groovy');
+
+ $this->router->addRoute('replace', [
+ 'type' => Segment::class,
+ 'options' => [
+ 'route' => '/:controller/:action',
+ 'defaults' => [
+ 'controller' => 'default',
+ ],
+ ],
+ ]);
+
+ self::assertEquals(
+ '/groovy/bar',
+ $this->helper->__invoke('replace', ['action' => 'bar'], true)
+ );
+ }
+
+ public function testThatMatchedRouteParamsAreNotReusedByDefault(): void
+ {
+ $this->routeMatch->setMatchedRouteName('replace');
+ $this->routeMatch->setParam('controller', 'groovy');
+
+ $this->router->addRoute('replace', [
+ 'type' => Segment::class,
+ 'options' => [
+ 'route' => '/:controller/:action',
+ 'defaults' => [
+ 'controller' => 'default',
+ ],
+ ],
+ ]);
+
+ self::assertEquals(
+ '/default/bar',
+ $this->helper->__invoke('replace', ['action' => 'bar'])
+ );
+ }
+
+ public function testThatControllerIsSourcedFromModuleRouteListenerWhenAvailable(): void
+ {
+ $this->routeMatch->setMatchedRouteName('default');
+ $this->routeMatch->setParam(ModuleRouteListener::ORIGINAL_CONTROLLER, 'groovy');
+
+ self::assertEquals(
+ '/groovy/bar',
+ $this->helper->__invoke('default', ['action' => 'bar'], [], true)
+ );
+ }
+
+ public function testThatGivenControllerOverridesControllerFoundInModuleRouteListener(): void
+ {
+ $this->routeMatch->setMatchedRouteName('default');
+ $this->routeMatch->setParam(ModuleRouteListener::ORIGINAL_CONTROLLER, 'groovy');
+
+ self::assertEquals(
+ '/bing/bar',
+ $this->helper->__invoke('default', ['controller' => 'bing', 'action' => 'bar'], [], true)
+ );
+ }
+
+ public function testModuleNamespaceIsStrippedFromRouteParams(): void
+ {
+ $this->router->addRoute('replace', [
+ 'type' => Segment::class,
+ 'options' => [
+ 'route' => '/:controller/:action[/:' . ModuleRouteListener::MODULE_NAMESPACE . ']',
+ 'defaults' => [
+ 'controller' => 'default',
+ ],
+ ],
+ ]);
+
+ $this->routeMatch->setMatchedRouteName('replace');
+ $this->routeMatch->setParam('controller', 'groovy');
+ $this->routeMatch->setParam(ModuleRouteListener::MODULE_NAMESPACE, 'Muppets');
+
+ self::assertEquals(
+ '/groovy/bar',
+ $this->helper->__invoke('default', ['action' => 'bar'], [], true)
+ );
+ }
+}