diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..ac608c0
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,118 @@
+# Custom added rules
+/bin/
+
+# Created by https://www.toptal.com/developers/gitignore/api/composer,phpunit,phpstorm+all
+# Edit at https://www.toptal.com/developers/gitignore?templates=composer,phpunit,phpstorm+all
+
+### Composer ###
+composer.phar
+/vendor/
+
+# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
+# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
+# composer.lock
+
+### PhpStorm+all ###
+# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
+# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
+
+# User-specific stuff
+.idea/**/workspace.xml
+.idea/**/tasks.xml
+.idea/**/usage.statistics.xml
+.idea/**/dictionaries
+.idea/**/shelf
+
+# AWS User-specific
+.idea/**/aws.xml
+
+# Generated files
+.idea/**/contentModel.xml
+
+# Sensitive or high-churn files
+.idea/**/dataSources/
+.idea/**/dataSources.ids
+.idea/**/dataSources.local.xml
+.idea/**/sqlDataSources.xml
+.idea/**/dynamic.xml
+.idea/**/uiDesigner.xml
+.idea/**/dbnavigator.xml
+
+# Gradle
+.idea/**/gradle.xml
+.idea/**/libraries
+
+# Gradle and Maven with auto-import
+# When using Gradle or Maven with auto-import, you should exclude module files,
+# since they will be recreated, and may cause churn. Uncomment if using
+# auto-import.
+# .idea/artifacts
+# .idea/compiler.xml
+# .idea/jarRepositories.xml
+# .idea/modules.xml
+# .idea/*.iml
+# .idea/modules
+# *.iml
+# *.ipr
+
+# CMake
+cmake-build-*/
+
+# Mongo Explorer plugin
+.idea/**/mongoSettings.xml
+
+# File-based project format
+*.iws
+
+# IntelliJ
+out/
+
+# mpeltonen/sbt-idea plugin
+.idea_modules/
+
+# JIRA plugin
+atlassian-ide-plugin.xml
+
+# Cursive Clojure plugin
+.idea/replstate.xml
+
+# SonarLint plugin
+.idea/sonarlint/
+
+# Crashlytics plugin (for Android Studio and IntelliJ)
+com_crashlytics_export_strings.xml
+crashlytics.properties
+crashlytics-build.properties
+fabric.properties
+
+# Editor-based Rest Client
+.idea/httpRequests
+
+# Android studio 3.1+ serialized cache file
+.idea/caches/build_file_checksums.ser
+
+### PhpStorm+all Patch ###
+# Ignore everything but code style settings and run configurations
+# that are supposed to be shared within teams.
+
+.idea/*
+
+!.idea/codeStyles
+!.idea/runConfigurations
+
+### PHPUnit ###
+# Covers PHPUnit
+# Reference: https://phpunit.de/
+
+# Generated files
+.phpunit.result.cache
+.phpunit.cache
+
+# PHPUnit
+/app/phpunit.xml
+/phpunit.xml
+
+# Build data
+/build/
+
+# End of https://www.toptal.com/developers/gitignore/api/composer,phpunit,phpstorm+all
\ No newline at end of file
diff --git a/README.md b/README.md
index f94905d..100207f 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-
then(function ($v) { echo $v; });
- *
- * @param callable $generatorFn Generator function to wrap into a promise.
- *
- * @return Promise
- * @link https://github.com/petkaantonov/bluebird/blob/master/API.md#generators inspiration
- */
-final class Coroutine implements \PayNL\GuzzleHttp\Promise\PromiseInterface
-{
- /**
- * @var PromiseInterface|null
- */
- private $currentPromise;
- /**
- * @var Generator
- */
- private $generator;
- /**
- * @var Promise
- */
- private $result;
- public function __construct(callable $generatorFn)
- {
- $this->generator = $generatorFn();
- $this->result = new \PayNL\GuzzleHttp\Promise\Promise(function () {
- while (isset($this->currentPromise)) {
- $this->currentPromise->wait();
- }
- });
- $this->nextCoroutine($this->generator->current());
- }
- public function then(callable $onFulfilled = null, callable $onRejected = null)
- {
- return $this->result->then($onFulfilled, $onRejected);
- }
- public function otherwise(callable $onRejected)
- {
- return $this->result->otherwise($onRejected);
- }
- public function wait($unwrap = \true)
- {
- return $this->result->wait($unwrap);
- }
- public function getState()
- {
- return $this->result->getState();
- }
- public function resolve($value)
- {
- $this->result->resolve($value);
- }
- public function reject($reason)
- {
- $this->result->reject($reason);
- }
- public function cancel()
- {
- $this->currentPromise->cancel();
- $this->result->cancel();
- }
- private function nextCoroutine($yielded)
- {
- $this->currentPromise = promise_for($yielded)->then([$this, '_handleSuccess'], [$this, '_handleFailure']);
- }
- /**
- * @internal
- */
- public function _handleSuccess($value)
- {
- unset($this->currentPromise);
- try {
- $next = $this->generator->send($value);
- if ($this->generator->valid()) {
- $this->nextCoroutine($next);
- } else {
- $this->result->resolve($value);
- }
- } catch (\Exception $exception) {
- $this->result->reject($exception);
- } catch (\Throwable $throwable) {
- $this->result->reject($throwable);
- }
- }
- /**
- * @internal
- */
- public function _handleFailure($reason)
- {
- unset($this->currentPromise);
- try {
- $nextYield = $this->generator->throw(exception_for($reason));
- // The throw was caught, so keep iterating on the coroutine
- $this->nextCoroutine($nextYield);
- } catch (\Exception $exception) {
- $this->result->reject($exception);
- } catch (\Throwable $throwable) {
- $this->result->reject($throwable);
- }
- }
-}
diff --git a/build/promises/src/EachPromise.php b/build/promises/src/EachPromise.php
deleted file mode 100644
index 42d7f92..0000000
--- a/build/promises/src/EachPromise.php
+++ /dev/null
@@ -1,190 +0,0 @@
-iterable = iter_for($iterable);
- if (isset($config['concurrency'])) {
- $this->concurrency = $config['concurrency'];
- }
- if (isset($config['fulfilled'])) {
- $this->onFulfilled = $config['fulfilled'];
- }
- if (isset($config['rejected'])) {
- $this->onRejected = $config['rejected'];
- }
- }
- public function promise()
- {
- if ($this->aggregate) {
- return $this->aggregate;
- }
- try {
- $this->createPromise();
- $this->iterable->rewind();
- $this->refillPending();
- } catch (\Throwable $e) {
- $this->aggregate->reject($e);
- } catch (\Exception $e) {
- $this->aggregate->reject($e);
- }
- return $this->aggregate;
- }
- private function createPromise()
- {
- $this->mutex = \false;
- $this->aggregate = new \PayNL\GuzzleHttp\Promise\Promise(function () {
- \reset($this->pending);
- if (empty($this->pending) && !$this->iterable->valid()) {
- $this->aggregate->resolve(null);
- return;
- }
- // Consume a potentially fluctuating list of promises while
- // ensuring that indexes are maintained (precluding array_shift).
- while ($promise = \current($this->pending)) {
- \next($this->pending);
- $promise->wait();
- if ($this->aggregate->getState() !== \PayNL\GuzzleHttp\Promise\PromiseInterface::PENDING) {
- return;
- }
- }
- });
- // Clear the references when the promise is resolved.
- $clearFn = function () {
- $this->iterable = $this->concurrency = $this->pending = null;
- $this->onFulfilled = $this->onRejected = null;
- };
- $this->aggregate->then($clearFn, $clearFn);
- }
- private function refillPending()
- {
- if (!$this->concurrency) {
- // Add all pending promises.
- while ($this->addPending() && $this->advanceIterator()) {
- }
- return;
- }
- // Add only up to N pending promises.
- $concurrency = \is_callable($this->concurrency) ? \call_user_func($this->concurrency, \count($this->pending)) : $this->concurrency;
- $concurrency = \max($concurrency - \count($this->pending), 0);
- // Concurrency may be set to 0 to disallow new promises.
- if (!$concurrency) {
- return;
- }
- // Add the first pending promise.
- $this->addPending();
- // Note this is special handling for concurrency=1 so that we do
- // not advance the iterator after adding the first promise. This
- // helps work around issues with generators that might not have the
- // next value to yield until promise callbacks are called.
- while (--$concurrency && $this->advanceIterator() && $this->addPending()) {
- }
- }
- private function addPending()
- {
- if (!$this->iterable || !$this->iterable->valid()) {
- return \false;
- }
- $promise = promise_for($this->iterable->current());
- $idx = $this->iterable->key();
- $this->pending[$idx] = $promise->then(function ($value) use($idx) {
- if ($this->onFulfilled) {
- \call_user_func($this->onFulfilled, $value, $idx, $this->aggregate);
- }
- $this->step($idx);
- }, function ($reason) use($idx) {
- if ($this->onRejected) {
- \call_user_func($this->onRejected, $reason, $idx, $this->aggregate);
- }
- $this->step($idx);
- });
- return \true;
- }
- private function advanceIterator()
- {
- // Place a lock on the iterator so that we ensure to not recurse,
- // preventing fatal generator errors.
- if ($this->mutex) {
- return \false;
- }
- $this->mutex = \true;
- try {
- $this->iterable->next();
- $this->mutex = \false;
- return \true;
- } catch (\Throwable $e) {
- $this->aggregate->reject($e);
- $this->mutex = \false;
- return \false;
- } catch (\Exception $e) {
- $this->aggregate->reject($e);
- $this->mutex = \false;
- return \false;
- }
- }
- private function step($idx)
- {
- // If the promise was already resolved, then ignore this step.
- if ($this->aggregate->getState() !== \PayNL\GuzzleHttp\Promise\PromiseInterface::PENDING) {
- return;
- }
- unset($this->pending[$idx]);
- // Only refill pending promises if we are not locked, preventing the
- // EachPromise to recursively invoke the provided iterator, which
- // cause a fatal error: "Cannot resume an already running generator"
- if ($this->advanceIterator() && !$this->checkIfFinished()) {
- // Add more pending promises if possible.
- $this->refillPending();
- }
- }
- private function checkIfFinished()
- {
- if (!$this->pending && !$this->iterable->valid()) {
- // Resolve the promise if there's nothing left to do.
- $this->aggregate->resolve(null);
- return \true;
- }
- return \false;
- }
-}
diff --git a/build/promises/src/FulfilledPromise.php b/build/promises/src/FulfilledPromise.php
deleted file mode 100644
index 0edaa6c..0000000
--- a/build/promises/src/FulfilledPromise.php
+++ /dev/null
@@ -1,69 +0,0 @@
-value = $value;
- }
- public function then(callable $onFulfilled = null, callable $onRejected = null)
- {
- // Return itself if there is no onFulfilled function.
- if (!$onFulfilled) {
- return $this;
- }
- $queue = queue();
- $p = new \PayNL\GuzzleHttp\Promise\Promise([$queue, 'run']);
- $value = $this->value;
- $queue->add(static function () use($p, $value, $onFulfilled) {
- if ($p->getState() === self::PENDING) {
- try {
- $p->resolve($onFulfilled($value));
- } catch (\Throwable $e) {
- $p->reject($e);
- } catch (\Exception $e) {
- $p->reject($e);
- }
- }
- });
- return $p;
- }
- public function otherwise(callable $onRejected)
- {
- return $this->then(null, $onRejected);
- }
- public function wait($unwrap = \true, $defaultDelivery = null)
- {
- return $unwrap ? $this->value : null;
- }
- public function getState()
- {
- return self::FULFILLED;
- }
- public function resolve($value)
- {
- if ($value !== $this->value) {
- throw new \LogicException("Cannot resolve a fulfilled promise");
- }
- }
- public function reject($reason)
- {
- throw new \LogicException("Cannot reject a fulfilled promise");
- }
- public function cancel()
- {
- // pass
- }
-}
diff --git a/build/promises/src/Promise.php b/build/promises/src/Promise.php
deleted file mode 100644
index f92951a..0000000
--- a/build/promises/src/Promise.php
+++ /dev/null
@@ -1,231 +0,0 @@
-waitFn = $waitFn;
- $this->cancelFn = $cancelFn;
- }
- public function then(callable $onFulfilled = null, callable $onRejected = null)
- {
- if ($this->state === self::PENDING) {
- $p = new \PayNL\GuzzleHttp\Promise\Promise(null, [$this, 'cancel']);
- $this->handlers[] = [$p, $onFulfilled, $onRejected];
- $p->waitList = $this->waitList;
- $p->waitList[] = $this;
- return $p;
- }
- // Return a fulfilled promise and immediately invoke any callbacks.
- if ($this->state === self::FULFILLED) {
- return $onFulfilled ? promise_for($this->result)->then($onFulfilled) : promise_for($this->result);
- }
- // It's either cancelled or rejected, so return a rejected promise
- // and immediately invoke any callbacks.
- $rejection = rejection_for($this->result);
- return $onRejected ? $rejection->then(null, $onRejected) : $rejection;
- }
- public function otherwise(callable $onRejected)
- {
- return $this->then(null, $onRejected);
- }
- public function wait($unwrap = \true)
- {
- $this->waitIfPending();
- $inner = $this->result instanceof \PayNL\GuzzleHttp\Promise\PromiseInterface ? $this->result->wait($unwrap) : $this->result;
- if ($unwrap) {
- if ($this->result instanceof \PayNL\GuzzleHttp\Promise\PromiseInterface || $this->state === self::FULFILLED) {
- return $inner;
- } else {
- // It's rejected so "unwrap" and throw an exception.
- throw exception_for($inner);
- }
- }
- }
- public function getState()
- {
- return $this->state;
- }
- public function cancel()
- {
- if ($this->state !== self::PENDING) {
- return;
- }
- $this->waitFn = $this->waitList = null;
- if ($this->cancelFn) {
- $fn = $this->cancelFn;
- $this->cancelFn = null;
- try {
- $fn();
- } catch (\Throwable $e) {
- $this->reject($e);
- } catch (\Exception $e) {
- $this->reject($e);
- }
- }
- // Reject the promise only if it wasn't rejected in a then callback.
- if ($this->state === self::PENDING) {
- $this->reject(new \PayNL\GuzzleHttp\Promise\CancellationException('Promise has been cancelled'));
- }
- }
- public function resolve($value)
- {
- $this->settle(self::FULFILLED, $value);
- }
- public function reject($reason)
- {
- $this->settle(self::REJECTED, $reason);
- }
- private function settle($state, $value)
- {
- if ($this->state !== self::PENDING) {
- // Ignore calls with the same resolution.
- if ($state === $this->state && $value === $this->result) {
- return;
- }
- throw $this->state === $state ? new \LogicException("The promise is already {$state}.") : new \LogicException("Cannot change a {$this->state} promise to {$state}");
- }
- if ($value === $this) {
- throw new \LogicException('Cannot fulfill or reject a promise with itself');
- }
- // Clear out the state of the promise but stash the handlers.
- $this->state = $state;
- $this->result = $value;
- $handlers = $this->handlers;
- $this->handlers = null;
- $this->waitList = $this->waitFn = null;
- $this->cancelFn = null;
- if (!$handlers) {
- return;
- }
- // If the value was not a settled promise or a thenable, then resolve
- // it in the task queue using the correct ID.
- if (!\method_exists($value, 'then')) {
- $id = $state === self::FULFILLED ? 1 : 2;
- // It's a success, so resolve the handlers in the queue.
- queue()->add(static function () use($id, $value, $handlers) {
- foreach ($handlers as $handler) {
- self::callHandler($id, $value, $handler);
- }
- });
- } elseif ($value instanceof \PayNL\GuzzleHttp\Promise\Promise && $value->getState() === self::PENDING) {
- // We can just merge our handlers onto the next promise.
- $value->handlers = \array_merge($value->handlers, $handlers);
- } else {
- // Resolve the handlers when the forwarded promise is resolved.
- $value->then(static function ($value) use($handlers) {
- foreach ($handlers as $handler) {
- self::callHandler(1, $value, $handler);
- }
- }, static function ($reason) use($handlers) {
- foreach ($handlers as $handler) {
- self::callHandler(2, $reason, $handler);
- }
- });
- }
- }
- /**
- * Call a stack of handlers using a specific callback index and value.
- *
- * @param int $index 1 (resolve) or 2 (reject).
- * @param mixed $value Value to pass to the callback.
- * @param array $handler Array of handler data (promise and callbacks).
- *
- * @return array Returns the next group to resolve.
- */
- private static function callHandler($index, $value, array $handler)
- {
- /** @var PromiseInterface $promise */
- $promise = $handler[0];
- // The promise may have been cancelled or resolved before placing
- // this thunk in the queue.
- if ($promise->getState() !== self::PENDING) {
- return;
- }
- try {
- if (isset($handler[$index])) {
- $promise->resolve($handler[$index]($value));
- } elseif ($index === 1) {
- // Forward resolution values as-is.
- $promise->resolve($value);
- } else {
- // Forward rejections down the chain.
- $promise->reject($value);
- }
- } catch (\Throwable $reason) {
- $promise->reject($reason);
- } catch (\Exception $reason) {
- $promise->reject($reason);
- }
- }
- private function waitIfPending()
- {
- if ($this->state !== self::PENDING) {
- return;
- } elseif ($this->waitFn) {
- $this->invokeWaitFn();
- } elseif ($this->waitList) {
- $this->invokeWaitList();
- } else {
- // If there's not wait function, then reject the promise.
- $this->reject('Cannot wait on a promise that has ' . 'no internal wait function. You must provide a wait ' . 'function when constructing the promise to be able to ' . 'wait on a promise.');
- }
- queue()->run();
- if ($this->state === self::PENDING) {
- $this->reject('Invoking the wait callback did not resolve the promise');
- }
- }
- private function invokeWaitFn()
- {
- try {
- $wfn = $this->waitFn;
- $this->waitFn = null;
- $wfn(\true);
- } catch (\Exception $reason) {
- if ($this->state === self::PENDING) {
- // The promise has not been resolved yet, so reject the promise
- // with the exception.
- $this->reject($reason);
- } else {
- // The promise was already resolved, so there's a problem in
- // the application.
- throw $reason;
- }
- }
- }
- private function invokeWaitList()
- {
- $waitList = $this->waitList;
- $this->waitList = null;
- foreach ($waitList as $result) {
- while (\true) {
- $result->waitIfPending();
- if ($result->result instanceof \PayNL\GuzzleHttp\Promise\Promise) {
- $result = $result->result;
- } else {
- if ($result->result instanceof \PayNL\GuzzleHttp\Promise\PromiseInterface) {
- $result->result->wait(\false);
- }
- break;
- }
- }
- }
- }
-}
diff --git a/build/promises/src/PromiseInterface.php b/build/promises/src/PromiseInterface.php
deleted file mode 100644
index 9e8b2bd..0000000
--- a/build/promises/src/PromiseInterface.php
+++ /dev/null
@@ -1,84 +0,0 @@
-reason = $reason;
- }
- public function then(callable $onFulfilled = null, callable $onRejected = null)
- {
- // If there's no onRejected callback then just return self.
- if (!$onRejected) {
- return $this;
- }
- $queue = queue();
- $reason = $this->reason;
- $p = new \PayNL\GuzzleHttp\Promise\Promise([$queue, 'run']);
- $queue->add(static function () use($p, $reason, $onRejected) {
- if ($p->getState() === self::PENDING) {
- try {
- // Return a resolved promise if onRejected does not throw.
- $p->resolve($onRejected($reason));
- } catch (\Throwable $e) {
- // onRejected threw, so return a rejected promise.
- $p->reject($e);
- } catch (\Exception $e) {
- // onRejected threw, so return a rejected promise.
- $p->reject($e);
- }
- }
- });
- return $p;
- }
- public function otherwise(callable $onRejected)
- {
- return $this->then(null, $onRejected);
- }
- public function wait($unwrap = \true, $defaultDelivery = null)
- {
- if ($unwrap) {
- throw exception_for($this->reason);
- }
- }
- public function getState()
- {
- return self::REJECTED;
- }
- public function resolve($value)
- {
- throw new \LogicException("Cannot resolve a rejected promise");
- }
- public function reject($reason)
- {
- if ($reason !== $this->reason) {
- throw new \LogicException("Cannot reject a rejected promise");
- }
- }
- public function cancel()
- {
- // pass
- }
-}
diff --git a/build/promises/src/RejectionException.php b/build/promises/src/RejectionException.php
deleted file mode 100644
index 3b3446a..0000000
--- a/build/promises/src/RejectionException.php
+++ /dev/null
@@ -1,40 +0,0 @@
-reason = $reason;
- $message = 'The promise was rejected';
- if ($description) {
- $message .= ' with reason: ' . $description;
- } elseif (\is_string($reason) || \is_object($reason) && \method_exists($reason, '__toString')) {
- $message .= ' with reason: ' . $this->reason;
- } elseif ($reason instanceof \JsonSerializable) {
- $message .= ' with reason: ' . \json_encode($this->reason, \JSON_PRETTY_PRINT);
- }
- parent::__construct($message);
- }
- /**
- * Returns the rejection reason.
- *
- * @return mixed
- */
- public function getReason()
- {
- return $this->reason;
- }
-}
diff --git a/build/promises/src/TaskQueue.php b/build/promises/src/TaskQueue.php
deleted file mode 100644
index fedee94..0000000
--- a/build/promises/src/TaskQueue.php
+++ /dev/null
@@ -1,62 +0,0 @@
-run();
- */
-class TaskQueue implements \PayNL\GuzzleHttp\Promise\TaskQueueInterface
-{
- private $enableShutdown = \true;
- private $queue = [];
- public function __construct($withShutdown = \true)
- {
- if ($withShutdown) {
- \register_shutdown_function(function () {
- if ($this->enableShutdown) {
- // Only run the tasks if an E_ERROR didn't occur.
- $err = \error_get_last();
- if (!$err || $err['type'] ^ \E_ERROR) {
- $this->run();
- }
- }
- });
- }
- }
- public function isEmpty()
- {
- return !$this->queue;
- }
- public function add(callable $task)
- {
- $this->queue[] = $task;
- }
- public function run()
- {
- /** @var callable $task */
- while ($task = \array_shift($this->queue)) {
- $task();
- }
- }
- /**
- * The task queue will be run and exhausted by default when the process
- * exits IFF the exit is not the result of a PHP E_ERROR error.
- *
- * You can disable running the automatic shutdown of the queue by calling
- * this function. If you disable the task queue shutdown process, then you
- * MUST either run the task queue (as a result of running your event loop
- * or manually using the run() method) or wait on each outstanding promise.
- *
- * Note: This shutdown will occur before any destructors are triggered.
- */
- public function disableShutdown()
- {
- $this->enableShutdown = \false;
- }
-}
diff --git a/build/promises/src/TaskQueueInterface.php b/build/promises/src/TaskQueueInterface.php
deleted file mode 100644
index bcfc11f..0000000
--- a/build/promises/src/TaskQueueInterface.php
+++ /dev/null
@@ -1,24 +0,0 @@
-
- * while ($eventLoop->isRunning()) {
- * GuzzleHttp\Promise\queue()->run();
- * }
- *
- *
- * @param TaskQueueInterface $assign Optionally specify a new queue instance.
- *
- * @return TaskQueueInterface
- */
-function queue(\PayNL\GuzzleHttp\Promise\TaskQueueInterface $assign = null)
-{
- static $queue;
- if ($assign) {
- $queue = $assign;
- } elseif (!$queue) {
- $queue = new \PayNL\GuzzleHttp\Promise\TaskQueue();
- }
- return $queue;
-}
-/**
- * Adds a function to run in the task queue when it is next `run()` and returns
- * a promise that is fulfilled or rejected with the result.
- *
- * @param callable $task Task function to run.
- *
- * @return PromiseInterface
- */
-function task(callable $task)
-{
- $queue = queue();
- $promise = new \PayNL\GuzzleHttp\Promise\Promise([$queue, 'run']);
- $queue->add(function () use($task, $promise) {
- try {
- $promise->resolve($task());
- } catch (\Throwable $e) {
- $promise->reject($e);
- } catch (\Exception $e) {
- $promise->reject($e);
- }
- });
- return $promise;
-}
-/**
- * Creates a promise for a value if the value is not a promise.
- *
- * @param mixed $value Promise or value.
- *
- * @return PromiseInterface
- */
-function promise_for($value)
-{
- if ($value instanceof \PayNL\GuzzleHttp\Promise\PromiseInterface) {
- return $value;
- }
- // Return a Guzzle promise that shadows the given promise.
- if (\method_exists($value, 'then')) {
- $wfn = \method_exists($value, 'wait') ? [$value, 'wait'] : null;
- $cfn = \method_exists($value, 'cancel') ? [$value, 'cancel'] : null;
- $promise = new \PayNL\GuzzleHttp\Promise\Promise($wfn, $cfn);
- $value->then([$promise, 'resolve'], [$promise, 'reject']);
- return $promise;
- }
- return new \PayNL\GuzzleHttp\Promise\FulfilledPromise($value);
-}
-/**
- * Creates a rejected promise for a reason if the reason is not a promise. If
- * the provided reason is a promise, then it is returned as-is.
- *
- * @param mixed $reason Promise or reason.
- *
- * @return PromiseInterface
- */
-function rejection_for($reason)
-{
- if ($reason instanceof \PayNL\GuzzleHttp\Promise\PromiseInterface) {
- return $reason;
- }
- return new \PayNL\GuzzleHttp\Promise\RejectedPromise($reason);
-}
-/**
- * Create an exception for a rejected promise value.
- *
- * @param mixed $reason
- *
- * @return \Exception|\Throwable
- */
-function exception_for($reason)
-{
- return $reason instanceof \Exception || $reason instanceof \Throwable ? $reason : new \PayNL\GuzzleHttp\Promise\RejectionException($reason);
-}
-/**
- * Returns an iterator for the given value.
- *
- * @param mixed $value
- *
- * @return \Iterator
- */
-function iter_for($value)
-{
- if ($value instanceof \Iterator) {
- return $value;
- } elseif (\is_array($value)) {
- return new \ArrayIterator($value);
- } else {
- return new \ArrayIterator([$value]);
- }
-}
-/**
- * Synchronously waits on a promise to resolve and returns an inspection state
- * array.
- *
- * Returns a state associative array containing a "state" key mapping to a
- * valid promise state. If the state of the promise is "fulfilled", the array
- * will contain a "value" key mapping to the fulfilled value of the promise. If
- * the promise is rejected, the array will contain a "reason" key mapping to
- * the rejection reason of the promise.
- *
- * @param PromiseInterface $promise Promise or value.
- *
- * @return array
- */
-function inspect(\PayNL\GuzzleHttp\Promise\PromiseInterface $promise)
-{
- try {
- return ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $promise->wait()];
- } catch (\PayNL\GuzzleHttp\Promise\RejectionException $e) {
- return ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e->getReason()];
- } catch (\Throwable $e) {
- return ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e];
- } catch (\Exception $e) {
- return ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e];
- }
-}
-/**
- * Waits on all of the provided promises, but does not unwrap rejected promises
- * as thrown exception.
- *
- * Returns an array of inspection state arrays.
- *
- * @param PromiseInterface[] $promises Traversable of promises to wait upon.
- *
- * @return array
- * @see GuzzleHttp\Promise\inspect for the inspection state array format.
- */
-function inspect_all($promises)
-{
- $results = [];
- foreach ($promises as $key => $promise) {
- $results[$key] = inspect($promise);
- }
- return $results;
-}
-/**
- * Waits on all of the provided promises and returns the fulfilled values.
- *
- * Returns an array that contains the value of each promise (in the same order
- * the promises were provided). An exception is thrown if any of the promises
- * are rejected.
- *
- * @param mixed $promises Iterable of PromiseInterface objects to wait on.
- *
- * @return array
- * @throws \Exception on error
- * @throws \Throwable on error in PHP >=7
- */
-function unwrap($promises)
-{
- $results = [];
- foreach ($promises as $key => $promise) {
- $results[$key] = $promise->wait();
- }
- return $results;
-}
-/**
- * Given an array of promises, return a promise that is fulfilled when all the
- * items in the array are fulfilled.
- *
- * The promise's fulfillment value is an array with fulfillment values at
- * respective positions to the original array. If any promise in the array
- * rejects, the returned promise is rejected with the rejection reason.
- *
- * @param mixed $promises Promises or values.
- *
- * @return PromiseInterface
- */
-function all($promises)
-{
- $results = [];
- return \each($promises, function ($value, $idx) use(&$results) {
- $results[$idx] = $value;
- }, function ($reason, $idx, \PayNL\GuzzleHttp\Promise\Promise $aggregate) {
- $aggregate->reject($reason);
- })->then(function () use(&$results) {
- \ksort($results);
- return $results;
- });
-}
-/**
- * Initiate a competitive race between multiple promises or values (values will
- * become immediately fulfilled promises).
- *
- * When count amount of promises have been fulfilled, the returned promise is
- * fulfilled with an array that contains the fulfillment values of the winners
- * in order of resolution.
- *
- * This prommise is rejected with a {@see GuzzleHttp\Promise\AggregateException}
- * if the number of fulfilled promises is less than the desired $count.
- *
- * @param int $count Total number of promises.
- * @param mixed $promises Promises or values.
- *
- * @return PromiseInterface
- */
-function some($count, $promises)
-{
- $results = [];
- $rejections = [];
- return \each($promises, function ($value, $idx, \PayNL\GuzzleHttp\Promise\PromiseInterface $p) use(&$results, $count) {
- if ($p->getState() !== \PayNL\GuzzleHttp\Promise\PromiseInterface::PENDING) {
- return;
- }
- $results[$idx] = $value;
- if (\count($results) >= $count) {
- $p->resolve(null);
- }
- }, function ($reason) use(&$rejections) {
- $rejections[] = $reason;
- })->then(function () use(&$results, &$rejections, $count) {
- if (\count($results) !== $count) {
- throw new \PayNL\GuzzleHttp\Promise\AggregateException('Not enough promises to fulfill count', $rejections);
- }
- \ksort($results);
- return \array_values($results);
- });
-}
-/**
- * Like some(), with 1 as count. However, if the promise fulfills, the
- * fulfillment value is not an array of 1 but the value directly.
- *
- * @param mixed $promises Promises or values.
- *
- * @return PromiseInterface
- */
-function any($promises)
-{
- return some(1, $promises)->then(function ($values) {
- return $values[0];
- });
-}
-/**
- * Returns a promise that is fulfilled when all of the provided promises have
- * been fulfilled or rejected.
- *
- * The returned promise is fulfilled with an array of inspection state arrays.
- *
- * @param mixed $promises Promises or values.
- *
- * @return PromiseInterface
- * @see GuzzleHttp\Promise\inspect for the inspection state array format.
- */
-function settle($promises)
-{
- $results = [];
- return \each($promises, function ($value, $idx) use(&$results) {
- $results[$idx] = ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $value];
- }, function ($reason, $idx) use(&$results) {
- $results[$idx] = ['state' => \PayNL\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $reason];
- })->then(function () use(&$results) {
- \ksort($results);
- return $results;
- });
-}
-/**
- * Given an iterator that yields promises or values, returns a promise that is
- * fulfilled with a null value when the iterator has been consumed or the
- * aggregate promise has been fulfilled or rejected.
- *
- * $onFulfilled is a function that accepts the fulfilled value, iterator
- * index, and the aggregate promise. The callback can invoke any necessary side
- * effects and choose to resolve or reject the aggregate promise if needed.
- *
- * $onRejected is a function that accepts the rejection reason, iterator
- * index, and the aggregate promise. The callback can invoke any necessary side
- * effects and choose to resolve or reject the aggregate promise if needed.
- *
- * @param mixed $iterable Iterator or array to iterate over.
- * @param callable $onFulfilled
- * @param callable $onRejected
- *
- * @return PromiseInterface
- */
-function each($iterable, callable $onFulfilled = null, callable $onRejected = null)
-{
- return (new \PayNL\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected]))->promise();
-}
-/**
- * Like each, but only allows a certain number of outstanding promises at any
- * given time.
- *
- * $concurrency may be an integer or a function that accepts the number of
- * pending promises and returns a numeric concurrency limit value to allow for
- * dynamic a concurrency size.
- *
- * @param mixed $iterable
- * @param int|callable $concurrency
- * @param callable $onFulfilled
- * @param callable $onRejected
- *
- * @return PromiseInterface
- */
-function each_limit($iterable, $concurrency, callable $onFulfilled = null, callable $onRejected = null)
-{
- return (new \PayNL\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected, 'concurrency' => $concurrency]))->promise();
-}
-/**
- * Like each_limit, but ensures that no promise in the given $iterable argument
- * is rejected. If any promise is rejected, then the aggregate promise is
- * rejected with the encountered rejection.
- *
- * @param mixed $iterable
- * @param int|callable $concurrency
- * @param callable $onFulfilled
- *
- * @return PromiseInterface
- */
-function each_limit_all($iterable, $concurrency, callable $onFulfilled = null)
-{
- return each_limit($iterable, $concurrency, $onFulfilled, function ($reason, $idx, \PayNL\GuzzleHttp\Promise\PromiseInterface $aggregate) {
- $aggregate->reject($reason);
- });
-}
-/**
- * Returns true if a promise is fulfilled.
- *
- * @param PromiseInterface $promise
- *
- * @return bool
- */
-function is_fulfilled(\PayNL\GuzzleHttp\Promise\PromiseInterface $promise)
-{
- return $promise->getState() === \PayNL\GuzzleHttp\Promise\PromiseInterface::FULFILLED;
-}
-/**
- * Returns true if a promise is rejected.
- *
- * @param PromiseInterface $promise
- *
- * @return bool
- */
-function is_rejected(\PayNL\GuzzleHttp\Promise\PromiseInterface $promise)
-{
- return $promise->getState() === \PayNL\GuzzleHttp\Promise\PromiseInterface::REJECTED;
-}
-/**
- * Returns true if a promise is fulfilled or rejected.
- *
- * @param PromiseInterface $promise
- *
- * @return bool
- */
-function is_settled(\PayNL\GuzzleHttp\Promise\PromiseInterface $promise)
-{
- return $promise->getState() !== \PayNL\GuzzleHttp\Promise\PromiseInterface::PENDING;
-}
-/**
- * @see Coroutine
- *
- * @param callable $generatorFn
- *
- * @return PromiseInterface
- */
-function coroutine(callable $generatorFn)
-{
- return new \PayNL\GuzzleHttp\Promise\Coroutine($generatorFn);
-}
diff --git a/build/promises/src/functions_include.php b/build/promises/src/functions_include.php
deleted file mode 100644
index 97271a3..0000000
--- a/build/promises/src/functions_include.php
+++ /dev/null
@@ -1,8 +0,0 @@
-addStream($stream);
- }
- }
- public function __toString()
- {
- try {
- $this->rewind();
- return $this->getContents();
- } catch (\Exception $e) {
- return '';
- }
- }
- /**
- * Add a stream to the AppendStream
- *
- * @param StreamInterface $stream Stream to append. Must be readable.
- *
- * @throws \InvalidArgumentException if the stream is not readable
- */
- public function addStream(\Psr\Http\Message\StreamInterface $stream)
- {
- if (!$stream->isReadable()) {
- throw new \InvalidArgumentException('Each stream must be readable');
- }
- // The stream is only seekable if all streams are seekable
- if (!$stream->isSeekable()) {
- $this->seekable = \false;
- }
- $this->streams[] = $stream;
- }
- public function getContents()
- {
- return copy_to_string($this);
- }
- /**
- * Closes each attached stream.
- *
- * {@inheritdoc}
- */
- public function close()
- {
- $this->pos = $this->current = 0;
- $this->seekable = \true;
- foreach ($this->streams as $stream) {
- $stream->close();
- }
- $this->streams = [];
- }
- /**
- * Detaches each attached stream.
- *
- * Returns null as it's not clear which underlying stream resource to return.
- *
- * {@inheritdoc}
- */
- public function detach()
- {
- $this->pos = $this->current = 0;
- $this->seekable = \true;
- foreach ($this->streams as $stream) {
- $stream->detach();
- }
- $this->streams = [];
- }
- public function tell()
- {
- return $this->pos;
- }
- /**
- * Tries to calculate the size by adding the size of each stream.
- *
- * If any of the streams do not return a valid number, then the size of the
- * append stream cannot be determined and null is returned.
- *
- * {@inheritdoc}
- */
- public function getSize()
- {
- $size = 0;
- foreach ($this->streams as $stream) {
- $s = $stream->getSize();
- if ($s === null) {
- return null;
- }
- $size += $s;
- }
- return $size;
- }
- public function eof()
- {
- return !$this->streams || $this->current >= \count($this->streams) - 1 && $this->streams[$this->current]->eof();
- }
- public function rewind()
- {
- $this->seek(0);
- }
- /**
- * Attempts to seek to the given position. Only supports SEEK_SET.
- *
- * {@inheritdoc}
- */
- public function seek($offset, $whence = \SEEK_SET)
- {
- if (!$this->seekable) {
- throw new \RuntimeException('This AppendStream is not seekable');
- } elseif ($whence !== \SEEK_SET) {
- throw new \RuntimeException('The AppendStream can only seek with SEEK_SET');
- }
- $this->pos = $this->current = 0;
- // Rewind each stream
- foreach ($this->streams as $i => $stream) {
- try {
- $stream->rewind();
- } catch (\Exception $e) {
- throw new \RuntimeException('Unable to seek stream ' . $i . ' of the AppendStream', 0, $e);
- }
- }
- // Seek to the actual position by reading from each stream
- while ($this->pos < $offset && !$this->eof()) {
- $result = $this->read(\min(8096, $offset - $this->pos));
- if ($result === '') {
- break;
- }
- }
- }
- /**
- * Reads from all of the appended streams until the length is met or EOF.
- *
- * {@inheritdoc}
- */
- public function read($length)
- {
- $buffer = '';
- $total = \count($this->streams) - 1;
- $remaining = $length;
- $progressToNext = \false;
- while ($remaining > 0) {
- // Progress to the next stream if needed.
- if ($progressToNext || $this->streams[$this->current]->eof()) {
- $progressToNext = \false;
- if ($this->current === $total) {
- break;
- }
- $this->current++;
- }
- $result = $this->streams[$this->current]->read($remaining);
- // Using a loose comparison here to match on '', false, and null
- if ($result == null) {
- $progressToNext = \true;
- continue;
- }
- $buffer .= $result;
- $remaining = $length - \strlen($buffer);
- }
- $this->pos += \strlen($buffer);
- return $buffer;
- }
- public function isReadable()
- {
- return \true;
- }
- public function isWritable()
- {
- return \false;
- }
- public function isSeekable()
- {
- return $this->seekable;
- }
- public function write($string)
- {
- throw new \RuntimeException('Cannot write to an AppendStream');
- }
- public function getMetadata($key = null)
- {
- return $key ? null : [];
- }
-}
diff --git a/build/psr7/src/BufferStream.php b/build/psr7/src/BufferStream.php
deleted file mode 100644
index 2154677..0000000
--- a/build/psr7/src/BufferStream.php
+++ /dev/null
@@ -1,114 +0,0 @@
-hwm = $hwm;
- }
- public function __toString()
- {
- return $this->getContents();
- }
- public function getContents()
- {
- $buffer = $this->buffer;
- $this->buffer = '';
- return $buffer;
- }
- public function close()
- {
- $this->buffer = '';
- }
- public function detach()
- {
- $this->close();
- }
- public function getSize()
- {
- return \strlen($this->buffer);
- }
- public function isReadable()
- {
- return \true;
- }
- public function isWritable()
- {
- return \true;
- }
- public function isSeekable()
- {
- return \false;
- }
- public function rewind()
- {
- $this->seek(0);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- throw new \RuntimeException('Cannot seek a BufferStream');
- }
- public function eof()
- {
- return \strlen($this->buffer) === 0;
- }
- public function tell()
- {
- throw new \RuntimeException('Cannot determine the position of a BufferStream');
- }
- /**
- * Reads data from the buffer.
- */
- public function read($length)
- {
- $currentLength = \strlen($this->buffer);
- if ($length >= $currentLength) {
- // No need to slice the buffer because we don't have enough data.
- $result = $this->buffer;
- $this->buffer = '';
- } else {
- // Slice up the result to provide a subset of the buffer.
- $result = \substr($this->buffer, 0, $length);
- $this->buffer = \substr($this->buffer, $length);
- }
- return $result;
- }
- /**
- * Writes data to the buffer.
- */
- public function write($string)
- {
- $this->buffer .= $string;
- if (\strlen($this->buffer) >= $this->hwm) {
- return \false;
- }
- return \strlen($string);
- }
- public function getMetadata($key = null)
- {
- if ($key == 'hwm') {
- return $this->hwm;
- }
- return $key ? null : [];
- }
-}
diff --git a/build/psr7/src/CachingStream.php b/build/psr7/src/CachingStream.php
deleted file mode 100644
index 4b643b7..0000000
--- a/build/psr7/src/CachingStream.php
+++ /dev/null
@@ -1,115 +0,0 @@
-remoteStream = $stream;
- $this->stream = $target ?: new \PayNL\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+'));
- }
- public function getSize()
- {
- return \max($this->stream->getSize(), $this->remoteStream->getSize());
- }
- public function rewind()
- {
- $this->seek(0);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- if ($whence == \SEEK_SET) {
- $byte = $offset;
- } elseif ($whence == \SEEK_CUR) {
- $byte = $offset + $this->tell();
- } elseif ($whence == \SEEK_END) {
- $size = $this->remoteStream->getSize();
- if ($size === null) {
- $size = $this->cacheEntireStream();
- }
- $byte = $size + $offset;
- } else {
- throw new \InvalidArgumentException('Invalid whence');
- }
- $diff = $byte - $this->stream->getSize();
- if ($diff > 0) {
- // Read the remoteStream until we have read in at least the amount
- // of bytes requested, or we reach the end of the file.
- while ($diff > 0 && !$this->remoteStream->eof()) {
- $this->read($diff);
- $diff = $byte - $this->stream->getSize();
- }
- } else {
- // We can just do a normal seek since we've already seen this byte.
- $this->stream->seek($byte);
- }
- }
- public function read($length)
- {
- // Perform a regular read on any previously read data from the buffer
- $data = $this->stream->read($length);
- $remaining = $length - \strlen($data);
- // More data was requested so read from the remote stream
- if ($remaining) {
- // If data was written to the buffer in a position that would have
- // been filled from the remote stream, then we must skip bytes on
- // the remote stream to emulate overwriting bytes from that
- // position. This mimics the behavior of other PHP stream wrappers.
- $remoteData = $this->remoteStream->read($remaining + $this->skipReadBytes);
- if ($this->skipReadBytes) {
- $len = \strlen($remoteData);
- $remoteData = \substr($remoteData, $this->skipReadBytes);
- $this->skipReadBytes = \max(0, $this->skipReadBytes - $len);
- }
- $data .= $remoteData;
- $this->stream->write($remoteData);
- }
- return $data;
- }
- public function write($string)
- {
- // When appending to the end of the currently read stream, you'll want
- // to skip bytes from being read from the remote stream to emulate
- // other stream wrappers. Basically replacing bytes of data of a fixed
- // length.
- $overflow = \strlen($string) + $this->tell() - $this->remoteStream->tell();
- if ($overflow > 0) {
- $this->skipReadBytes += $overflow;
- }
- return $this->stream->write($string);
- }
- public function eof()
- {
- return $this->stream->eof() && $this->remoteStream->eof();
- }
- /**
- * Close both the remote stream and buffer stream
- */
- public function close()
- {
- $this->remoteStream->close() && $this->stream->close();
- }
- private function cacheEntireStream()
- {
- $target = new \PayNL\GuzzleHttp\Psr7\FnStream(['write' => 'strlen']);
- copy_to_stream($this, $target);
- return $this->tell();
- }
-}
diff --git a/build/psr7/src/DroppingStream.php b/build/psr7/src/DroppingStream.php
deleted file mode 100644
index e942f41..0000000
--- a/build/psr7/src/DroppingStream.php
+++ /dev/null
@@ -1,36 +0,0 @@
-stream = $stream;
- $this->maxLength = $maxLength;
- }
- public function write($string)
- {
- $diff = $this->maxLength - $this->stream->getSize();
- // Begin returning 0 when the underlying stream is too large.
- if ($diff <= 0) {
- return 0;
- }
- // Write the stream or a subset of the stream if needed.
- if (\strlen($string) < $diff) {
- return $this->stream->write($string);
- }
- return $this->stream->write(\substr($string, 0, $diff));
- }
-}
diff --git a/build/psr7/src/FnStream.php b/build/psr7/src/FnStream.php
deleted file mode 100644
index 3095f70..0000000
--- a/build/psr7/src/FnStream.php
+++ /dev/null
@@ -1,132 +0,0 @@
-methods = $methods;
- // Create the functions on the class
- foreach ($methods as $name => $fn) {
- $this->{'_fn_' . $name} = $fn;
- }
- }
- /**
- * Lazily determine which methods are not implemented.
- * @throws \BadMethodCallException
- */
- public function __get($name)
- {
- throw new \BadMethodCallException(\str_replace('_fn_', '', $name) . '() is not implemented in the FnStream');
- }
- /**
- * The close method is called on the underlying stream only if possible.
- */
- public function __destruct()
- {
- if (isset($this->_fn_close)) {
- \call_user_func($this->_fn_close);
- }
- }
- /**
- * An unserialize would allow the __destruct to run when the unserialized value goes out of scope.
- * @throws \LogicException
- */
- public function __wakeup()
- {
- throw new \LogicException('FnStream should never be unserialized');
- }
- /**
- * Adds custom functionality to an underlying stream by intercepting
- * specific method calls.
- *
- * @param StreamInterface $stream Stream to decorate
- * @param array $methods Hash of method name to a closure
- *
- * @return FnStream
- */
- public static function decorate(\Psr\Http\Message\StreamInterface $stream, array $methods)
- {
- // If any of the required methods were not provided, then simply
- // proxy to the decorated stream.
- foreach (\array_diff(self::$slots, \array_keys($methods)) as $diff) {
- $methods[$diff] = [$stream, $diff];
- }
- return new self($methods);
- }
- public function __toString()
- {
- return \call_user_func($this->_fn___toString);
- }
- public function close()
- {
- return \call_user_func($this->_fn_close);
- }
- public function detach()
- {
- return \call_user_func($this->_fn_detach);
- }
- public function getSize()
- {
- return \call_user_func($this->_fn_getSize);
- }
- public function tell()
- {
- return \call_user_func($this->_fn_tell);
- }
- public function eof()
- {
- return \call_user_func($this->_fn_eof);
- }
- public function isSeekable()
- {
- return \call_user_func($this->_fn_isSeekable);
- }
- public function rewind()
- {
- \call_user_func($this->_fn_rewind);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- \call_user_func($this->_fn_seek, $offset, $whence);
- }
- public function isWritable()
- {
- return \call_user_func($this->_fn_isWritable);
- }
- public function write($string)
- {
- return \call_user_func($this->_fn_write, $string);
- }
- public function isReadable()
- {
- return \call_user_func($this->_fn_isReadable);
- }
- public function read($length)
- {
- return \call_user_func($this->_fn_read, $length);
- }
- public function getContents()
- {
- return \call_user_func($this->_fn_getContents);
- }
- public function getMetadata($key = null)
- {
- return \call_user_func($this->_fn_getMetadata, $key);
- }
-}
diff --git a/build/psr7/src/InflateStream.php b/build/psr7/src/InflateStream.php
deleted file mode 100644
index 90198d7..0000000
--- a/build/psr7/src/InflateStream.php
+++ /dev/null
@@ -1,48 +0,0 @@
-read(10);
- $filenameHeaderLength = $this->getLengthOfPossibleFilenameHeader($stream, $header);
- // Skip the header, that is 10 + length of filename + 1 (nil) bytes
- $stream = new \PayNL\GuzzleHttp\Psr7\LimitStream($stream, -1, 10 + $filenameHeaderLength);
- $resource = \PayNL\GuzzleHttp\Psr7\StreamWrapper::getResource($stream);
- \stream_filter_append($resource, 'zlib.inflate', \STREAM_FILTER_READ);
- $this->stream = $stream->isSeekable() ? new \PayNL\GuzzleHttp\Psr7\Stream($resource) : new \PayNL\GuzzleHttp\Psr7\NoSeekStream(new \PayNL\GuzzleHttp\Psr7\Stream($resource));
- }
- /**
- * @param StreamInterface $stream
- * @param $header
- * @return int
- */
- private function getLengthOfPossibleFilenameHeader(\Psr\Http\Message\StreamInterface $stream, $header)
- {
- $filename_header_length = 0;
- if (\substr(\bin2hex($header), 6, 2) === '08') {
- // we have a filename, read until nil
- $filename_header_length = 1;
- while ($stream->read(1) !== \chr(0)) {
- $filename_header_length++;
- }
- }
- return $filename_header_length;
- }
-}
diff --git a/build/psr7/src/LazyOpenStream.php b/build/psr7/src/LazyOpenStream.php
deleted file mode 100644
index e392002..0000000
--- a/build/psr7/src/LazyOpenStream.php
+++ /dev/null
@@ -1,35 +0,0 @@
-filename = $filename;
- $this->mode = $mode;
- }
- /**
- * Creates the underlying stream lazily when required.
- *
- * @return StreamInterface
- */
- protected function createStream()
- {
- return stream_for(try_fopen($this->filename, $this->mode));
- }
-}
diff --git a/build/psr7/src/LimitStream.php b/build/psr7/src/LimitStream.php
deleted file mode 100644
index 7a8ee33..0000000
--- a/build/psr7/src/LimitStream.php
+++ /dev/null
@@ -1,128 +0,0 @@
-stream = $stream;
- $this->setLimit($limit);
- $this->setOffset($offset);
- }
- public function eof()
- {
- // Always return true if the underlying stream is EOF
- if ($this->stream->eof()) {
- return \true;
- }
- // No limit and the underlying stream is not at EOF
- if ($this->limit == -1) {
- return \false;
- }
- return $this->stream->tell() >= $this->offset + $this->limit;
- }
- /**
- * Returns the size of the limited subset of data
- * {@inheritdoc}
- */
- public function getSize()
- {
- if (null === ($length = $this->stream->getSize())) {
- return null;
- } elseif ($this->limit == -1) {
- return $length - $this->offset;
- } else {
- return \min($this->limit, $length - $this->offset);
- }
- }
- /**
- * Allow for a bounded seek on the read limited stream
- * {@inheritdoc}
- */
- public function seek($offset, $whence = \SEEK_SET)
- {
- if ($whence !== \SEEK_SET || $offset < 0) {
- throw new \RuntimeException(\sprintf('Cannot seek to offset %s with whence %s', $offset, $whence));
- }
- $offset += $this->offset;
- if ($this->limit !== -1) {
- if ($offset > $this->offset + $this->limit) {
- $offset = $this->offset + $this->limit;
- }
- }
- $this->stream->seek($offset);
- }
- /**
- * Give a relative tell()
- * {@inheritdoc}
- */
- public function tell()
- {
- return $this->stream->tell() - $this->offset;
- }
- /**
- * Set the offset to start limiting from
- *
- * @param int $offset Offset to seek to and begin byte limiting from
- *
- * @throws \RuntimeException if the stream cannot be seeked.
- */
- public function setOffset($offset)
- {
- $current = $this->stream->tell();
- if ($current !== $offset) {
- // If the stream cannot seek to the offset position, then read to it
- if ($this->stream->isSeekable()) {
- $this->stream->seek($offset);
- } elseif ($current > $offset) {
- throw new \RuntimeException("Could not seek to stream offset {$offset}");
- } else {
- $this->stream->read($offset - $current);
- }
- }
- $this->offset = $offset;
- }
- /**
- * Set the limit of bytes that the decorator allows to be read from the
- * stream.
- *
- * @param int $limit Number of bytes to allow to be read from the stream.
- * Use -1 for no limit.
- */
- public function setLimit($limit)
- {
- $this->limit = $limit;
- }
- public function read($length)
- {
- if ($this->limit == -1) {
- return $this->stream->read($length);
- }
- // Check if the current position is less than the total allowed
- // bytes + original offset
- $remaining = $this->offset + $this->limit - $this->stream->tell();
- if ($remaining > 0) {
- // Only return the amount of requested data, ensuring that the byte
- // limit is not exceeded
- return $this->stream->read(\min($remaining, $length));
- }
- return '';
- }
-}
diff --git a/build/psr7/src/MessageTrait.php b/build/psr7/src/MessageTrait.php
deleted file mode 100644
index e801705..0000000
--- a/build/psr7/src/MessageTrait.php
+++ /dev/null
@@ -1,171 +0,0 @@
- array of values */
- private $headers = [];
- /** @var array Map of lowercase header name => original name at registration */
- private $headerNames = [];
- /** @var string */
- private $protocol = '1.1';
- /** @var StreamInterface */
- private $stream;
- public function getProtocolVersion()
- {
- return $this->protocol;
- }
- public function withProtocolVersion($version)
- {
- if ($this->protocol === $version) {
- return $this;
- }
- $new = clone $this;
- $new->protocol = $version;
- return $new;
- }
- public function getHeaders()
- {
- return $this->headers;
- }
- public function hasHeader($header)
- {
- return isset($this->headerNames[\strtolower($header)]);
- }
- public function getHeader($header)
- {
- $header = \strtolower($header);
- if (!isset($this->headerNames[$header])) {
- return [];
- }
- $header = $this->headerNames[$header];
- return $this->headers[$header];
- }
- public function getHeaderLine($header)
- {
- return \implode(', ', $this->getHeader($header));
- }
- public function withHeader($header, $value)
- {
- $this->assertHeader($header);
- $value = $this->normalizeHeaderValue($value);
- $normalized = \strtolower($header);
- $new = clone $this;
- if (isset($new->headerNames[$normalized])) {
- unset($new->headers[$new->headerNames[$normalized]]);
- }
- $new->headerNames[$normalized] = $header;
- $new->headers[$header] = $value;
- return $new;
- }
- public function withAddedHeader($header, $value)
- {
- $this->assertHeader($header);
- $value = $this->normalizeHeaderValue($value);
- $normalized = \strtolower($header);
- $new = clone $this;
- if (isset($new->headerNames[$normalized])) {
- $header = $this->headerNames[$normalized];
- $new->headers[$header] = \array_merge($this->headers[$header], $value);
- } else {
- $new->headerNames[$normalized] = $header;
- $new->headers[$header] = $value;
- }
- return $new;
- }
- public function withoutHeader($header)
- {
- $normalized = \strtolower($header);
- if (!isset($this->headerNames[$normalized])) {
- return $this;
- }
- $header = $this->headerNames[$normalized];
- $new = clone $this;
- unset($new->headers[$header], $new->headerNames[$normalized]);
- return $new;
- }
- public function getBody()
- {
- if (!$this->stream) {
- $this->stream = stream_for('');
- }
- return $this->stream;
- }
- public function withBody(\Psr\Http\Message\StreamInterface $body)
- {
- if ($body === $this->stream) {
- return $this;
- }
- $new = clone $this;
- $new->stream = $body;
- return $new;
- }
- private function setHeaders(array $headers)
- {
- $this->headerNames = $this->headers = [];
- foreach ($headers as $header => $value) {
- if (\is_int($header)) {
- // Numeric array keys are converted to int by PHP but having a header name '123' is not forbidden by the spec
- // and also allowed in withHeader(). So we need to cast it to string again for the following assertion to pass.
- $header = (string) $header;
- }
- $this->assertHeader($header);
- $value = $this->normalizeHeaderValue($value);
- $normalized = \strtolower($header);
- if (isset($this->headerNames[$normalized])) {
- $header = $this->headerNames[$normalized];
- $this->headers[$header] = \array_merge($this->headers[$header], $value);
- } else {
- $this->headerNames[$normalized] = $header;
- $this->headers[$header] = $value;
- }
- }
- }
- private function normalizeHeaderValue($value)
- {
- if (!\is_array($value)) {
- return $this->trimHeaderValues([$value]);
- }
- if (\count($value) === 0) {
- throw new \InvalidArgumentException('Header value can not be an empty array.');
- }
- return $this->trimHeaderValues($value);
- }
- /**
- * Trims whitespace from the header values.
- *
- * Spaces and tabs ought to be excluded by parsers when extracting the field value from a header field.
- *
- * header-field = field-name ":" OWS field-value OWS
- * OWS = *( SP / HTAB )
- *
- * @param string[] $values Header values
- *
- * @return string[] Trimmed header values
- *
- * @see https://tools.ietf.org/html/rfc7230#section-3.2.4
- */
- private function trimHeaderValues(array $values)
- {
- return \array_map(function ($value) {
- if (!\is_scalar($value) && null !== $value) {
- throw new \InvalidArgumentException(\sprintf('Header value must be scalar or null but %s provided.', \is_object($value) ? \get_class($value) : \gettype($value)));
- }
- return \trim((string) $value, " \t");
- }, $values);
- }
- private function assertHeader($header)
- {
- if (!\is_string($header)) {
- throw new \InvalidArgumentException(\sprintf('Header name must be a string but %s provided.', \is_object($header) ? \get_class($header) : \gettype($header)));
- }
- if ($header === '') {
- throw new \InvalidArgumentException('Header name can not be empty.');
- }
- }
-}
diff --git a/build/psr7/src/MultipartStream.php b/build/psr7/src/MultipartStream.php
deleted file mode 100644
index fa6d757..0000000
--- a/build/psr7/src/MultipartStream.php
+++ /dev/null
@@ -1,123 +0,0 @@
-boundary = $boundary ?: \sha1(\uniqid('', \true));
- $this->stream = $this->createStream($elements);
- }
- /**
- * Get the boundary
- *
- * @return string
- */
- public function getBoundary()
- {
- return $this->boundary;
- }
- public function isWritable()
- {
- return \false;
- }
- /**
- * Get the headers needed before transferring the content of a POST file
- */
- private function getHeaders(array $headers)
- {
- $str = '';
- foreach ($headers as $key => $value) {
- $str .= "{$key}: {$value}\r\n";
- }
- return "--{$this->boundary}\r\n" . \trim($str) . "\r\n\r\n";
- }
- /**
- * Create the aggregate stream that will be used to upload the POST data
- */
- protected function createStream(array $elements)
- {
- $stream = new \PayNL\GuzzleHttp\Psr7\AppendStream();
- foreach ($elements as $element) {
- $this->addElement($stream, $element);
- }
- // Add the trailing boundary with CRLF
- $stream->addStream(stream_for("--{$this->boundary}--\r\n"));
- return $stream;
- }
- private function addElement(\PayNL\GuzzleHttp\Psr7\AppendStream $stream, array $element)
- {
- foreach (['contents', 'name'] as $key) {
- if (!\array_key_exists($key, $element)) {
- throw new \InvalidArgumentException("A '{$key}' key is required");
- }
- }
- $element['contents'] = stream_for($element['contents']);
- if (empty($element['filename'])) {
- $uri = $element['contents']->getMetadata('uri');
- if (\substr($uri, 0, 6) !== 'php://') {
- $element['filename'] = $uri;
- }
- }
- list($body, $headers) = $this->createElement($element['name'], $element['contents'], isset($element['filename']) ? $element['filename'] : null, isset($element['headers']) ? $element['headers'] : []);
- $stream->addStream(stream_for($this->getHeaders($headers)));
- $stream->addStream($body);
- $stream->addStream(stream_for("\r\n"));
- }
- /**
- * @return array
- */
- private function createElement($name, \Psr\Http\Message\StreamInterface $stream, $filename, array $headers)
- {
- // Set a default content-disposition header if one was no provided
- $disposition = $this->getHeader($headers, 'content-disposition');
- if (!$disposition) {
- $headers['Content-Disposition'] = $filename === '0' || $filename ? \sprintf('form-data; name="%s"; filename="%s"', $name, \basename($filename)) : "form-data; name=\"{$name}\"";
- }
- // Set a default content-length header if one was no provided
- $length = $this->getHeader($headers, 'content-length');
- if (!$length) {
- if ($length = $stream->getSize()) {
- $headers['Content-Length'] = (string) $length;
- }
- }
- // Set a default Content-Type if one was not supplied
- $type = $this->getHeader($headers, 'content-type');
- if (!$type && ($filename === '0' || $filename)) {
- if ($type = mimetype_from_filename($filename)) {
- $headers['Content-Type'] = $type;
- }
- }
- return [$stream, $headers];
- }
- private function getHeader(array $headers, $key)
- {
- $lowercaseHeader = \strtolower($key);
- foreach ($headers as $k => $v) {
- if (\strtolower($k) === $lowercaseHeader) {
- return $v;
- }
- }
- return null;
- }
-}
diff --git a/build/psr7/src/NoSeekStream.php b/build/psr7/src/NoSeekStream.php
deleted file mode 100644
index 2adbc2e..0000000
--- a/build/psr7/src/NoSeekStream.php
+++ /dev/null
@@ -1,20 +0,0 @@
-source = $source;
- $this->size = isset($options['size']) ? $options['size'] : null;
- $this->metadata = isset($options['metadata']) ? $options['metadata'] : [];
- $this->buffer = new \PayNL\GuzzleHttp\Psr7\BufferStream();
- }
- public function __toString()
- {
- try {
- return copy_to_string($this);
- } catch (\Exception $e) {
- return '';
- }
- }
- public function close()
- {
- $this->detach();
- }
- public function detach()
- {
- $this->tellPos = \false;
- $this->source = null;
- }
- public function getSize()
- {
- return $this->size;
- }
- public function tell()
- {
- return $this->tellPos;
- }
- public function eof()
- {
- return !$this->source;
- }
- public function isSeekable()
- {
- return \false;
- }
- public function rewind()
- {
- $this->seek(0);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- throw new \RuntimeException('Cannot seek a PumpStream');
- }
- public function isWritable()
- {
- return \false;
- }
- public function write($string)
- {
- throw new \RuntimeException('Cannot write to a PumpStream');
- }
- public function isReadable()
- {
- return \true;
- }
- public function read($length)
- {
- $data = $this->buffer->read($length);
- $readLen = \strlen($data);
- $this->tellPos += $readLen;
- $remaining = $length - $readLen;
- if ($remaining) {
- $this->pump($remaining);
- $data .= $this->buffer->read($remaining);
- $this->tellPos += \strlen($data) - $readLen;
- }
- return $data;
- }
- public function getContents()
- {
- $result = '';
- while (!$this->eof()) {
- $result .= $this->read(1000000);
- }
- return $result;
- }
- public function getMetadata($key = null)
- {
- if (!$key) {
- return $this->metadata;
- }
- return isset($this->metadata[$key]) ? $this->metadata[$key] : null;
- }
- private function pump($length)
- {
- if ($this->source) {
- do {
- $data = \call_user_func($this->source, $length);
- if ($data === \false || $data === null) {
- $this->source = null;
- return;
- }
- $this->buffer->write($data);
- $length -= \strlen($data);
- } while ($length > 0);
- }
- }
-}
diff --git a/build/psr7/src/Request.php b/build/psr7/src/Request.php
deleted file mode 100644
index 54f2208..0000000
--- a/build/psr7/src/Request.php
+++ /dev/null
@@ -1,120 +0,0 @@
-assertMethod($method);
- if (!$uri instanceof \Psr\Http\Message\UriInterface) {
- $uri = new \PayNL\GuzzleHttp\Psr7\Uri($uri);
- }
- $this->method = \strtoupper($method);
- $this->uri = $uri;
- $this->setHeaders($headers);
- $this->protocol = $version;
- if (!isset($this->headerNames['host'])) {
- $this->updateHostFromUri();
- }
- if ($body !== '' && $body !== null) {
- $this->stream = stream_for($body);
- }
- }
- public function getRequestTarget()
- {
- if ($this->requestTarget !== null) {
- return $this->requestTarget;
- }
- $target = $this->uri->getPath();
- if ($target == '') {
- $target = '/';
- }
- if ($this->uri->getQuery() != '') {
- $target .= '?' . $this->uri->getQuery();
- }
- return $target;
- }
- public function withRequestTarget($requestTarget)
- {
- if (\preg_match('#\\s#', $requestTarget)) {
- throw new \InvalidArgumentException('Invalid request target provided; cannot contain whitespace');
- }
- $new = clone $this;
- $new->requestTarget = $requestTarget;
- return $new;
- }
- public function getMethod()
- {
- return $this->method;
- }
- public function withMethod($method)
- {
- $this->assertMethod($method);
- $new = clone $this;
- $new->method = \strtoupper($method);
- return $new;
- }
- public function getUri()
- {
- return $this->uri;
- }
- public function withUri(\Psr\Http\Message\UriInterface $uri, $preserveHost = \false)
- {
- if ($uri === $this->uri) {
- return $this;
- }
- $new = clone $this;
- $new->uri = $uri;
- if (!$preserveHost || !isset($this->headerNames['host'])) {
- $new->updateHostFromUri();
- }
- return $new;
- }
- private function updateHostFromUri()
- {
- $host = $this->uri->getHost();
- if ($host == '') {
- return;
- }
- if (($port = $this->uri->getPort()) !== null) {
- $host .= ':' . $port;
- }
- if (isset($this->headerNames['host'])) {
- $header = $this->headerNames['host'];
- } else {
- $header = 'Host';
- $this->headerNames['host'] = 'Host';
- }
- // Ensure Host is the first header.
- // See: http://tools.ietf.org/html/rfc7230#section-5.4
- $this->headers = [$header => [$host]] + $this->headers;
- }
- private function assertMethod($method)
- {
- if (!\is_string($method) || $method === '') {
- throw new \InvalidArgumentException('Method must be a non-empty string.');
- }
- }
-}
diff --git a/build/psr7/src/Response.php b/build/psr7/src/Response.php
deleted file mode 100644
index 65a9ed9..0000000
--- a/build/psr7/src/Response.php
+++ /dev/null
@@ -1,76 +0,0 @@
- 'Continue', 101 => 'Switching Protocols', 102 => 'Processing', 200 => 'OK', 201 => 'Created', 202 => 'Accepted', 203 => 'Non-Authoritative Information', 204 => 'No Content', 205 => 'Reset Content', 206 => 'Partial Content', 207 => 'Multi-status', 208 => 'Already Reported', 300 => 'Multiple Choices', 301 => 'Moved Permanently', 302 => 'Found', 303 => 'See Other', 304 => 'Not Modified', 305 => 'Use Proxy', 306 => 'Switch Proxy', 307 => 'Temporary Redirect', 400 => 'Bad Request', 401 => 'Unauthorized', 402 => 'Payment Required', 403 => 'Forbidden', 404 => 'Not Found', 405 => 'Method Not Allowed', 406 => 'Not Acceptable', 407 => 'Proxy Authentication Required', 408 => 'Request Time-out', 409 => 'Conflict', 410 => 'Gone', 411 => 'Length Required', 412 => 'Precondition Failed', 413 => 'Request Entity Too Large', 414 => 'Request-URI Too Large', 415 => 'Unsupported Media Type', 416 => 'Requested range not satisfiable', 417 => 'Expectation Failed', 418 => 'I\'m a teapot', 422 => 'Unprocessable Entity', 423 => 'Locked', 424 => 'Failed Dependency', 425 => 'Unordered Collection', 426 => 'Upgrade Required', 428 => 'Precondition Required', 429 => 'Too Many Requests', 431 => 'Request Header Fields Too Large', 451 => 'Unavailable For Legal Reasons', 500 => 'Internal Server Error', 501 => 'Not Implemented', 502 => 'Bad Gateway', 503 => 'Service Unavailable', 504 => 'Gateway Time-out', 505 => 'HTTP Version not supported', 506 => 'Variant Also Negotiates', 507 => 'Insufficient Storage', 508 => 'Loop Detected', 511 => 'Network Authentication Required'];
- /** @var string */
- private $reasonPhrase = '';
- /** @var int */
- private $statusCode = 200;
- /**
- * @param int $status Status code
- * @param array $headers Response headers
- * @param string|null|resource|StreamInterface $body Response body
- * @param string $version Protocol version
- * @param string|null $reason Reason phrase (when empty a default will be used based on the status code)
- */
- public function __construct($status = 200, array $headers = [], $body = null, $version = '1.1', $reason = null)
- {
- $this->assertStatusCodeIsInteger($status);
- $status = (int) $status;
- $this->assertStatusCodeRange($status);
- $this->statusCode = $status;
- if ($body !== '' && $body !== null) {
- $this->stream = stream_for($body);
- }
- $this->setHeaders($headers);
- if ($reason == '' && isset(self::$phrases[$this->statusCode])) {
- $this->reasonPhrase = self::$phrases[$this->statusCode];
- } else {
- $this->reasonPhrase = (string) $reason;
- }
- $this->protocol = $version;
- }
- public function getStatusCode()
- {
- return $this->statusCode;
- }
- public function getReasonPhrase()
- {
- return $this->reasonPhrase;
- }
- public function withStatus($code, $reasonPhrase = '')
- {
- $this->assertStatusCodeIsInteger($code);
- $code = (int) $code;
- $this->assertStatusCodeRange($code);
- $new = clone $this;
- $new->statusCode = $code;
- if ($reasonPhrase == '' && isset(self::$phrases[$new->statusCode])) {
- $reasonPhrase = self::$phrases[$new->statusCode];
- }
- $new->reasonPhrase = $reasonPhrase;
- return $new;
- }
- private function assertStatusCodeIsInteger($statusCode)
- {
- if (\filter_var($statusCode, \FILTER_VALIDATE_INT) === \false) {
- throw new \InvalidArgumentException('Status code must be an integer value.');
- }
- }
- private function assertStatusCodeRange($statusCode)
- {
- if ($statusCode < 100 || $statusCode >= 600) {
- throw new \InvalidArgumentException('Status code must be an integer value between 1xx and 5xx.');
- }
- }
-}
diff --git a/build/psr7/src/Rfc7230.php b/build/psr7/src/Rfc7230.php
deleted file mode 100644
index e52a5d7..0000000
--- a/build/psr7/src/Rfc7230.php
+++ /dev/null
@@ -1,18 +0,0 @@
-@,;:\\\"/[\\]?={}\1- ]++):[ \t]*+((?:[ \t]*+[!-~€-ÿ]++)*+)[ \t]*+\r?\n)m";
- const HEADER_FOLD_REGEX = "(\r?\n[ \t]++)";
-}
diff --git a/build/psr7/src/ServerRequest.php b/build/psr7/src/ServerRequest.php
deleted file mode 100644
index 8348ef6..0000000
--- a/build/psr7/src/ServerRequest.php
+++ /dev/null
@@ -1,302 +0,0 @@
-serverParams = $serverParams;
- parent::__construct($method, $uri, $headers, $body, $version);
- }
- /**
- * Return an UploadedFile instance array.
- *
- * @param array $files A array which respect $_FILES structure
- * @throws InvalidArgumentException for unrecognized values
- * @return array
- */
- public static function normalizeFiles(array $files)
- {
- $normalized = [];
- foreach ($files as $key => $value) {
- if ($value instanceof \Psr\Http\Message\UploadedFileInterface) {
- $normalized[$key] = $value;
- } elseif (\is_array($value) && isset($value['tmp_name'])) {
- $normalized[$key] = self::createUploadedFileFromSpec($value);
- } elseif (\is_array($value)) {
- $normalized[$key] = self::normalizeFiles($value);
- continue;
- } else {
- throw new \InvalidArgumentException('Invalid value in files specification');
- }
- }
- return $normalized;
- }
- /**
- * Create and return an UploadedFile instance from a $_FILES specification.
- *
- * If the specification represents an array of values, this method will
- * delegate to normalizeNestedFileSpec() and return that return value.
- *
- * @param array $value $_FILES struct
- * @return array|UploadedFileInterface
- */
- private static function createUploadedFileFromSpec(array $value)
- {
- if (\is_array($value['tmp_name'])) {
- return self::normalizeNestedFileSpec($value);
- }
- return new \PayNL\GuzzleHttp\Psr7\UploadedFile($value['tmp_name'], (int) $value['size'], (int) $value['error'], $value['name'], $value['type']);
- }
- /**
- * Normalize an array of file specifications.
- *
- * Loops through all nested files and returns a normalized array of
- * UploadedFileInterface instances.
- *
- * @param array $files
- * @return UploadedFileInterface[]
- */
- private static function normalizeNestedFileSpec(array $files = [])
- {
- $normalizedFiles = [];
- foreach (\array_keys($files['tmp_name']) as $key) {
- $spec = ['tmp_name' => $files['tmp_name'][$key], 'size' => $files['size'][$key], 'error' => $files['error'][$key], 'name' => $files['name'][$key], 'type' => $files['type'][$key]];
- $normalizedFiles[$key] = self::createUploadedFileFromSpec($spec);
- }
- return $normalizedFiles;
- }
- /**
- * Return a ServerRequest populated with superglobals:
- * $_GET
- * $_POST
- * $_COOKIE
- * $_FILES
- * $_SERVER
- *
- * @return ServerRequestInterface
- */
- public static function fromGlobals()
- {
- $method = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : 'GET';
- $headers = getallheaders();
- $uri = self::getUriFromGlobals();
- $body = new \PayNL\GuzzleHttp\Psr7\CachingStream(new \PayNL\GuzzleHttp\Psr7\LazyOpenStream('php://input', 'r+'));
- $protocol = isset($_SERVER['SERVER_PROTOCOL']) ? \str_replace('HTTP/', '', $_SERVER['SERVER_PROTOCOL']) : '1.1';
- $serverRequest = new \PayNL\GuzzleHttp\Psr7\ServerRequest($method, $uri, $headers, $body, $protocol, $_SERVER);
- return $serverRequest->withCookieParams($_COOKIE)->withQueryParams($_GET)->withParsedBody($_POST)->withUploadedFiles(self::normalizeFiles($_FILES));
- }
- private static function extractHostAndPortFromAuthority($authority)
- {
- $uri = 'http://' . $authority;
- $parts = \parse_url($uri);
- if (\false === $parts) {
- return [null, null];
- }
- $host = isset($parts['host']) ? $parts['host'] : null;
- $port = isset($parts['port']) ? $parts['port'] : null;
- return [$host, $port];
- }
- /**
- * Get a Uri populated with values from $_SERVER.
- *
- * @return UriInterface
- */
- public static function getUriFromGlobals()
- {
- $uri = new \PayNL\GuzzleHttp\Psr7\Uri('');
- $uri = $uri->withScheme(!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http');
- $hasPort = \false;
- if (isset($_SERVER['HTTP_HOST'])) {
- list($host, $port) = self::extractHostAndPortFromAuthority($_SERVER['HTTP_HOST']);
- if ($host !== null) {
- $uri = $uri->withHost($host);
- }
- if ($port !== null) {
- $hasPort = \true;
- $uri = $uri->withPort($port);
- }
- } elseif (isset($_SERVER['SERVER_NAME'])) {
- $uri = $uri->withHost($_SERVER['SERVER_NAME']);
- } elseif (isset($_SERVER['SERVER_ADDR'])) {
- $uri = $uri->withHost($_SERVER['SERVER_ADDR']);
- }
- if (!$hasPort && isset($_SERVER['SERVER_PORT'])) {
- $uri = $uri->withPort($_SERVER['SERVER_PORT']);
- }
- $hasQuery = \false;
- if (isset($_SERVER['REQUEST_URI'])) {
- $requestUriParts = \explode('?', $_SERVER['REQUEST_URI'], 2);
- $uri = $uri->withPath($requestUriParts[0]);
- if (isset($requestUriParts[1])) {
- $hasQuery = \true;
- $uri = $uri->withQuery($requestUriParts[1]);
- }
- }
- if (!$hasQuery && isset($_SERVER['QUERY_STRING'])) {
- $uri = $uri->withQuery($_SERVER['QUERY_STRING']);
- }
- return $uri;
- }
- /**
- * {@inheritdoc}
- */
- public function getServerParams()
- {
- return $this->serverParams;
- }
- /**
- * {@inheritdoc}
- */
- public function getUploadedFiles()
- {
- return $this->uploadedFiles;
- }
- /**
- * {@inheritdoc}
- */
- public function withUploadedFiles(array $uploadedFiles)
- {
- $new = clone $this;
- $new->uploadedFiles = $uploadedFiles;
- return $new;
- }
- /**
- * {@inheritdoc}
- */
- public function getCookieParams()
- {
- return $this->cookieParams;
- }
- /**
- * {@inheritdoc}
- */
- public function withCookieParams(array $cookies)
- {
- $new = clone $this;
- $new->cookieParams = $cookies;
- return $new;
- }
- /**
- * {@inheritdoc}
- */
- public function getQueryParams()
- {
- return $this->queryParams;
- }
- /**
- * {@inheritdoc}
- */
- public function withQueryParams(array $query)
- {
- $new = clone $this;
- $new->queryParams = $query;
- return $new;
- }
- /**
- * {@inheritdoc}
- */
- public function getParsedBody()
- {
- return $this->parsedBody;
- }
- /**
- * {@inheritdoc}
- */
- public function withParsedBody($data)
- {
- $new = clone $this;
- $new->parsedBody = $data;
- return $new;
- }
- /**
- * {@inheritdoc}
- */
- public function getAttributes()
- {
- return $this->attributes;
- }
- /**
- * {@inheritdoc}
- */
- public function getAttribute($attribute, $default = null)
- {
- if (\false === \array_key_exists($attribute, $this->attributes)) {
- return $default;
- }
- return $this->attributes[$attribute];
- }
- /**
- * {@inheritdoc}
- */
- public function withAttribute($attribute, $value)
- {
- $new = clone $this;
- $new->attributes[$attribute] = $value;
- return $new;
- }
- /**
- * {@inheritdoc}
- */
- public function withoutAttribute($attribute)
- {
- if (\false === \array_key_exists($attribute, $this->attributes)) {
- return $this;
- }
- $new = clone $this;
- unset($new->attributes[$attribute]);
- return $new;
- }
-}
diff --git a/build/psr7/src/Stream.php b/build/psr7/src/Stream.php
deleted file mode 100644
index 76491f6..0000000
--- a/build/psr7/src/Stream.php
+++ /dev/null
@@ -1,221 +0,0 @@
-size = $options['size'];
- }
- $this->customMetadata = isset($options['metadata']) ? $options['metadata'] : [];
- $this->stream = $stream;
- $meta = \stream_get_meta_data($this->stream);
- $this->seekable = $meta['seekable'];
- $this->readable = (bool) \preg_match(self::READABLE_MODES, $meta['mode']);
- $this->writable = (bool) \preg_match(self::WRITABLE_MODES, $meta['mode']);
- $this->uri = $this->getMetadata('uri');
- }
- /**
- * Closes the stream when the destructed
- */
- public function __destruct()
- {
- $this->close();
- }
- public function __toString()
- {
- try {
- $this->seek(0);
- return (string) \stream_get_contents($this->stream);
- } catch (\Exception $e) {
- return '';
- }
- }
- public function getContents()
- {
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- $contents = \stream_get_contents($this->stream);
- if ($contents === \false) {
- throw new \RuntimeException('Unable to read stream contents');
- }
- return $contents;
- }
- public function close()
- {
- if (isset($this->stream)) {
- if (\is_resource($this->stream)) {
- \fclose($this->stream);
- }
- $this->detach();
- }
- }
- public function detach()
- {
- if (!isset($this->stream)) {
- return null;
- }
- $result = $this->stream;
- unset($this->stream);
- $this->size = $this->uri = null;
- $this->readable = $this->writable = $this->seekable = \false;
- return $result;
- }
- public function getSize()
- {
- if ($this->size !== null) {
- return $this->size;
- }
- if (!isset($this->stream)) {
- return null;
- }
- // Clear the stat cache if the stream has a URI
- if ($this->uri) {
- \clearstatcache(\true, $this->uri);
- }
- $stats = \fstat($this->stream);
- if (isset($stats['size'])) {
- $this->size = $stats['size'];
- return $this->size;
- }
- return null;
- }
- public function isReadable()
- {
- return $this->readable;
- }
- public function isWritable()
- {
- return $this->writable;
- }
- public function isSeekable()
- {
- return $this->seekable;
- }
- public function eof()
- {
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- return \feof($this->stream);
- }
- public function tell()
- {
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- $result = \ftell($this->stream);
- if ($result === \false) {
- throw new \RuntimeException('Unable to determine stream position');
- }
- return $result;
- }
- public function rewind()
- {
- $this->seek(0);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- $whence = (int) $whence;
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- if (!$this->seekable) {
- throw new \RuntimeException('Stream is not seekable');
- }
- if (\fseek($this->stream, $offset, $whence) === -1) {
- throw new \RuntimeException('Unable to seek to stream position ' . $offset . ' with whence ' . \var_export($whence, \true));
- }
- }
- public function read($length)
- {
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- if (!$this->readable) {
- throw new \RuntimeException('Cannot read from non-readable stream');
- }
- if ($length < 0) {
- throw new \RuntimeException('Length parameter cannot be negative');
- }
- if (0 === $length) {
- return '';
- }
- $string = \fread($this->stream, $length);
- if (\false === $string) {
- throw new \RuntimeException('Unable to read from stream');
- }
- return $string;
- }
- public function write($string)
- {
- if (!isset($this->stream)) {
- throw new \RuntimeException('Stream is detached');
- }
- if (!$this->writable) {
- throw new \RuntimeException('Cannot write to a non-writable stream');
- }
- // We can't know the size after writing anything
- $this->size = null;
- $result = \fwrite($this->stream, $string);
- if ($result === \false) {
- throw new \RuntimeException('Unable to write to stream');
- }
- return $result;
- }
- public function getMetadata($key = null)
- {
- if (!isset($this->stream)) {
- return $key ? null : [];
- } elseif (!$key) {
- return $this->customMetadata + \stream_get_meta_data($this->stream);
- } elseif (isset($this->customMetadata[$key])) {
- return $this->customMetadata[$key];
- }
- $meta = \stream_get_meta_data($this->stream);
- return isset($meta[$key]) ? $meta[$key] : null;
- }
-}
diff --git a/build/psr7/src/StreamDecoratorTrait.php b/build/psr7/src/StreamDecoratorTrait.php
deleted file mode 100644
index ea83934..0000000
--- a/build/psr7/src/StreamDecoratorTrait.php
+++ /dev/null
@@ -1,128 +0,0 @@
-stream = $stream;
- }
- /**
- * Magic method used to create a new stream if streams are not added in
- * the constructor of a decorator (e.g., LazyOpenStream).
- *
- * @param string $name Name of the property (allows "stream" only).
- *
- * @return StreamInterface
- */
- public function __get($name)
- {
- if ($name == 'stream') {
- $this->stream = $this->createStream();
- return $this->stream;
- }
- throw new \UnexpectedValueException("{$name} not found on class");
- }
- public function __toString()
- {
- try {
- if ($this->isSeekable()) {
- $this->seek(0);
- }
- return $this->getContents();
- } catch (\Exception $e) {
- // Really, PHP? https://bugs.php.net/bug.php?id=53648
- \trigger_error('StreamDecorator::__toString exception: ' . (string) $e, \E_USER_ERROR);
- return '';
- }
- }
- public function getContents()
- {
- return copy_to_string($this);
- }
- /**
- * Allow decorators to implement custom methods
- *
- * @param string $method Missing method name
- * @param array $args Method arguments
- *
- * @return mixed
- */
- public function __call($method, array $args)
- {
- $result = \call_user_func_array([$this->stream, $method], $args);
- // Always return the wrapped object if the result is a return $this
- return $result === $this->stream ? $this : $result;
- }
- public function close()
- {
- $this->stream->close();
- }
- public function getMetadata($key = null)
- {
- return $this->stream->getMetadata($key);
- }
- public function detach()
- {
- return $this->stream->detach();
- }
- public function getSize()
- {
- return $this->stream->getSize();
- }
- public function eof()
- {
- return $this->stream->eof();
- }
- public function tell()
- {
- return $this->stream->tell();
- }
- public function isReadable()
- {
- return $this->stream->isReadable();
- }
- public function isWritable()
- {
- return $this->stream->isWritable();
- }
- public function isSeekable()
- {
- return $this->stream->isSeekable();
- }
- public function rewind()
- {
- $this->seek(0);
- }
- public function seek($offset, $whence = \SEEK_SET)
- {
- $this->stream->seek($offset, $whence);
- }
- public function read($length)
- {
- return $this->stream->read($length);
- }
- public function write($string)
- {
- return $this->stream->write($string);
- }
- /**
- * Implement in subclasses to dynamically create streams when requested.
- *
- * @return StreamInterface
- * @throws \BadMethodCallException
- */
- protected function createStream()
- {
- throw new \BadMethodCallException('Not implemented');
- }
-}
diff --git a/build/psr7/src/StreamWrapper.php b/build/psr7/src/StreamWrapper.php
deleted file mode 100644
index 6a7e0ff..0000000
--- a/build/psr7/src/StreamWrapper.php
+++ /dev/null
@@ -1,102 +0,0 @@
-isReadable()) {
- $mode = $stream->isWritable() ? 'r+' : 'r';
- } elseif ($stream->isWritable()) {
- $mode = 'w';
- } else {
- throw new \InvalidArgumentException('The stream must be readable, ' . 'writable, or both.');
- }
- return \fopen('guzzle://stream', $mode, null, self::createStreamContext($stream));
- }
- /**
- * Creates a stream context that can be used to open a stream as a php stream resource.
- *
- * @param StreamInterface $stream
- *
- * @return resource
- */
- public static function createStreamContext(\Psr\Http\Message\StreamInterface $stream)
- {
- return \stream_context_create(['guzzle' => ['stream' => $stream]]);
- }
- /**
- * Registers the stream wrapper if needed
- */
- public static function register()
- {
- if (!\in_array('guzzle', \stream_get_wrappers())) {
- \stream_wrapper_register('guzzle', __CLASS__);
- }
- }
- public function stream_open($path, $mode, $options, &$opened_path)
- {
- $options = \stream_context_get_options($this->context);
- if (!isset($options['guzzle']['stream'])) {
- return \false;
- }
- $this->mode = $mode;
- $this->stream = $options['guzzle']['stream'];
- return \true;
- }
- public function stream_read($count)
- {
- return $this->stream->read($count);
- }
- public function stream_write($data)
- {
- return (int) $this->stream->write($data);
- }
- public function stream_tell()
- {
- return $this->stream->tell();
- }
- public function stream_eof()
- {
- return $this->stream->eof();
- }
- public function stream_seek($offset, $whence)
- {
- $this->stream->seek($offset, $whence);
- return \true;
- }
- public function stream_cast($cast_as)
- {
- $stream = clone $this->stream;
- return $stream->detach();
- }
- public function stream_stat()
- {
- static $modeMap = ['r' => 33060, 'rb' => 33060, 'r+' => 33206, 'w' => 33188, 'wb' => 33188];
- return ['dev' => 0, 'ino' => 0, 'mode' => $modeMap[$this->mode], 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => $this->stream->getSize() ?: 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0];
- }
- public function url_stat($path, $flags)
- {
- return ['dev' => 0, 'ino' => 0, 'mode' => 0, 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0];
- }
-}
diff --git a/build/psr7/src/UploadedFile.php b/build/psr7/src/UploadedFile.php
deleted file mode 100644
index efd3788..0000000
--- a/build/psr7/src/UploadedFile.php
+++ /dev/null
@@ -1,244 +0,0 @@
-setError($errorStatus);
- $this->setSize($size);
- $this->setClientFilename($clientFilename);
- $this->setClientMediaType($clientMediaType);
- if ($this->isOk()) {
- $this->setStreamOrFile($streamOrFile);
- }
- }
- /**
- * Depending on the value set file or stream variable
- *
- * @param mixed $streamOrFile
- * @throws InvalidArgumentException
- */
- private function setStreamOrFile($streamOrFile)
- {
- if (\is_string($streamOrFile)) {
- $this->file = $streamOrFile;
- } elseif (\is_resource($streamOrFile)) {
- $this->stream = new \PayNL\GuzzleHttp\Psr7\Stream($streamOrFile);
- } elseif ($streamOrFile instanceof \Psr\Http\Message\StreamInterface) {
- $this->stream = $streamOrFile;
- } else {
- throw new \InvalidArgumentException('Invalid stream or file provided for UploadedFile');
- }
- }
- /**
- * @param int $error
- * @throws InvalidArgumentException
- */
- private function setError($error)
- {
- if (\false === \is_int($error)) {
- throw new \InvalidArgumentException('Upload file error status must be an integer');
- }
- if (\false === \in_array($error, \PayNL\GuzzleHttp\Psr7\UploadedFile::$errors)) {
- throw new \InvalidArgumentException('Invalid error status for UploadedFile');
- }
- $this->error = $error;
- }
- /**
- * @param int $size
- * @throws InvalidArgumentException
- */
- private function setSize($size)
- {
- if (\false === \is_int($size)) {
- throw new \InvalidArgumentException('Upload file size must be an integer');
- }
- $this->size = $size;
- }
- /**
- * @param mixed $param
- * @return boolean
- */
- private function isStringOrNull($param)
- {
- return \in_array(\gettype($param), ['string', 'NULL']);
- }
- /**
- * @param mixed $param
- * @return boolean
- */
- private function isStringNotEmpty($param)
- {
- return \is_string($param) && \false === empty($param);
- }
- /**
- * @param string|null $clientFilename
- * @throws InvalidArgumentException
- */
- private function setClientFilename($clientFilename)
- {
- if (\false === $this->isStringOrNull($clientFilename)) {
- throw new \InvalidArgumentException('Upload file client filename must be a string or null');
- }
- $this->clientFilename = $clientFilename;
- }
- /**
- * @param string|null $clientMediaType
- * @throws InvalidArgumentException
- */
- private function setClientMediaType($clientMediaType)
- {
- if (\false === $this->isStringOrNull($clientMediaType)) {
- throw new \InvalidArgumentException('Upload file client media type must be a string or null');
- }
- $this->clientMediaType = $clientMediaType;
- }
- /**
- * Return true if there is no upload error
- *
- * @return boolean
- */
- private function isOk()
- {
- return $this->error === \UPLOAD_ERR_OK;
- }
- /**
- * @return boolean
- */
- public function isMoved()
- {
- return $this->moved;
- }
- /**
- * @throws RuntimeException if is moved or not ok
- */
- private function validateActive()
- {
- if (\false === $this->isOk()) {
- throw new \RuntimeException('Cannot retrieve stream due to upload error');
- }
- if ($this->isMoved()) {
- throw new \RuntimeException('Cannot retrieve stream after it has already been moved');
- }
- }
- /**
- * {@inheritdoc}
- * @throws RuntimeException if the upload was not successful.
- */
- public function getStream()
- {
- $this->validateActive();
- if ($this->stream instanceof \Psr\Http\Message\StreamInterface) {
- return $this->stream;
- }
- return new \PayNL\GuzzleHttp\Psr7\LazyOpenStream($this->file, 'r+');
- }
- /**
- * {@inheritdoc}
- *
- * @see http://php.net/is_uploaded_file
- * @see http://php.net/move_uploaded_file
- * @param string $targetPath Path to which to move the uploaded file.
- * @throws RuntimeException if the upload was not successful.
- * @throws InvalidArgumentException if the $path specified is invalid.
- * @throws RuntimeException on any error during the move operation, or on
- * the second or subsequent call to the method.
- */
- public function moveTo($targetPath)
- {
- $this->validateActive();
- if (\false === $this->isStringNotEmpty($targetPath)) {
- throw new \InvalidArgumentException('Invalid path provided for move operation; must be a non-empty string');
- }
- if ($this->file) {
- $this->moved = \php_sapi_name() == 'cli' ? \rename($this->file, $targetPath) : \move_uploaded_file($this->file, $targetPath);
- } else {
- copy_to_stream($this->getStream(), new \PayNL\GuzzleHttp\Psr7\LazyOpenStream($targetPath, 'w'));
- $this->moved = \true;
- }
- if (\false === $this->moved) {
- throw new \RuntimeException(\sprintf('Uploaded file could not be moved to %s', $targetPath));
- }
- }
- /**
- * {@inheritdoc}
- *
- * @return int|null The file size in bytes or null if unknown.
- */
- public function getSize()
- {
- return $this->size;
- }
- /**
- * {@inheritdoc}
- *
- * @see http://php.net/manual/en/features.file-upload.errors.php
- * @return int One of PHP's UPLOAD_ERR_XXX constants.
- */
- public function getError()
- {
- return $this->error;
- }
- /**
- * {@inheritdoc}
- *
- * @return string|null The filename sent by the client or null if none
- * was provided.
- */
- public function getClientFilename()
- {
- return $this->clientFilename;
- }
- /**
- * {@inheritdoc}
- */
- public function getClientMediaType()
- {
- return $this->clientMediaType;
- }
-}
diff --git a/build/psr7/src/Uri.php b/build/psr7/src/Uri.php
deleted file mode 100644
index d5226f1..0000000
--- a/build/psr7/src/Uri.php
+++ /dev/null
@@ -1,598 +0,0 @@
- 80, 'https' => 443, 'ftp' => 21, 'gopher' => 70, 'nntp' => 119, 'news' => 119, 'telnet' => 23, 'tn3270' => 23, 'imap' => 143, 'pop' => 110, 'ldap' => 389];
- private static $charUnreserved = 'a-zA-Z0-9_\\-\\.~';
- private static $charSubDelims = '!\\$&\'\\(\\)\\*\\+,;=';
- private static $replaceQuery = ['=' => '%3D', '&' => '%26'];
- /** @var string Uri scheme. */
- private $scheme = '';
- /** @var string Uri user info. */
- private $userInfo = '';
- /** @var string Uri host. */
- private $host = '';
- /** @var int|null Uri port. */
- private $port;
- /** @var string Uri path. */
- private $path = '';
- /** @var string Uri query string. */
- private $query = '';
- /** @var string Uri fragment. */
- private $fragment = '';
- /**
- * @param string $uri URI to parse
- */
- public function __construct($uri = '')
- {
- // weak type check to also accept null until we can add scalar type hints
- if ($uri != '') {
- $parts = \parse_url($uri);
- if ($parts === \false) {
- throw new \InvalidArgumentException("Unable to parse URI: {$uri}");
- }
- $this->applyParts($parts);
- }
- }
- public function __toString()
- {
- return self::composeComponents($this->scheme, $this->getAuthority(), $this->path, $this->query, $this->fragment);
- }
- /**
- * Composes a URI reference string from its various components.
- *
- * Usually this method does not need to be called manually but instead is used indirectly via
- * `Psr\Http\Message\UriInterface::__toString`.
- *
- * PSR-7 UriInterface treats an empty component the same as a missing component as
- * getQuery(), getFragment() etc. always return a string. This explains the slight
- * difference to RFC 3986 Section 5.3.
- *
- * Another adjustment is that the authority separator is added even when the authority is missing/empty
- * for the "file" scheme. This is because PHP stream functions like `file_get_contents` only work with
- * `file:///myfile` but not with `file:/myfile` although they are equivalent according to RFC 3986. But
- * `file:///` is the more common syntax for the file scheme anyway (Chrome for example redirects to
- * that format).
- *
- * @param string $scheme
- * @param string $authority
- * @param string $path
- * @param string $query
- * @param string $fragment
- *
- * @return string
- *
- * @link https://tools.ietf.org/html/rfc3986#section-5.3
- */
- public static function composeComponents($scheme, $authority, $path, $query, $fragment)
- {
- $uri = '';
- // weak type checks to also accept null until we can add scalar type hints
- if ($scheme != '') {
- $uri .= $scheme . ':';
- }
- if ($authority != '' || $scheme === 'file') {
- $uri .= '//' . $authority;
- }
- $uri .= $path;
- if ($query != '') {
- $uri .= '?' . $query;
- }
- if ($fragment != '') {
- $uri .= '#' . $fragment;
- }
- return $uri;
- }
- /**
- * Whether the URI has the default port of the current scheme.
- *
- * `Psr\Http\Message\UriInterface::getPort` may return null or the standard port. This method can be used
- * independently of the implementation.
- *
- * @param UriInterface $uri
- *
- * @return bool
- */
- public static function isDefaultPort(\Psr\Http\Message\UriInterface $uri)
- {
- return $uri->getPort() === null || isset(self::$defaultPorts[$uri->getScheme()]) && $uri->getPort() === self::$defaultPorts[$uri->getScheme()];
- }
- /**
- * Whether the URI is absolute, i.e. it has a scheme.
- *
- * An instance of UriInterface can either be an absolute URI or a relative reference. This method returns true
- * if it is the former. An absolute URI has a scheme. A relative reference is used to express a URI relative
- * to another URI, the base URI. Relative references can be divided into several forms:
- * - network-path references, e.g. '//example.com/path'
- * - absolute-path references, e.g. '/path'
- * - relative-path references, e.g. 'subpath'
- *
- * @param UriInterface $uri
- *
- * @return bool
- * @see Uri::isNetworkPathReference
- * @see Uri::isAbsolutePathReference
- * @see Uri::isRelativePathReference
- * @link https://tools.ietf.org/html/rfc3986#section-4
- */
- public static function isAbsolute(\Psr\Http\Message\UriInterface $uri)
- {
- return $uri->getScheme() !== '';
- }
- /**
- * Whether the URI is a network-path reference.
- *
- * A relative reference that begins with two slash characters is termed an network-path reference.
- *
- * @param UriInterface $uri
- *
- * @return bool
- * @link https://tools.ietf.org/html/rfc3986#section-4.2
- */
- public static function isNetworkPathReference(\Psr\Http\Message\UriInterface $uri)
- {
- return $uri->getScheme() === '' && $uri->getAuthority() !== '';
- }
- /**
- * Whether the URI is a absolute-path reference.
- *
- * A relative reference that begins with a single slash character is termed an absolute-path reference.
- *
- * @param UriInterface $uri
- *
- * @return bool
- * @link https://tools.ietf.org/html/rfc3986#section-4.2
- */
- public static function isAbsolutePathReference(\Psr\Http\Message\UriInterface $uri)
- {
- return $uri->getScheme() === '' && $uri->getAuthority() === '' && isset($uri->getPath()[0]) && $uri->getPath()[0] === '/';
- }
- /**
- * Whether the URI is a relative-path reference.
- *
- * A relative reference that does not begin with a slash character is termed a relative-path reference.
- *
- * @param UriInterface $uri
- *
- * @return bool
- * @link https://tools.ietf.org/html/rfc3986#section-4.2
- */
- public static function isRelativePathReference(\Psr\Http\Message\UriInterface $uri)
- {
- return $uri->getScheme() === '' && $uri->getAuthority() === '' && (!isset($uri->getPath()[0]) || $uri->getPath()[0] !== '/');
- }
- /**
- * Whether the URI is a same-document reference.
- *
- * A same-document reference refers to a URI that is, aside from its fragment
- * component, identical to the base URI. When no base URI is given, only an empty
- * URI reference (apart from its fragment) is considered a same-document reference.
- *
- * @param UriInterface $uri The URI to check
- * @param UriInterface|null $base An optional base URI to compare against
- *
- * @return bool
- * @link https://tools.ietf.org/html/rfc3986#section-4.4
- */
- public static function isSameDocumentReference(\Psr\Http\Message\UriInterface $uri, \Psr\Http\Message\UriInterface $base = null)
- {
- if ($base !== null) {
- $uri = \PayNL\GuzzleHttp\Psr7\UriResolver::resolve($base, $uri);
- return $uri->getScheme() === $base->getScheme() && $uri->getAuthority() === $base->getAuthority() && $uri->getPath() === $base->getPath() && $uri->getQuery() === $base->getQuery();
- }
- return $uri->getScheme() === '' && $uri->getAuthority() === '' && $uri->getPath() === '' && $uri->getQuery() === '';
- }
- /**
- * Removes dot segments from a path and returns the new path.
- *
- * @param string $path
- *
- * @return string
- *
- * @deprecated since version 1.4. Use UriResolver::removeDotSegments instead.
- * @see UriResolver::removeDotSegments
- */
- public static function removeDotSegments($path)
- {
- return \PayNL\GuzzleHttp\Psr7\UriResolver::removeDotSegments($path);
- }
- /**
- * Converts the relative URI into a new URI that is resolved against the base URI.
- *
- * @param UriInterface $base Base URI
- * @param string|UriInterface $rel Relative URI
- *
- * @return UriInterface
- *
- * @deprecated since version 1.4. Use UriResolver::resolve instead.
- * @see UriResolver::resolve
- */
- public static function resolve(\Psr\Http\Message\UriInterface $base, $rel)
- {
- if (!$rel instanceof \Psr\Http\Message\UriInterface) {
- $rel = new self($rel);
- }
- return \PayNL\GuzzleHttp\Psr7\UriResolver::resolve($base, $rel);
- }
- /**
- * Creates a new URI with a specific query string value removed.
- *
- * Any existing query string values that exactly match the provided key are
- * removed.
- *
- * @param UriInterface $uri URI to use as a base.
- * @param string $key Query string key to remove.
- *
- * @return UriInterface
- */
- public static function withoutQueryValue(\Psr\Http\Message\UriInterface $uri, $key)
- {
- $result = self::getFilteredQueryString($uri, [$key]);
- return $uri->withQuery(\implode('&', $result));
- }
- /**
- * Creates a new URI with a specific query string value.
- *
- * Any existing query string values that exactly match the provided key are
- * removed and replaced with the given key value pair.
- *
- * A value of null will set the query string key without a value, e.g. "key"
- * instead of "key=value".
- *
- * @param UriInterface $uri URI to use as a base.
- * @param string $key Key to set.
- * @param string|null $value Value to set
- *
- * @return UriInterface
- */
- public static function withQueryValue(\Psr\Http\Message\UriInterface $uri, $key, $value)
- {
- $result = self::getFilteredQueryString($uri, [$key]);
- $result[] = self::generateQueryString($key, $value);
- return $uri->withQuery(\implode('&', $result));
- }
- /**
- * Creates a new URI with multiple specific query string values.
- *
- * It has the same behavior as withQueryValue() but for an associative array of key => value.
- *
- * @param UriInterface $uri URI to use as a base.
- * @param array $keyValueArray Associative array of key and values
- *
- * @return UriInterface
- */
- public static function withQueryValues(\Psr\Http\Message\UriInterface $uri, array $keyValueArray)
- {
- $result = self::getFilteredQueryString($uri, \array_keys($keyValueArray));
- foreach ($keyValueArray as $key => $value) {
- $result[] = self::generateQueryString($key, $value);
- }
- return $uri->withQuery(\implode('&', $result));
- }
- /**
- * Creates a URI from a hash of `parse_url` components.
- *
- * @param array $parts
- *
- * @return UriInterface
- * @link http://php.net/manual/en/function.parse-url.php
- *
- * @throws \InvalidArgumentException If the components do not form a valid URI.
- */
- public static function fromParts(array $parts)
- {
- $uri = new self();
- $uri->applyParts($parts);
- $uri->validateState();
- return $uri;
- }
- public function getScheme()
- {
- return $this->scheme;
- }
- public function getAuthority()
- {
- $authority = $this->host;
- if ($this->userInfo !== '') {
- $authority = $this->userInfo . '@' . $authority;
- }
- if ($this->port !== null) {
- $authority .= ':' . $this->port;
- }
- return $authority;
- }
- public function getUserInfo()
- {
- return $this->userInfo;
- }
- public function getHost()
- {
- return $this->host;
- }
- public function getPort()
- {
- return $this->port;
- }
- public function getPath()
- {
- return $this->path;
- }
- public function getQuery()
- {
- return $this->query;
- }
- public function getFragment()
- {
- return $this->fragment;
- }
- public function withScheme($scheme)
- {
- $scheme = $this->filterScheme($scheme);
- if ($this->scheme === $scheme) {
- return $this;
- }
- $new = clone $this;
- $new->scheme = $scheme;
- $new->removeDefaultPort();
- $new->validateState();
- return $new;
- }
- public function withUserInfo($user, $password = null)
- {
- $info = $this->filterUserInfoComponent($user);
- if ($password !== null) {
- $info .= ':' . $this->filterUserInfoComponent($password);
- }
- if ($this->userInfo === $info) {
- return $this;
- }
- $new = clone $this;
- $new->userInfo = $info;
- $new->validateState();
- return $new;
- }
- public function withHost($host)
- {
- $host = $this->filterHost($host);
- if ($this->host === $host) {
- return $this;
- }
- $new = clone $this;
- $new->host = $host;
- $new->validateState();
- return $new;
- }
- public function withPort($port)
- {
- $port = $this->filterPort($port);
- if ($this->port === $port) {
- return $this;
- }
- $new = clone $this;
- $new->port = $port;
- $new->removeDefaultPort();
- $new->validateState();
- return $new;
- }
- public function withPath($path)
- {
- $path = $this->filterPath($path);
- if ($this->path === $path) {
- return $this;
- }
- $new = clone $this;
- $new->path = $path;
- $new->validateState();
- return $new;
- }
- public function withQuery($query)
- {
- $query = $this->filterQueryAndFragment($query);
- if ($this->query === $query) {
- return $this;
- }
- $new = clone $this;
- $new->query = $query;
- return $new;
- }
- public function withFragment($fragment)
- {
- $fragment = $this->filterQueryAndFragment($fragment);
- if ($this->fragment === $fragment) {
- return $this;
- }
- $new = clone $this;
- $new->fragment = $fragment;
- return $new;
- }
- /**
- * Apply parse_url parts to a URI.
- *
- * @param array $parts Array of parse_url parts to apply.
- */
- private function applyParts(array $parts)
- {
- $this->scheme = isset($parts['scheme']) ? $this->filterScheme($parts['scheme']) : '';
- $this->userInfo = isset($parts['user']) ? $this->filterUserInfoComponent($parts['user']) : '';
- $this->host = isset($parts['host']) ? $this->filterHost($parts['host']) : '';
- $this->port = isset($parts['port']) ? $this->filterPort($parts['port']) : null;
- $this->path = isset($parts['path']) ? $this->filterPath($parts['path']) : '';
- $this->query = isset($parts['query']) ? $this->filterQueryAndFragment($parts['query']) : '';
- $this->fragment = isset($parts['fragment']) ? $this->filterQueryAndFragment($parts['fragment']) : '';
- if (isset($parts['pass'])) {
- $this->userInfo .= ':' . $this->filterUserInfoComponent($parts['pass']);
- }
- $this->removeDefaultPort();
- }
- /**
- * @param string $scheme
- *
- * @return string
- *
- * @throws \InvalidArgumentException If the scheme is invalid.
- */
- private function filterScheme($scheme)
- {
- if (!\is_string($scheme)) {
- throw new \InvalidArgumentException('Scheme must be a string');
- }
- return \strtolower($scheme);
- }
- /**
- * @param string $component
- *
- * @return string
- *
- * @throws \InvalidArgumentException If the user info is invalid.
- */
- private function filterUserInfoComponent($component)
- {
- if (!\is_string($component)) {
- throw new \InvalidArgumentException('User info must be a string');
- }
- return \preg_replace_callback('/(?:[^%' . self::$charUnreserved . self::$charSubDelims . ']+|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $component);
- }
- /**
- * @param string $host
- *
- * @return string
- *
- * @throws \InvalidArgumentException If the host is invalid.
- */
- private function filterHost($host)
- {
- if (!\is_string($host)) {
- throw new \InvalidArgumentException('Host must be a string');
- }
- return \strtolower($host);
- }
- /**
- * @param int|null $port
- *
- * @return int|null
- *
- * @throws \InvalidArgumentException If the port is invalid.
- */
- private function filterPort($port)
- {
- if ($port === null) {
- return null;
- }
- $port = (int) $port;
- if (0 > $port || 0xffff < $port) {
- throw new \InvalidArgumentException(\sprintf('Invalid port: %d. Must be between 0 and 65535', $port));
- }
- return $port;
- }
- /**
- * @param UriInterface $uri
- * @param array $keys
- *
- * @return array
- */
- private static function getFilteredQueryString(\Psr\Http\Message\UriInterface $uri, array $keys)
- {
- $current = $uri->getQuery();
- if ($current === '') {
- return [];
- }
- $decodedKeys = \array_map('rawurldecode', $keys);
- return \array_filter(\explode('&', $current), function ($part) use($decodedKeys) {
- return !\in_array(\rawurldecode(\explode('=', $part)[0]), $decodedKeys, \true);
- });
- }
- /**
- * @param string $key
- * @param string|null $value
- *
- * @return string
- */
- private static function generateQueryString($key, $value)
- {
- // Query string separators ("=", "&") within the key or value need to be encoded
- // (while preventing double-encoding) before setting the query string. All other
- // chars that need percent-encoding will be encoded by withQuery().
- $queryString = \strtr($key, self::$replaceQuery);
- if ($value !== null) {
- $queryString .= '=' . \strtr($value, self::$replaceQuery);
- }
- return $queryString;
- }
- private function removeDefaultPort()
- {
- if ($this->port !== null && self::isDefaultPort($this)) {
- $this->port = null;
- }
- }
- /**
- * Filters the path of a URI
- *
- * @param string $path
- *
- * @return string
- *
- * @throws \InvalidArgumentException If the path is invalid.
- */
- private function filterPath($path)
- {
- if (!\is_string($path)) {
- throw new \InvalidArgumentException('Path must be a string');
- }
- return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $path);
- }
- /**
- * Filters the query string or fragment of a URI.
- *
- * @param string $str
- *
- * @return string
- *
- * @throws \InvalidArgumentException If the query or fragment is invalid.
- */
- private function filterQueryAndFragment($str)
- {
- if (!\is_string($str)) {
- throw new \InvalidArgumentException('Query and fragment must be a string');
- }
- return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/\\?]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $str);
- }
- private function rawurlencodeMatchZero(array $match)
- {
- return \rawurlencode($match[0]);
- }
- private function validateState()
- {
- if ($this->host === '' && ($this->scheme === 'http' || $this->scheme === 'https')) {
- $this->host = self::HTTP_DEFAULT_HOST;
- }
- if ($this->getAuthority() === '') {
- if (0 === \strpos($this->path, '//')) {
- throw new \InvalidArgumentException('The path of a URI without an authority must not start with two slashes "//"');
- }
- if ($this->scheme === '' && \false !== \strpos(\explode('/', $this->path, 2)[0], ':')) {
- throw new \InvalidArgumentException('A relative URI must not have a path beginning with a segment containing a colon');
- }
- } elseif (isset($this->path[0]) && $this->path[0] !== '/') {
- @\trigger_error('The path of a URI with an authority must start with a slash "/" or be empty. Automagically fixing the URI ' . 'by adding a leading slash to the path is deprecated since version 1.4 and will throw an exception instead.', \E_USER_DEPRECATED);
- $this->path = '/' . $this->path;
- //throw new \InvalidArgumentException('The path of a URI with an authority must start with a slash "/" or be empty');
- }
- }
-}
diff --git a/build/psr7/src/UriNormalizer.php b/build/psr7/src/UriNormalizer.php
deleted file mode 100644
index b47e4c7..0000000
--- a/build/psr7/src/UriNormalizer.php
+++ /dev/null
@@ -1,179 +0,0 @@
-getPath() === '' && ($uri->getScheme() === 'http' || $uri->getScheme() === 'https')) {
- $uri = $uri->withPath('/');
- }
- if ($flags & self::REMOVE_DEFAULT_HOST && $uri->getScheme() === 'file' && $uri->getHost() === 'localhost') {
- $uri = $uri->withHost('');
- }
- if ($flags & self::REMOVE_DEFAULT_PORT && $uri->getPort() !== null && \PayNL\GuzzleHttp\Psr7\Uri::isDefaultPort($uri)) {
- $uri = $uri->withPort(null);
- }
- if ($flags & self::REMOVE_DOT_SEGMENTS && !\PayNL\GuzzleHttp\Psr7\Uri::isRelativePathReference($uri)) {
- $uri = $uri->withPath(\PayNL\GuzzleHttp\Psr7\UriResolver::removeDotSegments($uri->getPath()));
- }
- if ($flags & self::REMOVE_DUPLICATE_SLASHES) {
- $uri = $uri->withPath(\preg_replace('#//++#', '/', $uri->getPath()));
- }
- if ($flags & self::SORT_QUERY_PARAMETERS && $uri->getQuery() !== '') {
- $queryKeyValues = \explode('&', $uri->getQuery());
- \sort($queryKeyValues);
- $uri = $uri->withQuery(\implode('&', $queryKeyValues));
- }
- return $uri;
- }
- /**
- * Whether two URIs can be considered equivalent.
- *
- * Both URIs are normalized automatically before comparison with the given $normalizations bitmask. The method also
- * accepts relative URI references and returns true when they are equivalent. This of course assumes they will be
- * resolved against the same base URI. If this is not the case, determination of equivalence or difference of
- * relative references does not mean anything.
- *
- * @param UriInterface $uri1 An URI to compare
- * @param UriInterface $uri2 An URI to compare
- * @param int $normalizations A bitmask of normalizations to apply, see constants
- *
- * @return bool
- * @link https://tools.ietf.org/html/rfc3986#section-6.1
- */
- public static function isEquivalent(\Psr\Http\Message\UriInterface $uri1, \Psr\Http\Message\UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS)
- {
- return (string) self::normalize($uri1, $normalizations) === (string) self::normalize($uri2, $normalizations);
- }
- private static function capitalizePercentEncoding(\Psr\Http\Message\UriInterface $uri)
- {
- $regex = '/(?:%[A-Fa-f0-9]{2})++/';
- $callback = function (array $match) {
- return \strtoupper($match[0]);
- };
- return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery()));
- }
- private static function decodeUnreservedCharacters(\Psr\Http\Message\UriInterface $uri)
- {
- $regex = '/%(?:2D|2E|5F|7E|3[0-9]|[46][1-9A-F]|[57][0-9A])/i';
- $callback = function (array $match) {
- return \rawurldecode($match[0]);
- };
- return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery()));
- }
- private function __construct()
- {
- // cannot be instantiated
- }
-}
diff --git a/build/psr7/src/UriResolver.php b/build/psr7/src/UriResolver.php
deleted file mode 100644
index e0d0758..0000000
--- a/build/psr7/src/UriResolver.php
+++ /dev/null
@@ -1,190 +0,0 @@
-getScheme() != '') {
- return $rel->withPath(self::removeDotSegments($rel->getPath()));
- }
- if ($rel->getAuthority() != '') {
- $targetAuthority = $rel->getAuthority();
- $targetPath = self::removeDotSegments($rel->getPath());
- $targetQuery = $rel->getQuery();
- } else {
- $targetAuthority = $base->getAuthority();
- if ($rel->getPath() === '') {
- $targetPath = $base->getPath();
- $targetQuery = $rel->getQuery() != '' ? $rel->getQuery() : $base->getQuery();
- } else {
- if ($rel->getPath()[0] === '/') {
- $targetPath = $rel->getPath();
- } else {
- if ($targetAuthority != '' && $base->getPath() === '') {
- $targetPath = '/' . $rel->getPath();
- } else {
- $lastSlashPos = \strrpos($base->getPath(), '/');
- if ($lastSlashPos === \false) {
- $targetPath = $rel->getPath();
- } else {
- $targetPath = \substr($base->getPath(), 0, $lastSlashPos + 1) . $rel->getPath();
- }
- }
- }
- $targetPath = self::removeDotSegments($targetPath);
- $targetQuery = $rel->getQuery();
- }
- }
- return new \PayNL\GuzzleHttp\Psr7\Uri(\PayNL\GuzzleHttp\Psr7\Uri::composeComponents($base->getScheme(), $targetAuthority, $targetPath, $targetQuery, $rel->getFragment()));
- }
- /**
- * Returns the target URI as a relative reference from the base URI.
- *
- * This method is the counterpart to resolve():
- *
- * (string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target))
- *
- * One use-case is to use the current request URI as base URI and then generate relative links in your documents
- * to reduce the document size or offer self-contained downloadable document archives.
- *
- * $base = new Uri('http://example.com/a/b/');
- * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'.
- * echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'.
- * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'.
- * echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'.
- *
- * This method also accepts a target that is already relative and will try to relativize it further. Only a
- * relative-path reference will be returned as-is.
- *
- * echo UriResolver::relativize($base, new Uri('/a/b/c')); // prints 'c' as well
- *
- * @param UriInterface $base Base URI
- * @param UriInterface $target Target URI
- *
- * @return UriInterface The relative URI reference
- */
- public static function relativize(\Psr\Http\Message\UriInterface $base, \Psr\Http\Message\UriInterface $target)
- {
- if ($target->getScheme() !== '' && ($base->getScheme() !== $target->getScheme() || $target->getAuthority() === '' && $base->getAuthority() !== '')) {
- return $target;
- }
- if (\PayNL\GuzzleHttp\Psr7\Uri::isRelativePathReference($target)) {
- // As the target is already highly relative we return it as-is. It would be possible to resolve
- // the target with `$target = self::resolve($base, $target);` and then try make it more relative
- // by removing a duplicate query. But let's not do that automatically.
- return $target;
- }
- if ($target->getAuthority() !== '' && $base->getAuthority() !== $target->getAuthority()) {
- return $target->withScheme('');
- }
- // We must remove the path before removing the authority because if the path starts with two slashes, the URI
- // would turn invalid. And we also cannot set a relative path before removing the authority, as that is also
- // invalid.
- $emptyPathUri = $target->withScheme('')->withPath('')->withUserInfo('')->withPort(null)->withHost('');
- if ($base->getPath() !== $target->getPath()) {
- return $emptyPathUri->withPath(self::getRelativePath($base, $target));
- }
- if ($base->getQuery() === $target->getQuery()) {
- // Only the target fragment is left. And it must be returned even if base and target fragment are the same.
- return $emptyPathUri->withQuery('');
- }
- // If the base URI has a query but the target has none, we cannot return an empty path reference as it would
- // inherit the base query component when resolving.
- if ($target->getQuery() === '') {
- $segments = \explode('/', $target->getPath());
- $lastSegment = \end($segments);
- return $emptyPathUri->withPath($lastSegment === '' ? './' : $lastSegment);
- }
- return $emptyPathUri;
- }
- private static function getRelativePath(\Psr\Http\Message\UriInterface $base, \Psr\Http\Message\UriInterface $target)
- {
- $sourceSegments = \explode('/', $base->getPath());
- $targetSegments = \explode('/', $target->getPath());
- \array_pop($sourceSegments);
- $targetLastSegment = \array_pop($targetSegments);
- foreach ($sourceSegments as $i => $segment) {
- if (isset($targetSegments[$i]) && $segment === $targetSegments[$i]) {
- unset($sourceSegments[$i], $targetSegments[$i]);
- } else {
- break;
- }
- }
- $targetSegments[] = $targetLastSegment;
- $relativePath = \str_repeat('../', \count($sourceSegments)) . \implode('/', $targetSegments);
- // A reference to am empty last segment or an empty first sub-segment must be prefixed with "./".
- // This also applies to a segment with a colon character (e.g., "file:colon") that cannot be used
- // as the first segment of a relative-path reference, as it would be mistaken for a scheme name.
- if ('' === $relativePath || \false !== \strpos(\explode('/', $relativePath, 2)[0], ':')) {
- $relativePath = "./{$relativePath}";
- } elseif ('/' === $relativePath[0]) {
- if ($base->getAuthority() != '' && $base->getPath() === '') {
- // In this case an extra slash is added by resolve() automatically. So we must not add one here.
- $relativePath = ".{$relativePath}";
- } else {
- $relativePath = "./{$relativePath}";
- }
- }
- return $relativePath;
- }
- private function __construct()
- {
- // cannot be instantiated
- }
-}
diff --git a/build/psr7/src/functions.php b/build/psr7/src/functions.php
deleted file mode 100644
index 73613ce..0000000
--- a/build/psr7/src/functions.php
+++ /dev/null
@@ -1,657 +0,0 @@
-getMethod() . ' ' . $message->getRequestTarget()) . ' HTTP/' . $message->getProtocolVersion();
- if (!$message->hasHeader('host')) {
- $msg .= "\r\nHost: " . $message->getUri()->getHost();
- }
- } elseif ($message instanceof \Psr\Http\Message\ResponseInterface) {
- $msg = 'HTTP/' . $message->getProtocolVersion() . ' ' . $message->getStatusCode() . ' ' . $message->getReasonPhrase();
- } else {
- throw new \InvalidArgumentException('Unknown message type');
- }
- foreach ($message->getHeaders() as $name => $values) {
- $msg .= "\r\n{$name}: " . \implode(', ', $values);
- }
- return "{$msg}\r\n\r\n" . $message->getBody();
-}
-/**
- * Returns a UriInterface for the given value.
- *
- * This function accepts a string or {@see Psr\Http\Message\UriInterface} and
- * returns a UriInterface for the given value. If the value is already a
- * `UriInterface`, it is returned as-is.
- *
- * @param string|UriInterface $uri
- *
- * @return UriInterface
- * @throws \InvalidArgumentException
- */
-function uri_for($uri)
-{
- if ($uri instanceof \Psr\Http\Message\UriInterface) {
- return $uri;
- } elseif (\is_string($uri)) {
- return new \PayNL\GuzzleHttp\Psr7\Uri($uri);
- }
- throw new \InvalidArgumentException('URI must be a string or UriInterface');
-}
-/**
- * Create a new stream based on the input type.
- *
- * Options is an associative array that can contain the following keys:
- * - metadata: Array of custom metadata.
- * - size: Size of the stream.
- *
- * @param resource|string|null|int|float|bool|StreamInterface|callable|\Iterator $resource Entity body data
- * @param array $options Additional options
- *
- * @return StreamInterface
- * @throws \InvalidArgumentException if the $resource arg is not valid.
- */
-function stream_for($resource = '', array $options = [])
-{
- if (\is_scalar($resource)) {
- $stream = \fopen('php://temp', 'r+');
- if ($resource !== '') {
- \fwrite($stream, $resource);
- \fseek($stream, 0);
- }
- return new \PayNL\GuzzleHttp\Psr7\Stream($stream, $options);
- }
- switch (\gettype($resource)) {
- case 'resource':
- return new \PayNL\GuzzleHttp\Psr7\Stream($resource, $options);
- case 'object':
- if ($resource instanceof \Psr\Http\Message\StreamInterface) {
- return $resource;
- } elseif ($resource instanceof \Iterator) {
- return new \PayNL\GuzzleHttp\Psr7\PumpStream(function () use($resource) {
- if (!$resource->valid()) {
- return \false;
- }
- $result = $resource->current();
- $resource->next();
- return $result;
- }, $options);
- } elseif (\method_exists($resource, '__toString')) {
- return stream_for((string) $resource, $options);
- }
- break;
- case 'NULL':
- return new \PayNL\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+'), $options);
- }
- if (\is_callable($resource)) {
- return new \PayNL\GuzzleHttp\Psr7\PumpStream($resource, $options);
- }
- throw new \InvalidArgumentException('Invalid resource type: ' . \gettype($resource));
-}
-/**
- * Parse an array of header values containing ";" separated data into an
- * array of associative arrays representing the header key value pair
- * data of the header. When a parameter does not contain a value, but just
- * contains a key, this function will inject a key with a '' string value.
- *
- * @param string|array $header Header to parse into components.
- *
- * @return array Returns the parsed header values.
- */
-function parse_header($header)
-{
- static $trimmed = "\"' \n\t\r";
- $params = $matches = [];
- foreach (normalize_header($header) as $val) {
- $part = [];
- foreach (\preg_split('/;(?=([^"]*"[^"]*")*[^"]*$)/', $val) as $kvp) {
- if (\preg_match_all('/<[^>]+>|[^=]+/', $kvp, $matches)) {
- $m = $matches[0];
- if (isset($m[1])) {
- $part[\trim($m[0], $trimmed)] = \trim($m[1], $trimmed);
- } else {
- $part[] = \trim($m[0], $trimmed);
- }
- }
- }
- if ($part) {
- $params[] = $part;
- }
- }
- return $params;
-}
-/**
- * Converts an array of header values that may contain comma separated
- * headers into an array of headers with no comma separated values.
- *
- * @param string|array $header Header to normalize.
- *
- * @return array Returns the normalized header field values.
- */
-function normalize_header($header)
-{
- if (!\is_array($header)) {
- return \array_map('trim', \explode(',', $header));
- }
- $result = [];
- foreach ($header as $value) {
- foreach ((array) $value as $v) {
- if (\strpos($v, ',') === \false) {
- $result[] = $v;
- continue;
- }
- foreach (\preg_split('/,(?=([^"]*"[^"]*")*[^"]*$)/', $v) as $vv) {
- $result[] = \trim($vv);
- }
- }
- }
- return $result;
-}
-/**
- * Clone and modify a request with the given changes.
- *
- * The changes can be one of:
- * - method: (string) Changes the HTTP method.
- * - set_headers: (array) Sets the given headers.
- * - remove_headers: (array) Remove the given headers.
- * - body: (mixed) Sets the given body.
- * - uri: (UriInterface) Set the URI.
- * - query: (string) Set the query string value of the URI.
- * - version: (string) Set the protocol version.
- *
- * @param RequestInterface $request Request to clone and modify.
- * @param array $changes Changes to apply.
- *
- * @return RequestInterface
- */
-function modify_request(\Psr\Http\Message\RequestInterface $request, array $changes)
-{
- if (!$changes) {
- return $request;
- }
- $headers = $request->getHeaders();
- if (!isset($changes['uri'])) {
- $uri = $request->getUri();
- } else {
- // Remove the host header if one is on the URI
- if ($host = $changes['uri']->getHost()) {
- $changes['set_headers']['Host'] = $host;
- if ($port = $changes['uri']->getPort()) {
- $standardPorts = ['http' => 80, 'https' => 443];
- $scheme = $changes['uri']->getScheme();
- if (isset($standardPorts[$scheme]) && $port != $standardPorts[$scheme]) {
- $changes['set_headers']['Host'] .= ':' . $port;
- }
- }
- }
- $uri = $changes['uri'];
- }
- if (!empty($changes['remove_headers'])) {
- $headers = _caseless_remove($changes['remove_headers'], $headers);
- }
- if (!empty($changes['set_headers'])) {
- $headers = _caseless_remove(\array_keys($changes['set_headers']), $headers);
- $headers = $changes['set_headers'] + $headers;
- }
- if (isset($changes['query'])) {
- $uri = $uri->withQuery($changes['query']);
- }
- if ($request instanceof \Psr\Http\Message\ServerRequestInterface) {
- return (new \PayNL\GuzzleHttp\Psr7\ServerRequest(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion(), $request->getServerParams()))->withParsedBody($request->getParsedBody())->withQueryParams($request->getQueryParams())->withCookieParams($request->getCookieParams())->withUploadedFiles($request->getUploadedFiles());
- }
- return new \PayNL\GuzzleHttp\Psr7\Request(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion());
-}
-/**
- * Attempts to rewind a message body and throws an exception on failure.
- *
- * The body of the message will only be rewound if a call to `tell()` returns a
- * value other than `0`.
- *
- * @param MessageInterface $message Message to rewind
- *
- * @throws \RuntimeException
- */
-function rewind_body(\Psr\Http\Message\MessageInterface $message)
-{
- $body = $message->getBody();
- if ($body->tell()) {
- $body->rewind();
- }
-}
-/**
- * Safely opens a PHP stream resource using a filename.
- *
- * When fopen fails, PHP normally raises a warning. This function adds an
- * error handler that checks for errors and throws an exception instead.
- *
- * @param string $filename File to open
- * @param string $mode Mode used to open the file
- *
- * @return resource
- * @throws \RuntimeException if the file cannot be opened
- */
-function try_fopen($filename, $mode)
-{
- $ex = null;
- \set_error_handler(function () use($filename, $mode, &$ex) {
- $ex = new \RuntimeException(\sprintf('Unable to open %s using mode %s: %s', $filename, $mode, \func_get_args()[1]));
- });
- $handle = \fopen($filename, $mode);
- \restore_error_handler();
- if ($ex) {
- /** @var $ex \RuntimeException */
- throw $ex;
- }
- return $handle;
-}
-/**
- * Copy the contents of a stream into a string until the given number of
- * bytes have been read.
- *
- * @param StreamInterface $stream Stream to read
- * @param int $maxLen Maximum number of bytes to read. Pass -1
- * to read the entire stream.
- * @return string
- * @throws \RuntimeException on error.
- */
-function copy_to_string(\Psr\Http\Message\StreamInterface $stream, $maxLen = -1)
-{
- $buffer = '';
- if ($maxLen === -1) {
- while (!$stream->eof()) {
- $buf = $stream->read(1048576);
- // Using a loose equality here to match on '' and false.
- if ($buf == null) {
- break;
- }
- $buffer .= $buf;
- }
- return $buffer;
- }
- $len = 0;
- while (!$stream->eof() && $len < $maxLen) {
- $buf = $stream->read($maxLen - $len);
- // Using a loose equality here to match on '' and false.
- if ($buf == null) {
- break;
- }
- $buffer .= $buf;
- $len = \strlen($buffer);
- }
- return $buffer;
-}
-/**
- * Copy the contents of a stream into another stream until the given number
- * of bytes have been read.
- *
- * @param StreamInterface $source Stream to read from
- * @param StreamInterface $dest Stream to write to
- * @param int $maxLen Maximum number of bytes to read. Pass -1
- * to read the entire stream.
- *
- * @throws \RuntimeException on error.
- */
-function copy_to_stream(\Psr\Http\Message\StreamInterface $source, \Psr\Http\Message\StreamInterface $dest, $maxLen = -1)
-{
- $bufferSize = 8192;
- if ($maxLen === -1) {
- while (!$source->eof()) {
- if (!$dest->write($source->read($bufferSize))) {
- break;
- }
- }
- } else {
- $remaining = $maxLen;
- while ($remaining > 0 && !$source->eof()) {
- $buf = $source->read(\min($bufferSize, $remaining));
- $len = \strlen($buf);
- if (!$len) {
- break;
- }
- $remaining -= $len;
- $dest->write($buf);
- }
- }
-}
-/**
- * Calculate a hash of a Stream
- *
- * @param StreamInterface $stream Stream to calculate the hash for
- * @param string $algo Hash algorithm (e.g. md5, crc32, etc)
- * @param bool $rawOutput Whether or not to use raw output
- *
- * @return string Returns the hash of the stream
- * @throws \RuntimeException on error.
- */
-function hash(\Psr\Http\Message\StreamInterface $stream, $algo, $rawOutput = \false)
-{
- $pos = $stream->tell();
- if ($pos > 0) {
- $stream->rewind();
- }
- $ctx = \hash_init($algo);
- while (!$stream->eof()) {
- \hash_update($ctx, $stream->read(1048576));
- }
- $out = \hash_final($ctx, (bool) $rawOutput);
- $stream->seek($pos);
- return $out;
-}
-/**
- * Read a line from the stream up to the maximum allowed buffer length
- *
- * @param StreamInterface $stream Stream to read from
- * @param int $maxLength Maximum buffer length
- *
- * @return string
- */
-function readline(\Psr\Http\Message\StreamInterface $stream, $maxLength = null)
-{
- $buffer = '';
- $size = 0;
- while (!$stream->eof()) {
- // Using a loose equality here to match on '' and false.
- if (null == ($byte = $stream->read(1))) {
- return $buffer;
- }
- $buffer .= $byte;
- // Break when a new line is found or the max length - 1 is reached
- if ($byte === "\n" || ++$size === $maxLength - 1) {
- break;
- }
- }
- return $buffer;
-}
-/**
- * Parses a request message string into a request object.
- *
- * @param string $message Request message string.
- *
- * @return Request
- */
-function parse_request($message)
-{
- $data = _parse_message($message);
- $matches = [];
- if (!\preg_match('/^[\\S]+\\s+([a-zA-Z]+:\\/\\/|\\/).*/', $data['start-line'], $matches)) {
- throw new \InvalidArgumentException('Invalid request string');
- }
- $parts = \explode(' ', $data['start-line'], 3);
- $version = isset($parts[2]) ? \explode('/', $parts[2])[1] : '1.1';
- $request = new \PayNL\GuzzleHttp\Psr7\Request($parts[0], $matches[1] === '/' ? _parse_request_uri($parts[1], $data['headers']) : $parts[1], $data['headers'], $data['body'], $version);
- return $matches[1] === '/' ? $request : $request->withRequestTarget($parts[1]);
-}
-/**
- * Parses a response message string into a response object.
- *
- * @param string $message Response message string.
- *
- * @return Response
- */
-function parse_response($message)
-{
- $data = _parse_message($message);
- // According to https://tools.ietf.org/html/rfc7230#section-3.1.2 the space
- // between status-code and reason-phrase is required. But browsers accept
- // responses without space and reason as well.
- if (!\preg_match('/^HTTP\\/.* [0-9]{3}( .*|$)/', $data['start-line'])) {
- throw new \InvalidArgumentException('Invalid response string: ' . $data['start-line']);
- }
- $parts = \explode(' ', $data['start-line'], 3);
- return new \PayNL\GuzzleHttp\Psr7\Response($parts[1], $data['headers'], $data['body'], \explode('/', $parts[0])[1], isset($parts[2]) ? $parts[2] : null);
-}
-/**
- * Parse a query string into an associative array.
- *
- * If multiple values are found for the same key, the value of that key
- * value pair will become an array. This function does not parse nested
- * PHP style arrays into an associative array (e.g., foo[a]=1&foo[b]=2 will
- * be parsed into ['foo[a]' => '1', 'foo[b]' => '2']).
- *
- * @param string $str Query string to parse
- * @param int|bool $urlEncoding How the query string is encoded
- *
- * @return array
- */
-function parse_query($str, $urlEncoding = \true)
-{
- $result = [];
- if ($str === '') {
- return $result;
- }
- if ($urlEncoding === \true) {
- $decoder = function ($value) {
- return \rawurldecode(\str_replace('+', ' ', $value));
- };
- } elseif ($urlEncoding === \PHP_QUERY_RFC3986) {
- $decoder = 'rawurldecode';
- } elseif ($urlEncoding === \PHP_QUERY_RFC1738) {
- $decoder = 'urldecode';
- } else {
- $decoder = function ($str) {
- return $str;
- };
- }
- foreach (\explode('&', $str) as $kvp) {
- $parts = \explode('=', $kvp, 2);
- $key = $decoder($parts[0]);
- $value = isset($parts[1]) ? $decoder($parts[1]) : null;
- if (!isset($result[$key])) {
- $result[$key] = $value;
- } else {
- if (!\is_array($result[$key])) {
- $result[$key] = [$result[$key]];
- }
- $result[$key][] = $value;
- }
- }
- return $result;
-}
-/**
- * Build a query string from an array of key value pairs.
- *
- * This function can use the return value of parse_query() to build a query
- * string. This function does not modify the provided keys when an array is
- * encountered (like http_build_query would).
- *
- * @param array $params Query string parameters.
- * @param int|false $encoding Set to false to not encode, PHP_QUERY_RFC3986
- * to encode using RFC3986, or PHP_QUERY_RFC1738
- * to encode using RFC1738.
- * @return string
- */
-function build_query(array $params, $encoding = \PHP_QUERY_RFC3986)
-{
- if (!$params) {
- return '';
- }
- if ($encoding === \false) {
- $encoder = function ($str) {
- return $str;
- };
- } elseif ($encoding === \PHP_QUERY_RFC3986) {
- $encoder = 'rawurlencode';
- } elseif ($encoding === \PHP_QUERY_RFC1738) {
- $encoder = 'urlencode';
- } else {
- throw new \InvalidArgumentException('Invalid type');
- }
- $qs = '';
- foreach ($params as $k => $v) {
- $k = $encoder($k);
- if (!\is_array($v)) {
- $qs .= $k;
- if ($v !== null) {
- $qs .= '=' . $encoder($v);
- }
- $qs .= '&';
- } else {
- foreach ($v as $vv) {
- $qs .= $k;
- if ($vv !== null) {
- $qs .= '=' . $encoder($vv);
- }
- $qs .= '&';
- }
- }
- }
- return $qs ? (string) \substr($qs, 0, -1) : '';
-}
-/**
- * Determines the mimetype of a file by looking at its extension.
- *
- * @param $filename
- *
- * @return null|string
- */
-function mimetype_from_filename($filename)
-{
- return mimetype_from_extension(\pathinfo($filename, \PATHINFO_EXTENSION));
-}
-/**
- * Maps a file extensions to a mimetype.
- *
- * @param $extension string The file extension.
- *
- * @return string|null
- * @link http://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x/conf/mime.types
- */
-function mimetype_from_extension($extension)
-{
- static $mimetypes = ['3gp' => 'video/3gpp', '7z' => 'application/x-7z-compressed', 'aac' => 'audio/x-aac', 'ai' => 'application/postscript', 'aif' => 'audio/x-aiff', 'asc' => 'text/plain', 'asf' => 'video/x-ms-asf', 'atom' => 'application/atom+xml', 'avi' => 'video/x-msvideo', 'bmp' => 'image/bmp', 'bz2' => 'application/x-bzip2', 'cer' => 'application/pkix-cert', 'crl' => 'application/pkix-crl', 'crt' => 'application/x-x509-ca-cert', 'css' => 'text/css', 'csv' => 'text/csv', 'cu' => 'application/cu-seeme', 'deb' => 'application/x-debian-package', 'doc' => 'application/msword', 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'dvi' => 'application/x-dvi', 'eot' => 'application/vnd.ms-fontobject', 'eps' => 'application/postscript', 'epub' => 'application/epub+zip', 'etx' => 'text/x-setext', 'flac' => 'audio/flac', 'flv' => 'video/x-flv', 'gif' => 'image/gif', 'gz' => 'application/gzip', 'htm' => 'text/html', 'html' => 'text/html', 'ico' => 'image/x-icon', 'ics' => 'text/calendar', 'ini' => 'text/plain', 'iso' => 'application/x-iso9660-image', 'jar' => 'application/java-archive', 'jpe' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'jpg' => 'image/jpeg', 'js' => 'text/javascript', 'json' => 'application/json', 'latex' => 'application/x-latex', 'log' => 'text/plain', 'm4a' => 'audio/mp4', 'm4v' => 'video/mp4', 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mov' => 'video/quicktime', 'mkv' => 'video/x-matroska', 'mp3' => 'audio/mpeg', 'mp4' => 'video/mp4', 'mp4a' => 'audio/mp4', 'mp4v' => 'video/mp4', 'mpe' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpg4' => 'video/mp4', 'oga' => 'audio/ogg', 'ogg' => 'audio/ogg', 'ogv' => 'video/ogg', 'ogx' => 'application/ogg', 'pbm' => 'image/x-portable-bitmap', 'pdf' => 'application/pdf', 'pgm' => 'image/x-portable-graymap', 'png' => 'image/png', 'pnm' => 'image/x-portable-anymap', 'ppm' => 'image/x-portable-pixmap', 'ppt' => 'application/vnd.ms-powerpoint', 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', 'ps' => 'application/postscript', 'qt' => 'video/quicktime', 'rar' => 'application/x-rar-compressed', 'ras' => 'image/x-cmu-raster', 'rss' => 'application/rss+xml', 'rtf' => 'application/rtf', 'sgm' => 'text/sgml', 'sgml' => 'text/sgml', 'svg' => 'image/svg+xml', 'swf' => 'application/x-shockwave-flash', 'tar' => 'application/x-tar', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'torrent' => 'application/x-bittorrent', 'ttf' => 'application/x-font-ttf', 'txt' => 'text/plain', 'wav' => 'audio/x-wav', 'webm' => 'video/webm', 'webp' => 'image/webp', 'wma' => 'audio/x-ms-wma', 'wmv' => 'video/x-ms-wmv', 'woff' => 'application/x-font-woff', 'wsdl' => 'application/wsdl+xml', 'xbm' => 'image/x-xbitmap', 'xls' => 'application/vnd.ms-excel', 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'xml' => 'application/xml', 'xpm' => 'image/x-xpixmap', 'xwd' => 'image/x-xwindowdump', 'yaml' => 'text/yaml', 'yml' => 'text/yaml', 'zip' => 'application/zip'];
- $extension = \strtolower($extension);
- return isset($mimetypes[$extension]) ? $mimetypes[$extension] : null;
-}
-/**
- * Parses an HTTP message into an associative array.
- *
- * The array contains the "start-line" key containing the start line of
- * the message, "headers" key containing an associative array of header
- * array values, and a "body" key containing the body of the message.
- *
- * @param string $message HTTP request or response to parse.
- *
- * @return array
- * @internal
- */
-function _parse_message($message)
-{
- if (!$message) {
- throw new \InvalidArgumentException('Invalid message');
- }
- $message = \ltrim($message, "\r\n");
- $messageParts = \preg_split("/\r?\n\r?\n/", $message, 2);
- if ($messageParts === \false || \count($messageParts) !== 2) {
- throw new \InvalidArgumentException('Invalid message: Missing header delimiter');
- }
- list($rawHeaders, $body) = $messageParts;
- $rawHeaders .= "\r\n";
- // Put back the delimiter we split previously
- $headerParts = \preg_split("/\r?\n/", $rawHeaders, 2);
- if ($headerParts === \false || \count($headerParts) !== 2) {
- throw new \InvalidArgumentException('Invalid message: Missing status line');
- }
- list($startLine, $rawHeaders) = $headerParts;
- if (\preg_match("/(?:^HTTP\\/|^[A-Z]+ \\S+ HTTP\\/)(\\d+(?:\\.\\d+)?)/i", $startLine, $matches) && $matches[1] === '1.0') {
- // Header folding is deprecated for HTTP/1.1, but allowed in HTTP/1.0
- $rawHeaders = \preg_replace(\PayNL\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, ' ', $rawHeaders);
- }
- /** @var array[] $headerLines */
- $count = \preg_match_all(\PayNL\GuzzleHttp\Psr7\Rfc7230::HEADER_REGEX, $rawHeaders, $headerLines, \PREG_SET_ORDER);
- // If these aren't the same, then one line didn't match and there's an invalid header.
- if ($count !== \substr_count($rawHeaders, "\n")) {
- // Folding is deprecated, see https://tools.ietf.org/html/rfc7230#section-3.2.4
- if (\preg_match(\PayNL\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, $rawHeaders)) {
- throw new \InvalidArgumentException('Invalid header syntax: Obsolete line folding');
- }
- throw new \InvalidArgumentException('Invalid header syntax');
- }
- $headers = [];
- foreach ($headerLines as $headerLine) {
- $headers[$headerLine[1]][] = $headerLine[2];
- }
- return ['start-line' => $startLine, 'headers' => $headers, 'body' => $body];
-}
-/**
- * Constructs a URI for an HTTP request message.
- *
- * @param string $path Path from the start-line
- * @param array $headers Array of headers (each value an array).
- *
- * @return string
- * @internal
- */
-function _parse_request_uri($path, array $headers)
-{
- $hostKey = \array_filter(\array_keys($headers), function ($k) {
- return \strtolower($k) === 'host';
- });
- // If no host is found, then a full URI cannot be constructed.
- if (!$hostKey) {
- return $path;
- }
- $host = $headers[\reset($hostKey)][0];
- $scheme = \substr($host, -4) === ':443' ? 'https' : 'http';
- return $scheme . '://' . $host . '/' . \ltrim($path, '/');
-}
-/**
- * Get a short summary of the message body
- *
- * Will return `null` if the response is not printable.
- *
- * @param MessageInterface $message The message to get the body summary
- * @param int $truncateAt The maximum allowed size of the summary
- *
- * @return null|string
- */
-function get_message_body_summary(\Psr\Http\Message\MessageInterface $message, $truncateAt = 120)
-{
- $body = $message->getBody();
- if (!$body->isSeekable() || !$body->isReadable()) {
- return null;
- }
- $size = $body->getSize();
- if ($size === 0) {
- return null;
- }
- $summary = $body->read($truncateAt);
- $body->rewind();
- if ($size > $truncateAt) {
- $summary .= ' (truncated...)';
- }
- // Matches any printable character, including unicode characters:
- // letters, marks, numbers, punctuation, spacing, and separators.
- if (\preg_match('/[^\\pL\\pM\\pN\\pP\\pS\\pZ\\n\\r\\t]/', $summary)) {
- return null;
- }
- return $summary;
-}
-/** @internal */
-function _caseless_remove($keys, array $data)
-{
- $result = [];
- foreach ($keys as &$key) {
- $key = \strtolower($key);
- }
- foreach ($data as $k => $v) {
- if (!\in_array(\strtolower($k), $keys)) {
- $result[$k] = $v;
- }
- }
- return $result;
-}
diff --git a/build/psr7/src/functions_include.php b/build/psr7/src/functions_include.php
deleted file mode 100644
index 742dc99..0000000
--- a/build/psr7/src/functions_include.php
+++ /dev/null
@@ -1,8 +0,0 @@
-=7.4.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.0.x-dev"
+ }
+ },
+ "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": "Common Container Interface (PHP FIG PSR-11)",
+ "homepage": "https://github.com/php-fig/container",
+ "keywords": [
+ "PSR-11",
+ "container",
+ "container-interface",
+ "container-interop",
+ "psr"
+ ],
+ "support": {
+ "issues": "https://github.com/php-fig/container/issues",
+ "source": "https://github.com/php-fig/container/tree/2.0.2"
+ },
+ "time": "2021-11-05T16:47:00+00:00"
+ },
+ {
+ "name": "psr/http-message",
+ "version": "2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-message.git",
+ "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-message/zipball/402d35bcb92c70c026d1a6a9883f06b2ead23d71",
+ "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2 || ^8.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP messages",
+ "homepage": "https://github.com/php-fig/http-message",
+ "keywords": [
+ "http",
+ "http-message",
+ "psr",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-message/tree/2.0"
+ },
+ "time": "2023-04-04T09:54:51+00:00"
+ }
+ ],
+ "packages-dev": [
+ {
+ "name": "composer/pcre",
+ "version": "3.3.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/pcre.git",
+ "reference": "b2bed4734f0cc156ee1fe9c0da2550420d99a21e"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/pcre/zipball/b2bed4734f0cc156ee1fe9c0da2550420d99a21e",
+ "reference": "b2bed4734f0cc156ee1fe9c0da2550420d99a21e",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.4 || ^8.0"
+ },
+ "conflict": {
+ "phpstan/phpstan": "<1.11.10"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.12 || ^2",
+ "phpstan/phpstan-strict-rules": "^1 || ^2",
+ "phpunit/phpunit": "^8 || ^9"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.x-dev"
+ },
+ "phpstan": {
+ "includes": [
+ "extension.neon"
+ ]
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\Pcre\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ }
+ ],
+ "description": "PCRE wrapping library that offers type-safe preg_* replacements.",
+ "keywords": [
+ "PCRE",
+ "preg",
+ "regex",
+ "regular expression"
+ ],
+ "support": {
+ "issues": "https://github.com/composer/pcre/issues",
+ "source": "https://github.com/composer/pcre/tree/3.3.2"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-11-12T16:29:46+00:00"
+ },
+ {
+ "name": "composer/xdebug-handler",
+ "version": "3.0.5",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/xdebug-handler.git",
+ "reference": "6c1925561632e83d60a44492e0b344cf48ab85ef"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/6c1925561632e83d60a44492e0b344cf48ab85ef",
+ "reference": "6c1925561632e83d60a44492e0b344cf48ab85ef",
+ "shasum": ""
+ },
+ "require": {
+ "composer/pcre": "^1 || ^2 || ^3",
+ "php": "^7.2.5 || ^8.0",
+ "psr/log": "^1 || ^2 || ^3"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.0",
+ "phpstan/phpstan-strict-rules": "^1.1",
+ "phpunit/phpunit": "^8.5 || ^9.6 || ^10.5"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Composer\\XdebugHandler\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "John Stevenson",
+ "email": "john-stevenson@blueyonder.co.uk"
+ }
+ ],
+ "description": "Restarts a process without Xdebug.",
+ "keywords": [
+ "Xdebug",
+ "performance"
+ ],
+ "support": {
+ "irc": "ircs://irc.libera.chat:6697/composer",
+ "issues": "https://github.com/composer/xdebug-handler/issues",
+ "source": "https://github.com/composer/xdebug-handler/tree/3.0.5"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-05-06T16:37:16+00:00"
+ },
+ {
+ "name": "guzzlehttp/guzzle",
+ "version": "7.9.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/guzzle.git",
+ "reference": "d281ed313b989f213357e3be1a179f02196ac99b"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/guzzle/zipball/d281ed313b989f213357e3be1a179f02196ac99b",
+ "reference": "d281ed313b989f213357e3be1a179f02196ac99b",
+ "shasum": ""
+ },
+ "require": {
+ "ext-json": "*",
+ "guzzlehttp/promises": "^1.5.3 || ^2.0.3",
+ "guzzlehttp/psr7": "^2.7.0",
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-client": "^1.0",
+ "symfony/deprecation-contracts": "^2.2 || ^3.0"
+ },
+ "provide": {
+ "psr/http-client-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.2",
+ "ext-curl": "*",
+ "guzzle/client-integration-tests": "3.0.2",
+ "php-http/message-factory": "^1.1",
+ "phpunit/phpunit": "^8.5.39 || ^9.6.20",
+ "psr/log": "^1.1 || ^2.0 || ^3.0"
+ },
+ "suggest": {
+ "ext-curl": "Required for CURL handler support",
+ "ext-intl": "Required for Internationalized Domain Name (IDN) support",
+ "psr/log": "Required for using the Log middleware"
+ },
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "GuzzleHttp\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Jeremy Lindblom",
+ "email": "jeremeamia@gmail.com",
+ "homepage": "https://github.com/jeremeamia"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle is a PHP HTTP client library",
+ "keywords": [
+ "client",
+ "curl",
+ "framework",
+ "http",
+ "http client",
+ "psr-18",
+ "psr-7",
+ "rest",
+ "web service"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/guzzle/issues",
+ "source": "https://github.com/guzzle/guzzle/tree/7.9.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-07-24T11:22:20+00:00"
+ },
+ {
+ "name": "guzzlehttp/promises",
+ "version": "2.0.4",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/promises.git",
+ "reference": "f9c436286ab2892c7db7be8c8da4ef61ccf7b455"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/promises/zipball/f9c436286ab2892c7db7be8c8da4ef61ccf7b455",
+ "reference": "f9c436286ab2892c7db7be8c8da4ef61ccf7b455",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2.5 || ^8.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.2",
+ "phpunit/phpunit": "^8.5.39 || ^9.6.20"
+ },
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Promise\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle promises library",
+ "keywords": [
+ "promise"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/promises/issues",
+ "source": "https://github.com/guzzle/promises/tree/2.0.4"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-10-17T10:06:22+00:00"
+ },
+ {
+ "name": "guzzlehttp/psr7",
+ "version": "2.7.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/psr7.git",
+ "reference": "a70f5c95fb43bc83f07c9c948baa0dc1829bf201"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/psr7/zipball/a70f5c95fb43bc83f07c9c948baa0dc1829bf201",
+ "reference": "a70f5c95fb43bc83f07c9c948baa0dc1829bf201",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-factory": "^1.0",
+ "psr/http-message": "^1.1 || ^2.0",
+ "ralouphie/getallheaders": "^3.0"
+ },
+ "provide": {
+ "psr/http-factory-implementation": "1.0",
+ "psr/http-message-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.2",
+ "http-interop/http-factory-tests": "0.9.0",
+ "phpunit/phpunit": "^8.5.39 || ^9.6.20"
+ },
+ "suggest": {
+ "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses"
+ },
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Psr7\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://sagikazarmark.hu"
+ }
+ ],
+ "description": "PSR-7 message implementation that also provides common utility methods",
+ "keywords": [
+ "http",
+ "message",
+ "psr-7",
+ "request",
+ "response",
+ "stream",
+ "uri",
+ "url"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/psr7/issues",
+ "source": "https://github.com/guzzle/psr7/tree/2.7.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-07-18T11:15:46+00:00"
+ },
+ {
+ "name": "myclabs/deep-copy",
+ "version": "1.12.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/myclabs/DeepCopy.git",
+ "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/123267b2c49fbf30d78a7b2d333f6be754b94845",
+ "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.1 || ^8.0"
+ },
+ "conflict": {
+ "doctrine/collections": "<1.6.8",
+ "doctrine/common": "<2.13.3 || >=3 <3.2.2"
+ },
+ "require-dev": {
+ "doctrine/collections": "^1.6.8",
+ "doctrine/common": "^2.13.3 || ^3.2.2",
+ "phpspec/prophecy": "^1.10",
+ "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13"
+ },
+ "type": "library",
+ "autoload": {
+ "files": [
+ "src/DeepCopy/deep_copy.php"
+ ],
+ "psr-4": {
+ "DeepCopy\\": "src/DeepCopy/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "description": "Create deep copies (clones) of your objects",
+ "keywords": [
+ "clone",
+ "copy",
+ "duplicate",
+ "object",
+ "object graph"
+ ],
+ "support": {
+ "issues": "https://github.com/myclabs/DeepCopy/issues",
+ "source": "https://github.com/myclabs/DeepCopy/tree/1.12.1"
+ },
+ "funding": [
+ {
+ "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-11-08T17:47:46+00:00"
+ },
+ {
+ "name": "nikic/php-parser",
+ "version": "v5.3.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/nikic/PHP-Parser.git",
+ "reference": "8eea230464783aa9671db8eea6f8c6ac5285794b"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/8eea230464783aa9671db8eea6f8c6ac5285794b",
+ "reference": "8eea230464783aa9671db8eea6f8c6ac5285794b",
+ "shasum": ""
+ },
+ "require": {
+ "ext-ctype": "*",
+ "ext-json": "*",
+ "ext-tokenizer": "*",
+ "php": ">=7.4"
+ },
+ "require-dev": {
+ "ircmaxell/php-yacc": "^0.0.7",
+ "phpunit/phpunit": "^9.0"
+ },
+ "bin": [
+ "bin/php-parse"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "5.0-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/v5.3.1"
+ },
+ "time": "2024-10-08T18:51:32+00:00"
+ },
+ {
+ "name": "pdepend/pdepend",
+ "version": "2.16.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/pdepend/pdepend.git",
+ "reference": "f942b208dc2a0868454d01b29f0c75bbcfc6ed58"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/pdepend/pdepend/zipball/f942b208dc2a0868454d01b29f0c75bbcfc6ed58",
+ "reference": "f942b208dc2a0868454d01b29f0c75bbcfc6ed58",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.7",
+ "symfony/config": "^2.3.0|^3|^4|^5|^6.0|^7.0",
+ "symfony/dependency-injection": "^2.3.0|^3|^4|^5|^6.0|^7.0",
+ "symfony/filesystem": "^2.3.0|^3|^4|^5|^6.0|^7.0",
+ "symfony/polyfill-mbstring": "^1.19"
+ },
+ "require-dev": {
+ "easy-doc/easy-doc": "0.0.0|^1.2.3",
+ "gregwar/rst": "^1.0",
+ "squizlabs/php_codesniffer": "^2.0.0"
+ },
+ "bin": [
+ "src/bin/pdepend"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "PDepend\\": "src/main/php/PDepend"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "description": "Official version of pdepend to be handled with Composer",
+ "keywords": [
+ "PHP Depend",
+ "PHP_Depend",
+ "dev",
+ "pdepend"
+ ],
+ "support": {
+ "issues": "https://github.com/pdepend/pdepend/issues",
+ "source": "https://github.com/pdepend/pdepend/tree/2.16.2"
+ },
+ "funding": [
+ {
+ "url": "https://tidelift.com/funding/github/packagist/pdepend/pdepend",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2023-12-17T18:09:59+00:00"
+ },
+ {
+ "name": "phar-io/manifest",
+ "version": "2.0.4",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/phar-io/manifest.git",
+ "reference": "54750ef60c58e43759730615a392c31c80e23176"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176",
+ "reference": "54750ef60c58e43759730615a392c31c80e23176",
+ "shasum": ""
+ },
+ "require": {
+ "ext-dom": "*",
+ "ext-libxml": "*",
+ "ext-phar": "*",
+ "ext-xmlwriter": "*",
+ "phar-io/version": "^3.0.1",
+ "php": "^7.2 || ^8.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": "Arne Blankerts",
+ "email": "arne@blankerts.de",
+ "role": "Developer"
+ },
+ {
+ "name": "Sebastian Heuer",
+ "email": "sebastian@phpeople.de",
+ "role": "Developer"
+ },
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de",
+ "role": "Developer"
+ }
+ ],
+ "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)",
+ "support": {
+ "issues": "https://github.com/phar-io/manifest/issues",
+ "source": "https://github.com/phar-io/manifest/tree/2.0.4"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/theseer",
+ "type": "github"
+ }
+ ],
+ "time": "2024-03-03T12:33:53+00:00"
+ },
+ {
+ "name": "phar-io/version",
+ "version": "3.2.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/phar-io/version.git",
+ "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74",
+ "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2 || ^8.0"
+ },
+ "type": "library",
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Arne Blankerts",
+ "email": "arne@blankerts.de",
+ "role": "Developer"
+ },
+ {
+ "name": "Sebastian Heuer",
+ "email": "sebastian@phpeople.de",
+ "role": "Developer"
+ },
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de",
+ "role": "Developer"
+ }
+ ],
+ "description": "Library for handling version information and constraints",
+ "support": {
+ "issues": "https://github.com/phar-io/version/issues",
+ "source": "https://github.com/phar-io/version/tree/3.2.1"
+ },
+ "time": "2022-02-21T01:04:05+00:00"
+ },
+ {
+ "name": "phpmd/phpmd",
+ "version": "2.15.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/phpmd/phpmd.git",
+ "reference": "74a1f56e33afad4128b886e334093e98e1b5e7c0"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/phpmd/phpmd/zipball/74a1f56e33afad4128b886e334093e98e1b5e7c0",
+ "reference": "74a1f56e33afad4128b886e334093e98e1b5e7c0",
+ "shasum": ""
+ },
+ "require": {
+ "composer/xdebug-handler": "^1.0 || ^2.0 || ^3.0",
+ "ext-xml": "*",
+ "pdepend/pdepend": "^2.16.1",
+ "php": ">=5.3.9"
+ },
+ "require-dev": {
+ "easy-doc/easy-doc": "0.0.0 || ^1.3.2",
+ "ext-json": "*",
+ "ext-simplexml": "*",
+ "gregwar/rst": "^1.0",
+ "mikey179/vfsstream": "^1.6.8",
+ "squizlabs/php_codesniffer": "^2.9.2 || ^3.7.2"
+ },
+ "bin": [
+ "src/bin/phpmd"
+ ],
+ "type": "library",
+ "autoload": {
+ "psr-0": {
+ "PHPMD\\": "src/main/php"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Manuel Pichler",
+ "email": "github@manuel-pichler.de",
+ "homepage": "https://github.com/manuelpichler",
+ "role": "Project Founder"
+ },
+ {
+ "name": "Marc Würth",
+ "email": "ravage@bluewin.ch",
+ "homepage": "https://github.com/ravage84",
+ "role": "Project Maintainer"
+ },
+ {
+ "name": "Other contributors",
+ "homepage": "https://github.com/phpmd/phpmd/graphs/contributors",
+ "role": "Contributors"
+ }
+ ],
+ "description": "PHPMD is a spin-off project of PHP Depend and aims to be a PHP equivalent of the well known Java tool PMD.",
+ "homepage": "https://phpmd.org/",
+ "keywords": [
+ "dev",
+ "mess detection",
+ "mess detector",
+ "pdepend",
+ "phpmd",
+ "pmd"
+ ],
+ "support": {
+ "irc": "irc://irc.freenode.org/phpmd",
+ "issues": "https://github.com/phpmd/phpmd/issues",
+ "source": "https://github.com/phpmd/phpmd/tree/2.15.0"
+ },
+ "funding": [
+ {
+ "url": "https://tidelift.com/funding/github/packagist/phpmd/phpmd",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2023-12-11T08:22:20+00:00"
+ },
+ {
+ "name": "phpstan/phpstan",
+ "version": "2.0.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/phpstan/phpstan.git",
+ "reference": "46b4d3529b12178112d9008337beda0cc2a1a6b4"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/phpstan/phpstan/zipball/46b4d3529b12178112d9008337beda0cc2a1a6b4",
+ "reference": "46b4d3529b12178112d9008337beda0cc2a1a6b4",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.4|^8.0"
+ },
+ "conflict": {
+ "phpstan/phpstan-shim": "*"
+ },
+ "bin": [
+ "phpstan",
+ "phpstan.phar"
+ ],
+ "type": "library",
+ "autoload": {
+ "files": [
+ "bootstrap.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "description": "PHPStan - PHP Static Analysis Tool",
+ "keywords": [
+ "dev",
+ "static analysis"
+ ],
+ "support": {
+ "docs": "https://phpstan.org/user-guide/getting-started",
+ "forum": "https://github.com/phpstan/phpstan/discussions",
+ "issues": "https://github.com/phpstan/phpstan/issues",
+ "security": "https://github.com/phpstan/phpstan/security/policy",
+ "source": "https://github.com/phpstan/phpstan-src"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/ondrejmirtes",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/phpstan",
+ "type": "github"
+ }
+ ],
+ "time": "2024-11-28T22:19:37+00:00"
+ },
+ {
+ "name": "phpunit/php-code-coverage",
+ "version": "11.0.7",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/php-code-coverage.git",
+ "reference": "f7f08030e8811582cc459871d28d6f5a1a4d35ca"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f7f08030e8811582cc459871d28d6f5a1a4d35ca",
+ "reference": "f7f08030e8811582cc459871d28d6f5a1a4d35ca",
+ "shasum": ""
+ },
+ "require": {
+ "ext-dom": "*",
+ "ext-libxml": "*",
+ "ext-xmlwriter": "*",
+ "nikic/php-parser": "^5.3.1",
+ "php": ">=8.2",
+ "phpunit/php-file-iterator": "^5.1.0",
+ "phpunit/php-text-template": "^4.0.1",
+ "sebastian/code-unit-reverse-lookup": "^4.0.1",
+ "sebastian/complexity": "^4.0.1",
+ "sebastian/environment": "^7.2.0",
+ "sebastian/lines-of-code": "^3.0.1",
+ "sebastian/version": "^5.0.2",
+ "theseer/tokenizer": "^1.2.3"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.4.1"
+ },
+ "suggest": {
+ "ext-pcov": "PHP extension that provides line coverage",
+ "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "11.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 provides collection, processing, and rendering functionality for PHP code coverage information.",
+ "homepage": "https://github.com/sebastianbergmann/php-code-coverage",
+ "keywords": [
+ "coverage",
+ "testing",
+ "xunit"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
+ "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy",
+ "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/11.0.7"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-10-09T06:21:38+00:00"
+ },
+ {
+ "name": "phpunit/php-file-iterator",
+ "version": "5.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/php-file-iterator.git",
+ "reference": "118cfaaa8bc5aef3287bf315b6060b1174754af6"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/118cfaaa8bc5aef3287bf315b6060b1174754af6",
+ "reference": "118cfaaa8bc5aef3287bf315b6060b1174754af6",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "5.0-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": "FilterIterator implementation that filters files based on a list of suffixes.",
+ "homepage": "https://github.com/sebastianbergmann/php-file-iterator/",
+ "keywords": [
+ "filesystem",
+ "iterator"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues",
+ "security": "https://github.com/sebastianbergmann/php-file-iterator/security/policy",
+ "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/5.1.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-08-27T05:02:59+00:00"
+ },
+ {
+ "name": "phpunit/php-invoker",
+ "version": "5.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/php-invoker.git",
+ "reference": "c1ca3814734c07492b3d4c5f794f4b0995333da2"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/c1ca3814734c07492b3d4c5f794f4b0995333da2",
+ "reference": "c1ca3814734c07492b3d4c5f794f4b0995333da2",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "ext-pcntl": "*",
+ "phpunit/phpunit": "^11.0"
+ },
+ "suggest": {
+ "ext-pcntl": "*"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "5.0-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": "Invoke callables with a timeout",
+ "homepage": "https://github.com/sebastianbergmann/php-invoker/",
+ "keywords": [
+ "process"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-invoker/issues",
+ "security": "https://github.com/sebastianbergmann/php-invoker/security/policy",
+ "source": "https://github.com/sebastianbergmann/php-invoker/tree/5.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:07:44+00:00"
+ },
+ {
+ "name": "phpunit/php-text-template",
+ "version": "4.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/php-text-template.git",
+ "reference": "3e0404dc6b300e6bf56415467ebcb3fe4f33e964"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/3e0404dc6b300e6bf56415467ebcb3fe4f33e964",
+ "reference": "3e0404dc6b300e6bf56415467ebcb3fe4f33e964",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "4.0-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": "Simple template engine.",
+ "homepage": "https://github.com/sebastianbergmann/php-text-template/",
+ "keywords": [
+ "template"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-text-template/issues",
+ "security": "https://github.com/sebastianbergmann/php-text-template/security/policy",
+ "source": "https://github.com/sebastianbergmann/php-text-template/tree/4.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:08:43+00:00"
+ },
+ {
+ "name": "phpunit/php-timer",
+ "version": "7.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/php-timer.git",
+ "reference": "3b415def83fbcb41f991d9ebf16ae4ad8b7837b3"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3b415def83fbcb41f991d9ebf16ae4ad8b7837b3",
+ "reference": "3b415def83fbcb41f991d9ebf16ae4ad8b7837b3",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "7.0-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": "Utility class for timing",
+ "homepage": "https://github.com/sebastianbergmann/php-timer/",
+ "keywords": [
+ "timer"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-timer/issues",
+ "security": "https://github.com/sebastianbergmann/php-timer/security/policy",
+ "source": "https://github.com/sebastianbergmann/php-timer/tree/7.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:09:35+00:00"
+ },
+ {
+ "name": "phpunit/phpunit",
+ "version": "11.5.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/phpunit.git",
+ "reference": "0569902506a6c0878930b87ea79ec3b50ea563f7"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0569902506a6c0878930b87ea79ec3b50ea563f7",
+ "reference": "0569902506a6c0878930b87ea79ec3b50ea563f7",
+ "shasum": ""
+ },
+ "require": {
+ "ext-dom": "*",
+ "ext-json": "*",
+ "ext-libxml": "*",
+ "ext-mbstring": "*",
+ "ext-xml": "*",
+ "ext-xmlwriter": "*",
+ "myclabs/deep-copy": "^1.12.1",
+ "phar-io/manifest": "^2.0.4",
+ "phar-io/version": "^3.2.1",
+ "php": ">=8.2",
+ "phpunit/php-code-coverage": "^11.0.7",
+ "phpunit/php-file-iterator": "^5.1.0",
+ "phpunit/php-invoker": "^5.0.1",
+ "phpunit/php-text-template": "^4.0.1",
+ "phpunit/php-timer": "^7.0.1",
+ "sebastian/cli-parser": "^3.0.2",
+ "sebastian/code-unit": "^3.0.1",
+ "sebastian/comparator": "^6.2.1",
+ "sebastian/diff": "^6.0.2",
+ "sebastian/environment": "^7.2.0",
+ "sebastian/exporter": "^6.3.0",
+ "sebastian/global-state": "^7.0.2",
+ "sebastian/object-enumerator": "^6.0.1",
+ "sebastian/type": "^5.1.0",
+ "sebastian/version": "^5.0.2",
+ "staabm/side-effects-detector": "^1.0.5"
+ },
+ "suggest": {
+ "ext-soap": "To be able to generate mocks based on WSDL files"
+ },
+ "bin": [
+ "phpunit"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "11.5-dev"
+ }
+ },
+ "autoload": {
+ "files": [
+ "src/Framework/Assert/Functions.php"
+ ],
+ "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"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/phpunit/issues",
+ "security": "https://github.com/sebastianbergmann/phpunit/security/policy",
+ "source": "https://github.com/sebastianbergmann/phpunit/tree/11.5.0"
+ },
+ "funding": [
+ {
+ "url": "https://phpunit.de/sponsors.html",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-12-06T05:57:38+00:00"
+ },
+ {
+ "name": "psr/http-client",
+ "version": "1.0.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-client.git",
+ "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-client/zipball/bb5906edc1c324c9a05aa0873d40117941e5fa90",
+ "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.0 || ^8.0",
+ "psr/http-message": "^1.0 || ^2.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP clients",
+ "homepage": "https://github.com/php-fig/http-client",
+ "keywords": [
+ "http",
+ "http-client",
+ "psr",
+ "psr-18"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-client"
+ },
+ "time": "2023-09-23T14:17:50+00:00"
+ },
+ {
+ "name": "psr/http-factory",
+ "version": "1.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-factory.git",
+ "reference": "2b4765fddfe3b508ac62f829e852b1501d3f6e8a"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-factory/zipball/2b4765fddfe3b508ac62f829e852b1501d3f6e8a",
+ "reference": "2b4765fddfe3b508ac62f829e852b1501d3f6e8a",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.1",
+ "psr/http-message": "^1.0 || ^2.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "PSR-17: Common interfaces for PSR-7 HTTP message factories",
+ "keywords": [
+ "factory",
+ "http",
+ "message",
+ "psr",
+ "psr-17",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-factory"
+ },
+ "time": "2024-04-15T12:06:14+00:00"
+ },
+ {
+ "name": "psr/log",
+ "version": "3.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/log.git",
+ "reference": "f16e1d5863e37f8d8c2a01719f5b34baa2b714d3"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/log/zipball/f16e1d5863e37f8d8c2a01719f5b34baa2b714d3",
+ "reference": "f16e1d5863e37f8d8c2a01719f5b34baa2b714d3",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.0.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "3.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Log\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for logging libraries",
+ "homepage": "https://github.com/php-fig/log",
+ "keywords": [
+ "log",
+ "psr",
+ "psr-3"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/log/tree/3.0.2"
+ },
+ "time": "2024-09-11T13:17:53+00:00"
+ },
+ {
+ "name": "ralouphie/getallheaders",
+ "version": "3.0.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/ralouphie/getallheaders.git",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.6"
+ },
+ "require-dev": {
+ "php-coveralls/php-coveralls": "^2.1",
+ "phpunit/phpunit": "^5 || ^6.5"
+ },
+ "type": "library",
+ "autoload": {
+ "files": [
+ "src/getallheaders.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Ralph Khattar",
+ "email": "ralph.khattar@gmail.com"
+ }
+ ],
+ "description": "A polyfill for getallheaders.",
+ "support": {
+ "issues": "https://github.com/ralouphie/getallheaders/issues",
+ "source": "https://github.com/ralouphie/getallheaders/tree/develop"
+ },
+ "time": "2019-03-08T08:55:37+00:00"
+ },
+ {
+ "name": "roave/security-advisories",
+ "version": "dev-master",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Roave/SecurityAdvisories.git",
+ "reference": "dcb2bdb48e1d9b0b5b1c333b61f49772aee879ff"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/dcb2bdb48e1d9b0b5b1c333b61f49772aee879ff",
+ "reference": "dcb2bdb48e1d9b0b5b1c333b61f49772aee879ff",
+ "shasum": ""
+ },
+ "conflict": {
+ "3f/pygmentize": "<1.2",
+ "admidio/admidio": "<4.3.12",
+ "adodb/adodb-php": "<=5.20.20|>=5.21,<=5.21.3",
+ "aheinze/cockpit": "<2.2",
+ "aimeos/ai-admin-graphql": ">=2022.04.1,<2022.10.10|>=2023.04.1,<2023.10.6|>=2024.04.1,<2024.07.2",
+ "aimeos/ai-admin-jsonadm": "<2020.10.13|>=2021.04.1,<2021.10.6|>=2022.04.1,<2022.10.3|>=2023.04.1,<2023.10.4|==2024.04.1",
+ "aimeos/ai-client-html": ">=2020.04.1,<2020.10.27|>=2021.04.1,<2021.10.22|>=2022.04.1,<2022.10.13|>=2023.04.1,<2023.10.15|>=2024.04.1,<2024.04.7",
+ "aimeos/ai-controller-frontend": "<2020.10.15|>=2021.04.1,<2021.10.8|>=2022.04.1,<2022.10.8|>=2023.04.1,<2023.10.9|==2024.04.1",
+ "aimeos/aimeos-core": ">=2022.04.1,<2022.10.17|>=2023.04.1,<2023.10.17|>=2024.04.1,<2024.04.7",
+ "aimeos/aimeos-typo3": "<19.10.12|>=20,<20.10.5",
+ "airesvsg/acf-to-rest-api": "<=3.1",
+ "akaunting/akaunting": "<2.1.13",
+ "akeneo/pim-community-dev": "<5.0.119|>=6,<6.0.53",
+ "alextselegidis/easyappointments": "<1.5",
+ "alterphp/easyadmin-extension-bundle": ">=1.2,<1.2.11|>=1.3,<1.3.1",
+ "amazing/media2click": ">=1,<1.3.3",
+ "ameos/ameos_tarteaucitron": "<1.2.23",
+ "amphp/artax": "<1.0.6|>=2,<2.0.6",
+ "amphp/http": "<=1.7.2|>=2,<=2.1",
+ "amphp/http-client": ">=4,<4.4",
+ "anchorcms/anchor-cms": "<=0.12.7",
+ "andreapollastri/cipi": "<=3.1.15",
+ "andrewhaine/silverstripe-form-capture": ">=0.2,<=0.2.3|>=1,<1.0.2|>=2,<2.2.5",
+ "apache-solr-for-typo3/solr": "<2.8.3",
+ "apereo/phpcas": "<1.6",
+ "api-platform/core": ">=2.2,<2.2.10|>=2.3,<2.3.6|>=2.6,<2.7.10|>=3,<3.0.12|>=3.1,<3.1.3",
+ "appwrite/server-ce": "<=1.2.1",
+ "arc/web": "<3",
+ "area17/twill": "<1.2.5|>=2,<2.5.3",
+ "artesaos/seotools": "<0.17.2",
+ "asymmetricrypt/asymmetricrypt": "<9.9.99",
+ "athlon1600/php-proxy": "<=5.1",
+ "athlon1600/php-proxy-app": "<=3",
+ "austintoddj/canvas": "<=3.4.2",
+ "auth0/wordpress": "<=4.6",
+ "automad/automad": "<2.0.0.0-alpha5",
+ "automattic/jetpack": "<9.8",
+ "awesome-support/awesome-support": "<=6.0.7",
+ "aws/aws-sdk-php": "<3.288.1",
+ "azuracast/azuracast": "<0.18.3",
+ "backdrop/backdrop": "<1.27.3|>=1.28,<1.28.2",
+ "backpack/crud": "<3.4.9",
+ "backpack/filemanager": "<2.0.2|>=3,<3.0.9",
+ "bacula-web/bacula-web": "<8.0.0.0-RC2-dev",
+ "badaso/core": "<2.7",
+ "bagisto/bagisto": "<2.1",
+ "barrelstrength/sprout-base-email": "<1.2.7",
+ "barrelstrength/sprout-forms": "<3.9",
+ "barryvdh/laravel-translation-manager": "<0.6.2",
+ "barzahlen/barzahlen-php": "<2.0.1",
+ "baserproject/basercms": "<=5.1.1",
+ "bassjobsen/bootstrap-3-typeahead": ">4.0.2",
+ "bbpress/bbpress": "<2.6.5",
+ "bcosca/fatfree": "<3.7.2",
+ "bedita/bedita": "<4",
+ "bigfork/silverstripe-form-capture": ">=3,<3.1.1",
+ "billz/raspap-webgui": "<=3.1.4",
+ "bk2k/bootstrap-package": ">=7.1,<7.1.2|>=8,<8.0.8|>=9,<9.0.4|>=9.1,<9.1.3|>=10,<10.0.10|>=11,<11.0.3",
+ "blueimp/jquery-file-upload": "==6.4.4",
+ "bmarshall511/wordpress_zero_spam": "<5.2.13",
+ "bolt/bolt": "<3.7.2",
+ "bolt/core": "<=4.2",
+ "born05/craft-twofactorauthentication": "<3.3.4",
+ "bottelet/flarepoint": "<2.2.1",
+ "bref/bref": "<2.1.17",
+ "brightlocal/phpwhois": "<=4.2.5",
+ "brotkrueml/codehighlight": "<2.7",
+ "brotkrueml/schema": "<1.13.1|>=2,<2.5.1",
+ "brotkrueml/typo3-matomo-integration": "<1.3.2",
+ "buddypress/buddypress": "<7.2.1",
+ "bugsnag/bugsnag-laravel": ">=2,<2.0.2",
+ "bytefury/crater": "<6.0.2",
+ "cachethq/cachet": "<2.5.1",
+ "cakephp/cakephp": "<3.10.3|>=4,<4.0.10|>=4.1,<4.1.4|>=4.2,<4.2.12|>=4.3,<4.3.11|>=4.4,<4.4.10",
+ "cakephp/database": ">=4.2,<4.2.12|>=4.3,<4.3.11|>=4.4,<4.4.10",
+ "cardgate/magento2": "<2.0.33",
+ "cardgate/woocommerce": "<=3.1.15",
+ "cart2quote/module-quotation": ">=4.1.6,<=4.4.5|>=5,<5.4.4",
+ "cart2quote/module-quotation-encoded": ">=4.1.6,<=4.4.5|>=5,<5.4.4",
+ "cartalyst/sentry": "<=2.1.6",
+ "catfan/medoo": "<1.7.5",
+ "causal/oidc": "<2.1",
+ "cecil/cecil": "<7.47.1",
+ "centreon/centreon": "<22.10.15",
+ "cesnet/simplesamlphp-module-proxystatistics": "<3.1",
+ "chriskacerguis/codeigniter-restserver": "<=2.7.1",
+ "civicrm/civicrm-core": ">=4.2,<4.2.9|>=4.3,<4.3.3",
+ "ckeditor/ckeditor": "<4.24",
+ "cockpit-hq/cockpit": "<2.7|==2.7",
+ "codeception/codeception": "<3.1.3|>=4,<4.1.22",
+ "codeigniter/framework": "<3.1.9",
+ "codeigniter4/framework": "<4.4.7",
+ "codeigniter4/shield": "<1.0.0.0-beta8",
+ "codiad/codiad": "<=2.8.4",
+ "composer/composer": "<1.10.27|>=2,<2.2.24|>=2.3,<2.7.7",
+ "concrete5/concrete5": "<9.3.4",
+ "concrete5/core": "<8.5.8|>=9,<9.1",
+ "contao-components/mediaelement": ">=2.14.2,<2.21.1",
+ "contao/comments-bundle": ">=2,<4.13.40|>=5.0.0.0-RC1-dev,<5.3.4",
+ "contao/contao": "<=5.4.1",
+ "contao/core": "<3.5.39",
+ "contao/core-bundle": "<4.13.49|>=5,<5.3.15|>=5.4,<5.4.3",
+ "contao/listing-bundle": ">=3,<=3.5.30|>=4,<4.4.8",
+ "contao/managed-edition": "<=1.5",
+ "corveda/phpsandbox": "<1.3.5",
+ "cosenary/instagram": "<=2.3",
+ "craftcms/cms": "<=4.12.6.1|>=5,<=5.4.7.1",
+ "croogo/croogo": "<4",
+ "cuyz/valinor": "<0.12",
+ "czim/file-handling": "<1.5|>=2,<2.3",
+ "czproject/git-php": "<4.0.3",
+ "damienharper/auditor-bundle": "<5.2.6",
+ "dapphp/securimage": "<3.6.6",
+ "darylldoyle/safe-svg": "<1.9.10",
+ "datadog/dd-trace": ">=0.30,<0.30.2",
+ "datatables/datatables": "<1.10.10",
+ "david-garcia/phpwhois": "<=4.3.1",
+ "dbrisinajumi/d2files": "<1",
+ "dcat/laravel-admin": "<=2.1.3",
+ "derhansen/fe_change_pwd": "<2.0.5|>=3,<3.0.3",
+ "derhansen/sf_event_mgt": "<4.3.1|>=5,<5.1.1|>=7,<7.4",
+ "desperado/xml-bundle": "<=0.1.7",
+ "dev-lancer/minecraft-motd-parser": "<=1.0.5",
+ "devgroup/dotplant": "<2020.09.14-dev",
+ "directmailteam/direct-mail": "<6.0.3|>=7,<7.0.3|>=8,<9.5.2",
+ "doctrine/annotations": "<1.2.7",
+ "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2",
+ "doctrine/common": "<2.4.3|>=2.5,<2.5.1",
+ "doctrine/dbal": ">=2,<2.0.8|>=2.1,<2.1.2|>=3,<3.1.4",
+ "doctrine/doctrine-bundle": "<1.5.2",
+ "doctrine/doctrine-module": "<0.7.2",
+ "doctrine/mongodb-odm": "<1.0.2",
+ "doctrine/mongodb-odm-bundle": "<3.0.1",
+ "doctrine/orm": ">=1,<1.2.4|>=2,<2.4.8|>=2.5,<2.5.1|>=2.8.3,<2.8.4",
+ "dolibarr/dolibarr": "<19.0.2",
+ "dompdf/dompdf": "<2.0.4",
+ "doublethreedigital/guest-entries": "<3.1.2",
+ "drupal/core": ">=6,<6.38|>=7,<7.96|>=8,<10.2.10|>=10.3,<10.3.6|>=11,<11.0.5",
+ "drupal/core-recommended": ">=8,<10.2.9|>=10.3,<10.3.6|>=11,<11.0.5",
+ "drupal/drupal": ">=5,<5.11|>=6,<6.38|>=7,<7.80|>=8,<10.2.9|>=10.3,<10.3.6|>=11,<11.0.5",
+ "duncanmcclean/guest-entries": "<3.1.2",
+ "dweeves/magmi": "<=0.7.24",
+ "ec-cube/ec-cube": "<2.4.4|>=2.11,<=2.17.1|>=3,<=3.0.18.0-patch4|>=4,<=4.1.2",
+ "ecodev/newsletter": "<=4",
+ "ectouch/ectouch": "<=2.7.2",
+ "egroupware/egroupware": "<23.1.20240624",
+ "elefant/cms": "<2.0.7",
+ "elgg/elgg": "<3.3.24|>=4,<4.0.5",
+ "elijaa/phpmemcacheadmin": "<=1.3",
+ "encore/laravel-admin": "<=1.8.19",
+ "endroid/qr-code-bundle": "<3.4.2",
+ "enhavo/enhavo-app": "<=0.13.1",
+ "enshrined/svg-sanitize": "<0.15",
+ "erusev/parsedown": "<1.7.2",
+ "ether/logs": "<3.0.4",
+ "evolutioncms/evolution": "<=3.2.3",
+ "exceedone/exment": "<4.4.3|>=5,<5.0.3",
+ "exceedone/laravel-admin": "<2.2.3|==3",
+ "ezsystems/demobundle": ">=5.4,<5.4.6.1-dev",
+ "ezsystems/ez-support-tools": ">=2.2,<2.2.3",
+ "ezsystems/ezdemo-ls-extension": ">=5.4,<5.4.2.1-dev",
+ "ezsystems/ezfind-ls": ">=5.3,<5.3.6.1-dev|>=5.4,<5.4.11.1-dev|>=2017.12,<2017.12.0.1-dev",
+ "ezsystems/ezplatform": "<=1.13.6|>=2,<=2.5.24",
+ "ezsystems/ezplatform-admin-ui": ">=1.3,<1.3.5|>=1.4,<1.4.6|>=1.5,<1.5.29|>=2.3,<2.3.26|>=3.3,<3.3.39",
+ "ezsystems/ezplatform-admin-ui-assets": ">=4,<4.2.1|>=5,<5.0.1|>=5.1,<5.1.1",
+ "ezsystems/ezplatform-graphql": ">=1.0.0.0-RC1-dev,<1.0.13|>=2.0.0.0-beta1,<2.3.12",
+ "ezsystems/ezplatform-http-cache": "<2.3.16",
+ "ezsystems/ezplatform-kernel": "<1.2.5.1-dev|>=1.3,<1.3.35",
+ "ezsystems/ezplatform-rest": ">=1.2,<=1.2.2|>=1.3,<1.3.8",
+ "ezsystems/ezplatform-richtext": ">=2.3,<2.3.7.1-dev|>=3.3,<3.3.40",
+ "ezsystems/ezplatform-solr-search-engine": ">=1.7,<1.7.12|>=2,<2.0.2|>=3.3,<3.3.15",
+ "ezsystems/ezplatform-user": ">=1,<1.0.1",
+ "ezsystems/ezpublish-kernel": "<6.13.8.2-dev|>=7,<7.5.31",
+ "ezsystems/ezpublish-legacy": "<=2017.12.7.3|>=2018.6,<=2019.03.5.1",
+ "ezsystems/platform-ui-assets-bundle": ">=4.2,<4.2.3",
+ "ezsystems/repository-forms": ">=2.3,<2.3.2.1-dev|>=2.5,<2.5.15",
+ "ezyang/htmlpurifier": "<=4.2",
+ "facade/ignition": "<1.16.15|>=2,<2.4.2|>=2.5,<2.5.2",
+ "facturascripts/facturascripts": "<=2022.08",
+ "fastly/magento2": "<1.2.26",
+ "feehi/cms": "<=2.1.1",
+ "feehi/feehicms": "<=2.1.1",
+ "fenom/fenom": "<=2.12.1",
+ "filament/actions": ">=3.2,<3.2.123",
+ "filament/infolists": ">=3,<3.2.115",
+ "filament/tables": ">=3,<3.2.115",
+ "filegator/filegator": "<7.8",
+ "filp/whoops": "<2.1.13",
+ "fineuploader/php-traditional-server": "<=1.2.2",
+ "firebase/php-jwt": "<6",
+ "fisharebest/webtrees": "<=2.1.18",
+ "fixpunkt/fp-masterquiz": "<2.2.1|>=3,<3.5.2",
+ "fixpunkt/fp-newsletter": "<1.1.1|>=2,<2.1.2|>=2.2,<3.2.6",
+ "flarum/core": "<1.8.5",
+ "flarum/flarum": "<0.1.0.0-beta8",
+ "flarum/framework": "<1.8.5",
+ "flarum/mentions": "<1.6.3",
+ "flarum/sticky": ">=0.1.0.0-beta14,<=0.1.0.0-beta15",
+ "flarum/tags": "<=0.1.0.0-beta13",
+ "floriangaerber/magnesium": "<0.3.1",
+ "fluidtypo3/vhs": "<5.1.1",
+ "fof/byobu": ">=0.3.0.0-beta2,<1.1.7",
+ "fof/upload": "<1.2.3",
+ "foodcoopshop/foodcoopshop": ">=3.2,<3.6.1",
+ "fooman/tcpdf": "<6.2.22",
+ "forkcms/forkcms": "<5.11.1",
+ "fossar/tcpdf-parser": "<6.2.22",
+ "francoisjacquet/rosariosis": "<=11.5.1",
+ "frappant/frp-form-answers": "<3.1.2|>=4,<4.0.2",
+ "friendsofsymfony/oauth2-php": "<1.3",
+ "friendsofsymfony/rest-bundle": ">=1.2,<1.2.2",
+ "friendsofsymfony/user-bundle": ">=1,<1.3.5",
+ "friendsofsymfony1/swiftmailer": ">=4,<5.4.13|>=6,<6.2.5",
+ "friendsofsymfony1/symfony1": ">=1.1,<1.5.19",
+ "friendsoftypo3/mediace": ">=7.6.2,<7.6.5",
+ "friendsoftypo3/openid": ">=4.5,<4.5.31|>=4.7,<4.7.16|>=6,<6.0.11|>=6.1,<6.1.6",
+ "froala/wysiwyg-editor": "<3.2.7|>=4.0.1,<=4.1.3",
+ "froxlor/froxlor": "<=2.2.0.0-RC3",
+ "frozennode/administrator": "<=5.0.12",
+ "fuel/core": "<1.8.1",
+ "funadmin/funadmin": "<=5.0.2",
+ "gaoming13/wechat-php-sdk": "<=1.10.2",
+ "genix/cms": "<=1.1.11",
+ "getformwork/formwork": "<1.13.1|==2.0.0.0-beta1",
+ "getgrav/grav": "<1.7.46",
+ "getkirby/cms": "<=3.6.6.5|>=3.7,<=3.7.5.4|>=3.8,<=3.8.4.3|>=3.9,<=3.9.8.1|>=3.10,<=3.10.1|>=4,<=4.3",
+ "getkirby/kirby": "<=2.5.12",
+ "getkirby/panel": "<2.5.14",
+ "getkirby/starterkit": "<=3.7.0.2",
+ "gilacms/gila": "<=1.15.4",
+ "gleez/cms": "<=1.3|==2",
+ "globalpayments/php-sdk": "<2",
+ "gogentooss/samlbase": "<1.2.7",
+ "google/protobuf": "<3.15",
+ "gos/web-socket-bundle": "<1.10.4|>=2,<2.6.1|>=3,<3.3",
+ "gree/jose": "<2.2.1",
+ "gregwar/rst": "<1.0.3",
+ "grumpydictator/firefly-iii": "<6.1.17",
+ "gugoan/economizzer": "<=0.9.0.0-beta1",
+ "guzzlehttp/guzzle": "<6.5.8|>=7,<7.4.5",
+ "guzzlehttp/psr7": "<1.9.1|>=2,<2.4.5",
+ "haffner/jh_captcha": "<=2.1.3|>=3,<=3.0.2",
+ "harvesthq/chosen": "<1.8.7",
+ "helloxz/imgurl": "<=2.31",
+ "hhxsv5/laravel-s": "<3.7.36",
+ "hillelcoren/invoice-ninja": "<5.3.35",
+ "himiklab/yii2-jqgrid-widget": "<1.0.8",
+ "hjue/justwriting": "<=1",
+ "hov/jobfair": "<1.0.13|>=2,<2.0.2",
+ "httpsoft/http-message": "<1.0.12",
+ "hyn/multi-tenant": ">=5.6,<5.7.2",
+ "ibexa/admin-ui": ">=4.2,<4.2.3|>=4.6,<4.6.14",
+ "ibexa/core": ">=4,<4.0.7|>=4.1,<4.1.4|>=4.2,<4.2.3|>=4.5,<4.5.6|>=4.6,<4.6.2",
+ "ibexa/fieldtype-richtext": ">=4.6,<4.6.10",
+ "ibexa/graphql": ">=2.5,<2.5.31|>=3.3,<3.3.28|>=4.2,<4.2.3",
+ "ibexa/http-cache": ">=4.6,<4.6.14",
+ "ibexa/post-install": "<1.0.16|>=4.6,<4.6.14",
+ "ibexa/solr": ">=4.5,<4.5.4",
+ "ibexa/user": ">=4,<4.4.3",
+ "icecoder/icecoder": "<=8.1",
+ "idno/known": "<=1.3.1",
+ "ilicmiljan/secure-props": ">=1.2,<1.2.2",
+ "illuminate/auth": "<5.5.10",
+ "illuminate/cookie": ">=4,<=4.0.11|>=4.1,<6.18.31|>=7,<7.22.4",
+ "illuminate/database": "<6.20.26|>=7,<7.30.5|>=8,<8.40",
+ "illuminate/encryption": ">=4,<=4.0.11|>=4.1,<=4.1.31|>=4.2,<=4.2.22|>=5,<=5.0.35|>=5.1,<=5.1.46|>=5.2,<=5.2.45|>=5.3,<=5.3.31|>=5.4,<=5.4.36|>=5.5,<5.5.40|>=5.6,<5.6.15",
+ "illuminate/view": "<6.20.42|>=7,<7.30.6|>=8,<8.75",
+ "imdbphp/imdbphp": "<=5.1.1",
+ "impresscms/impresscms": "<=1.4.5",
+ "impresspages/impresspages": "<=1.0.12",
+ "in2code/femanager": "<5.5.3|>=6,<6.3.4|>=7,<7.2.3",
+ "in2code/ipandlanguageredirect": "<5.1.2",
+ "in2code/lux": "<17.6.1|>=18,<24.0.2",
+ "in2code/powermail": "<7.5.1|>=8,<8.5.1|>=9,<10.9.1|>=11,<12.4.1",
+ "innologi/typo3-appointments": "<2.0.6",
+ "intelliants/subrion": "<4.2.2",
+ "inter-mediator/inter-mediator": "==5.5",
+ "ipl/web": "<0.10.1",
+ "islandora/islandora": ">=2,<2.4.1",
+ "ivankristianto/phpwhois": "<=4.3",
+ "jackalope/jackalope-doctrine-dbal": "<1.7.4",
+ "james-heinrich/getid3": "<1.9.21",
+ "james-heinrich/phpthumb": "<1.7.12",
+ "jasig/phpcas": "<1.3.3",
+ "jcbrand/converse.js": "<3.3.3",
+ "johnbillion/wp-crontrol": "<1.16.2",
+ "joomla/application": "<1.0.13",
+ "joomla/archive": "<1.1.12|>=2,<2.0.1",
+ "joomla/filesystem": "<1.6.2|>=2,<2.0.1",
+ "joomla/filter": "<1.4.4|>=2,<2.0.1",
+ "joomla/framework": "<1.5.7|>=2.5.4,<=3.8.12",
+ "joomla/input": ">=2,<2.0.2",
+ "joomla/joomla-cms": ">=2.5,<3.9.12",
+ "joomla/session": "<1.3.1",
+ "joyqi/hyper-down": "<=2.4.27",
+ "jsdecena/laracom": "<2.0.9",
+ "jsmitty12/phpwhois": "<5.1",
+ "juzaweb/cms": "<=3.4",
+ "jweiland/events2": "<8.3.8|>=9,<9.0.6",
+ "kazist/phpwhois": "<=4.2.6",
+ "kelvinmo/simplexrd": "<3.1.1",
+ "kevinpapst/kimai2": "<1.16.7",
+ "khodakhah/nodcms": "<=3",
+ "kimai/kimai": "<=2.20.1",
+ "kitodo/presentation": "<3.2.3|>=3.3,<3.3.4",
+ "klaviyo/magento2-extension": ">=1,<3",
+ "knplabs/knp-snappy": "<=1.4.2",
+ "kohana/core": "<3.3.3",
+ "krayin/laravel-crm": "<=1.3",
+ "kreait/firebase-php": ">=3.2,<3.8.1",
+ "kumbiaphp/kumbiapp": "<=1.1.1",
+ "la-haute-societe/tcpdf": "<6.2.22",
+ "laminas/laminas-diactoros": "<2.18.1|==2.19|==2.20|==2.21|==2.22|==2.23|>=2.24,<2.24.2|>=2.25,<2.25.2",
+ "laminas/laminas-form": "<2.17.1|>=3,<3.0.2|>=3.1,<3.1.1",
+ "laminas/laminas-http": "<2.14.2",
+ "lara-zeus/artemis": ">=1,<=1.0.6",
+ "lara-zeus/dynamic-dashboard": ">=3,<=3.0.1",
+ "laravel/fortify": "<1.11.1",
+ "laravel/framework": "<6.20.45|>=7,<7.30.7|>=8,<8.83.28|>=9,<9.52.17|>=10,<10.48.23|>=11,<11.31",
+ "laravel/laravel": ">=5.4,<5.4.22",
+ "laravel/reverb": "<1.4",
+ "laravel/socialite": ">=1,<2.0.10",
+ "latte/latte": "<2.10.8",
+ "lavalite/cms": "<=9|==10.1",
+ "lcobucci/jwt": ">=3.4,<3.4.6|>=4,<4.0.4|>=4.1,<4.1.5",
+ "league/commonmark": "<0.18.3",
+ "league/flysystem": "<1.1.4|>=2,<2.1.1",
+ "league/oauth2-server": ">=8.3.2,<8.4.2|>=8.5,<8.5.3",
+ "lexik/jwt-authentication-bundle": "<2.10.7|>=2.11,<2.11.3",
+ "libreform/libreform": ">=2,<=2.0.8",
+ "librenms/librenms": "<2017.08.18",
+ "liftkit/database": "<2.13.2",
+ "lightsaml/lightsaml": "<1.3.5",
+ "limesurvey/limesurvey": "<6.5.12",
+ "livehelperchat/livehelperchat": "<=3.91",
+ "livewire/livewire": "<2.12.7|>=3.0.0.0-beta1,<3.5.2",
+ "lms/routes": "<2.1.1",
+ "localizationteam/l10nmgr": "<7.4|>=8,<8.7|>=9,<9.2",
+ "luyadev/yii-helpers": "<1.2.1",
+ "maestroerror/php-heic-to-jpg": "<1.0.5",
+ "magento/community-edition": "<2.4.5|==2.4.5|>=2.4.5.0-patch1,<2.4.5.0-patch10|==2.4.6|>=2.4.6.0-patch1,<2.4.6.0-patch8|>=2.4.7.0-beta1,<2.4.7.0-patch3",
+ "magento/core": "<=1.9.4.5",
+ "magento/magento1ce": "<1.9.4.3-dev",
+ "magento/magento1ee": ">=1,<1.14.4.3-dev",
+ "magento/product-community-edition": "<2.4.4.0-patch9|>=2.4.5,<2.4.5.0-patch8|>=2.4.6,<2.4.6.0-patch6|>=2.4.7,<2.4.7.0-patch1",
+ "magneto/core": "<1.9.4.4-dev",
+ "maikuolan/phpmussel": ">=1,<1.6",
+ "mainwp/mainwp": "<=4.4.3.3",
+ "mantisbt/mantisbt": "<=2.26.3",
+ "marcwillmann/turn": "<0.3.3",
+ "matyhtf/framework": "<3.0.6",
+ "mautic/core": "<4.4.13|>=5,<5.1.1",
+ "mautic/core-lib": ">=1.0.0.0-beta,<4.4.13|>=5.0.0.0-alpha,<5.1.1",
+ "maximebf/debugbar": "<1.19",
+ "mdanter/ecc": "<2",
+ "mediawiki/abuse-filter": "<1.39.9|>=1.40,<1.41.3|>=1.42,<1.42.2",
+ "mediawiki/cargo": "<3.6.1",
+ "mediawiki/core": "<1.39.5|==1.40",
+ "mediawiki/matomo": "<2.4.3",
+ "mediawiki/semantic-media-wiki": "<4.0.2",
+ "melisplatform/melis-asset-manager": "<5.0.1",
+ "melisplatform/melis-cms": "<5.0.1",
+ "melisplatform/melis-front": "<5.0.1",
+ "mezzio/mezzio-swoole": "<3.7|>=4,<4.3",
+ "mgallegos/laravel-jqgrid": "<=1.3",
+ "microsoft/microsoft-graph": ">=1.16,<1.109.1|>=2,<2.0.1",
+ "microsoft/microsoft-graph-beta": "<2.0.1",
+ "microsoft/microsoft-graph-core": "<2.0.2",
+ "microweber/microweber": "<=2.0.16",
+ "mikehaertl/php-shellcommand": "<1.6.1",
+ "miniorange/miniorange-saml": "<1.4.3",
+ "mittwald/typo3_forum": "<1.2.1",
+ "mobiledetect/mobiledetectlib": "<2.8.32",
+ "modx/revolution": "<=2.8.3.0-patch",
+ "mojo42/jirafeau": "<4.4",
+ "mongodb/mongodb": ">=1,<1.9.2",
+ "monolog/monolog": ">=1.8,<1.12",
+ "moodle/moodle": "<4.3.8|>=4.4,<4.4.4",
+ "mos/cimage": "<0.7.19",
+ "movim/moxl": ">=0.8,<=0.10",
+ "movingbytes/social-network": "<=1.2.1",
+ "mpdf/mpdf": "<=7.1.7",
+ "munkireport/comment": "<4.1",
+ "munkireport/managedinstalls": "<2.6",
+ "munkireport/munki_facts": "<1.5",
+ "munkireport/munkireport": ">=2.5.3,<5.6.3",
+ "munkireport/reportdata": "<3.5",
+ "munkireport/softwareupdate": "<1.6",
+ "mustache/mustache": ">=2,<2.14.1",
+ "namshi/jose": "<2.2",
+ "nategood/httpful": "<1",
+ "neoan3-apps/template": "<1.1.1",
+ "neorazorx/facturascripts": "<2022.04",
+ "neos/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.12|>=3.1,<3.1.10|>=3.2,<3.2.13|>=3.3,<3.3.13|>=4,<4.0.6",
+ "neos/form": ">=1.2,<4.3.3|>=5,<5.0.9|>=5.1,<5.1.3",
+ "neos/media-browser": "<7.3.19|>=8,<8.0.16|>=8.1,<8.1.11|>=8.2,<8.2.11|>=8.3,<8.3.9",
+ "neos/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4|>=2.3,<3.0.20|>=3.1,<3.1.18|>=3.2,<3.2.14|>=3.3,<5.3.10|>=7,<7.0.9|>=7.1,<7.1.7|>=7.2,<7.2.6|>=7.3,<7.3.4|>=8,<8.0.2",
+ "neos/swiftmailer": "<5.4.5",
+ "netgen/tagsbundle": ">=3.4,<3.4.11|>=4,<4.0.15",
+ "nette/application": ">=2,<2.0.19|>=2.1,<2.1.13|>=2.2,<2.2.10|>=2.3,<2.3.14|>=2.4,<2.4.16|>=3,<3.0.6",
+ "nette/nette": ">=2,<2.0.19|>=2.1,<2.1.13",
+ "nilsteampassnet/teampass": "<3.0.10",
+ "nonfiction/nterchange": "<4.1.1",
+ "notrinos/notrinos-erp": "<=0.7",
+ "noumo/easyii": "<=0.9",
+ "novaksolutions/infusionsoft-php-sdk": "<1",
+ "nukeviet/nukeviet": "<4.5.02",
+ "nyholm/psr7": "<1.6.1",
+ "nystudio107/craft-seomatic": "<3.4.12",
+ "nzedb/nzedb": "<0.8",
+ "nzo/url-encryptor-bundle": ">=4,<4.3.2|>=5,<5.0.1",
+ "october/backend": "<1.1.2",
+ "october/cms": "<1.0.469|==1.0.469|==1.0.471|==1.1.1",
+ "october/october": "<=3.6.4",
+ "october/rain": "<1.0.472|>=1.1,<1.1.2",
+ "october/system": "<1.0.476|>=1.1,<1.1.12|>=2,<2.2.34|>=3,<3.5.15",
+ "omeka/omeka-s": "<4.0.3",
+ "onelogin/php-saml": "<2.10.4",
+ "oneup/uploader-bundle": ">=1,<1.9.3|>=2,<2.1.5",
+ "open-web-analytics/open-web-analytics": "<1.7.4",
+ "opencart/opencart": ">=0",
+ "openid/php-openid": "<2.3",
+ "openmage/magento-lts": "<20.10.1",
+ "opensolutions/vimbadmin": "<=3.0.15",
+ "opensource-workshop/connect-cms": "<1.7.2|>=2,<2.3.2",
+ "orchid/platform": ">=8,<14.43",
+ "oro/calendar-bundle": ">=4.2,<=4.2.6|>=5,<=5.0.6|>=5.1,<5.1.1",
+ "oro/commerce": ">=4.1,<5.0.11|>=5.1,<5.1.1",
+ "oro/crm": ">=1.7,<1.7.4|>=3.1,<4.1.17|>=4.2,<4.2.7",
+ "oro/crm-call-bundle": ">=4.2,<=4.2.5|>=5,<5.0.4|>=5.1,<5.1.1",
+ "oro/customer-portal": ">=4.1,<=4.1.13|>=4.2,<=4.2.10|>=5,<=5.0.11|>=5.1,<=5.1.3",
+ "oro/platform": ">=1.7,<1.7.4|>=3.1,<3.1.29|>=4.1,<4.1.17|>=4.2,<=4.2.10|>=5,<=5.0.12|>=5.1,<=5.1.3",
+ "oveleon/contao-cookiebar": "<1.16.3|>=2,<2.1.3",
+ "oxid-esales/oxideshop-ce": "<4.5",
+ "oxid-esales/paymorrow-module": ">=1,<1.0.2|>=2,<2.0.1",
+ "packbackbooks/lti-1-3-php-library": "<5",
+ "padraic/humbug_get_contents": "<1.1.2",
+ "pagarme/pagarme-php": "<3",
+ "pagekit/pagekit": "<=1.0.18",
+ "paragonie/ecc": "<2.0.1",
+ "paragonie/random_compat": "<2",
+ "passbolt/passbolt_api": "<4.6.2",
+ "paypal/adaptivepayments-sdk-php": "<=3.9.2",
+ "paypal/invoice-sdk-php": "<=3.9",
+ "paypal/merchant-sdk-php": "<3.12",
+ "paypal/permissions-sdk-php": "<=3.9.1",
+ "pear/archive_tar": "<1.4.14",
+ "pear/auth": "<1.2.4",
+ "pear/crypt_gpg": "<1.6.7",
+ "pear/pear": "<=1.10.1",
+ "pegasus/google-for-jobs": "<1.5.1|>=2,<2.1.1",
+ "personnummer/personnummer": "<3.0.2",
+ "phanan/koel": "<5.1.4",
+ "phenx/php-svg-lib": "<0.5.2",
+ "php-censor/php-censor": "<2.0.13|>=2.1,<2.1.5",
+ "php-mod/curl": "<2.3.2",
+ "phpbb/phpbb": "<3.3.11",
+ "phpems/phpems": ">=6,<=6.1.3",
+ "phpfastcache/phpfastcache": "<6.1.5|>=7,<7.1.2|>=8,<8.0.7",
+ "phpmailer/phpmailer": "<6.5",
+ "phpmussel/phpmussel": ">=1,<1.6",
+ "phpmyadmin/phpmyadmin": "<5.2.1",
+ "phpmyfaq/phpmyfaq": "<3.2.5|==3.2.5",
+ "phpoffice/common": "<0.2.9",
+ "phpoffice/phpexcel": "<1.8.1",
+ "phpoffice/phpspreadsheet": "<1.29.4|>=2,<2.1.3|>=2.2,<2.3.2|>=3.3,<3.4",
+ "phpseclib/phpseclib": "<2.0.47|>=3,<3.0.36",
+ "phpservermon/phpservermon": "<3.6",
+ "phpsysinfo/phpsysinfo": "<3.4.3",
+ "phpunit/phpunit": ">=4.8.19,<4.8.28|>=5.0.10,<5.6.3",
+ "phpwhois/phpwhois": "<=4.2.5",
+ "phpxmlrpc/extras": "<0.6.1",
+ "phpxmlrpc/phpxmlrpc": "<4.9.2",
+ "pi/pi": "<=2.5",
+ "pimcore/admin-ui-classic-bundle": "<1.5.4",
+ "pimcore/customer-management-framework-bundle": "<4.0.6",
+ "pimcore/data-hub": "<1.2.4",
+ "pimcore/data-importer": "<1.8.9|>=1.9,<1.9.3",
+ "pimcore/demo": "<10.3",
+ "pimcore/ecommerce-framework-bundle": "<1.0.10",
+ "pimcore/perspective-editor": "<1.5.1",
+ "pimcore/pimcore": "<11.2.4",
+ "pixelfed/pixelfed": "<0.11.11",
+ "plotly/plotly.js": "<2.25.2",
+ "pocketmine/bedrock-protocol": "<8.0.2",
+ "pocketmine/pocketmine-mp": "<5.11.2",
+ "pocketmine/raklib": ">=0.14,<0.14.6|>=0.15,<0.15.1",
+ "pressbooks/pressbooks": "<5.18",
+ "prestashop/autoupgrade": ">=4,<4.10.1",
+ "prestashop/blockreassurance": "<=5.1.3",
+ "prestashop/blockwishlist": ">=2,<2.1.1",
+ "prestashop/contactform": ">=1.0.1,<4.3",
+ "prestashop/gamification": "<2.3.2",
+ "prestashop/prestashop": "<8.1.6",
+ "prestashop/productcomments": "<5.0.2",
+ "prestashop/ps_emailsubscription": "<2.6.1",
+ "prestashop/ps_facetedsearch": "<3.4.1",
+ "prestashop/ps_linklist": "<3.1",
+ "privatebin/privatebin": "<1.4|>=1.5,<1.7.4",
+ "processwire/processwire": "<=3.0.229",
+ "propel/propel": ">=2.0.0.0-alpha1,<=2.0.0.0-alpha7",
+ "propel/propel1": ">=1,<=1.7.1",
+ "pterodactyl/panel": "<1.11.8",
+ "ptheofan/yii2-statemachine": ">=2.0.0.0-RC1-dev,<=2",
+ "ptrofimov/beanstalk_console": "<1.7.14",
+ "pubnub/pubnub": "<6.1",
+ "pusher/pusher-php-server": "<2.2.1",
+ "pwweb/laravel-core": "<=0.3.6.0-beta",
+ "pxlrbt/filament-excel": "<1.1.14|>=2.0.0.0-alpha,<2.3.3",
+ "pyrocms/pyrocms": "<=3.9.1",
+ "qcubed/qcubed": "<=3.1.1",
+ "quickapps/cms": "<=2.0.0.0-beta2",
+ "rainlab/blog-plugin": "<1.4.1",
+ "rainlab/debugbar-plugin": "<3.1",
+ "rainlab/user-plugin": "<=1.4.5",
+ "rankmath/seo-by-rank-math": "<=1.0.95",
+ "rap2hpoutre/laravel-log-viewer": "<0.13",
+ "react/http": ">=0.7,<1.9",
+ "really-simple-plugins/complianz-gdpr": "<6.4.2",
+ "redaxo/source": "<5.18",
+ "remdex/livehelperchat": "<4.29",
+ "reportico-web/reportico": "<=8.1",
+ "rhukster/dom-sanitizer": "<1.0.7",
+ "rmccue/requests": ">=1.6,<1.8",
+ "robrichards/xmlseclibs": ">=1,<3.0.4",
+ "roots/soil": "<4.1",
+ "rudloff/alltube": "<3.0.3",
+ "s-cart/core": "<6.9",
+ "s-cart/s-cart": "<6.9",
+ "sabberworm/php-css-parser": ">=1,<1.0.1|>=2,<2.0.1|>=3,<3.0.1|>=4,<4.0.1|>=5,<5.0.9|>=5.1,<5.1.3|>=5.2,<5.2.1|>=6,<6.0.2|>=7,<7.0.4|>=8,<8.0.1|>=8.1,<8.1.1|>=8.2,<8.2.1|>=8.3,<8.3.1",
+ "sabre/dav": ">=1.6,<1.7.11|>=1.8,<1.8.9",
+ "samwilson/unlinked-wikibase": "<1.39.6|>=1.40,<1.40.2|>=1.41,<1.41.1",
+ "scheb/two-factor-bundle": "<3.26|>=4,<4.11",
+ "sensiolabs/connect": "<4.2.3",
+ "serluck/phpwhois": "<=4.2.6",
+ "sfroemken/url_redirect": "<=1.2.1",
+ "sheng/yiicms": "<=1.2",
+ "shopware/core": "<=6.5.8.12|>=6.6,<=6.6.5",
+ "shopware/platform": "<=6.5.8.12|>=6.6,<=6.6.5",
+ "shopware/production": "<=6.3.5.2",
+ "shopware/shopware": "<=5.7.17",
+ "shopware/storefront": "<=6.4.8.1|>=6.5.8,<6.5.8.7-dev",
+ "shopxo/shopxo": "<=6.1",
+ "showdoc/showdoc": "<2.10.4",
+ "silverstripe-australia/advancedreports": ">=1,<=2",
+ "silverstripe/admin": "<1.13.19|>=2,<2.1.8",
+ "silverstripe/assets": ">=1,<1.11.1",
+ "silverstripe/cms": "<4.11.3",
+ "silverstripe/comments": ">=1.3,<3.1.1",
+ "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3",
+ "silverstripe/framework": "<5.2.16",
+ "silverstripe/graphql": ">=2,<2.0.5|>=3,<3.8.2|>=4,<4.3.7|>=5,<5.1.3",
+ "silverstripe/hybridsessions": ">=1,<2.4.1|>=2.5,<2.5.1",
+ "silverstripe/recipe-cms": ">=4.5,<4.5.3",
+ "silverstripe/registry": ">=2.1,<2.1.2|>=2.2,<2.2.1",
+ "silverstripe/reports": "<5.2.3",
+ "silverstripe/restfulserver": ">=1,<1.0.9|>=2,<2.0.4|>=2.1,<2.1.2",
+ "silverstripe/silverstripe-omnipay": "<2.5.2|>=3,<3.0.2|>=3.1,<3.1.4|>=3.2,<3.2.1",
+ "silverstripe/subsites": ">=2,<2.6.1",
+ "silverstripe/taxonomy": ">=1.3,<1.3.1|>=2,<2.0.1",
+ "silverstripe/userforms": "<3|>=5,<5.4.2",
+ "silverstripe/versioned-admin": ">=1,<1.11.1",
+ "simple-updates/phpwhois": "<=1",
+ "simplesamlphp/saml2": "<4.6.14|==5.0.0.0-alpha12",
+ "simplesamlphp/saml2-legacy": "<4.6.14",
+ "simplesamlphp/simplesamlphp": "<1.18.6",
+ "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1",
+ "simplesamlphp/simplesamlphp-module-openid": "<1",
+ "simplesamlphp/simplesamlphp-module-openidprovider": "<0.9",
+ "simplesamlphp/xml-common": "<1.20",
+ "simplesamlphp/xml-security": "==1.6.11",
+ "simplito/elliptic-php": "<1.0.6",
+ "sitegeist/fluid-components": "<3.5",
+ "sjbr/sr-freecap": "<2.4.6|>=2.5,<2.5.3",
+ "slim/psr7": "<1.4.1|>=1.5,<1.5.1|>=1.6,<1.6.1",
+ "slim/slim": "<2.6",
+ "slub/slub-events": "<3.0.3",
+ "smarty/smarty": "<4.5.3|>=5,<5.1.1",
+ "snipe/snipe-it": "<=7.0.13",
+ "socalnick/scn-social-auth": "<1.15.2",
+ "socialiteproviders/steam": "<1.1",
+ "spatie/browsershot": "<3.57.4",
+ "spatie/image-optimizer": "<1.7.3",
+ "spencer14420/sp-php-email-handler": "<1",
+ "spipu/html2pdf": "<5.2.8",
+ "spoon/library": "<1.4.1",
+ "spoonity/tcpdf": "<6.2.22",
+ "squizlabs/php_codesniffer": ">=1,<2.8.1|>=3,<3.0.1",
+ "ssddanbrown/bookstack": "<24.05.1",
+ "starcitizentools/citizen-skin": ">=2.6.3,<2.31",
+ "statamic/cms": "<=5.16",
+ "stormpath/sdk": "<9.9.99",
+ "studio-42/elfinder": "<=2.1.64",
+ "studiomitte/friendlycaptcha": "<0.1.4",
+ "subhh/libconnect": "<7.0.8|>=8,<8.1",
+ "sukohi/surpass": "<1",
+ "sulu/form-bundle": ">=2,<2.5.3",
+ "sulu/sulu": "<1.6.44|>=2,<2.5.21|>=2.6,<2.6.5",
+ "sumocoders/framework-user-bundle": "<1.4",
+ "superbig/craft-audit": "<3.0.2",
+ "swag/paypal": "<5.4.4",
+ "swiftmailer/swiftmailer": "<6.2.5",
+ "swiftyedit/swiftyedit": "<1.2",
+ "sylius/admin-bundle": ">=1,<1.0.17|>=1.1,<1.1.9|>=1.2,<1.2.2",
+ "sylius/grid": ">=1,<1.1.19|>=1.2,<1.2.18|>=1.3,<1.3.13|>=1.4,<1.4.5|>=1.5,<1.5.1",
+ "sylius/grid-bundle": "<1.10.1",
+ "sylius/paypal-plugin": ">=1,<1.2.4|>=1.3,<1.3.1",
+ "sylius/resource-bundle": ">=1,<1.3.14|>=1.4,<1.4.7|>=1.5,<1.5.2|>=1.6,<1.6.4",
+ "sylius/sylius": "<1.12.19|>=1.13.0.0-alpha1,<1.13.4",
+ "symbiote/silverstripe-multivaluefield": ">=3,<3.1",
+ "symbiote/silverstripe-queuedjobs": ">=3,<3.0.2|>=3.1,<3.1.4|>=4,<4.0.7|>=4.1,<4.1.2|>=4.2,<4.2.4|>=4.3,<4.3.3|>=4.4,<4.4.3|>=4.5,<4.5.1|>=4.6,<4.6.4",
+ "symbiote/silverstripe-seed": "<6.0.3",
+ "symbiote/silverstripe-versionedfiles": "<=2.0.3",
+ "symfont/process": ">=0",
+ "symfony/cache": ">=3.1,<3.4.35|>=4,<4.2.12|>=4.3,<4.3.8",
+ "symfony/dependency-injection": ">=2,<2.0.17|>=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7",
+ "symfony/error-handler": ">=4.4,<4.4.4|>=5,<5.0.4",
+ "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.50|>=2.8,<2.8.49|>=3,<3.4.20|>=4,<4.0.15|>=4.1,<4.1.9|>=4.2,<4.2.1",
+ "symfony/framework-bundle": ">=2,<2.3.18|>=2.4,<2.4.8|>=2.5,<2.5.2|>=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7|>=5.3.14,<5.3.15|>=5.4.3,<5.4.4|>=6.0.3,<6.0.4",
+ "symfony/http-client": ">=4.3,<5.4.47|>=6,<6.4.15|>=7,<7.1.8",
+ "symfony/http-foundation": "<5.4.46|>=6,<6.4.14|>=7,<7.1.7",
+ "symfony/http-kernel": ">=2,<4.4.50|>=5,<5.4.20|>=6,<6.0.20|>=6.1,<6.1.12|>=6.2,<6.2.6",
+ "symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13",
+ "symfony/maker-bundle": ">=1.27,<1.29.2|>=1.30,<1.31.1",
+ "symfony/mime": ">=4.3,<4.3.8",
+ "symfony/phpunit-bridge": ">=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7",
+ "symfony/polyfill": ">=1,<1.10",
+ "symfony/polyfill-php55": ">=1,<1.10",
+ "symfony/process": "<5.4.46|>=6,<6.4.14|>=7,<7.1.7",
+ "symfony/proxy-manager-bridge": ">=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7",
+ "symfony/routing": ">=2,<2.0.19",
+ "symfony/runtime": ">=5.3,<5.4.46|>=6,<6.4.14|>=7,<7.1.7",
+ "symfony/security": ">=2,<2.7.51|>=2.8,<3.4.49|>=4,<4.4.24|>=5,<5.2.8",
+ "symfony/security-bundle": ">=2,<4.4.50|>=5,<5.4.20|>=6,<6.0.20|>=6.1,<6.1.12|>=6.2,<6.4.10|>=7,<7.0.10|>=7.1,<7.1.3",
+ "symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<3.4.49|>=4,<4.4.24|>=5,<5.2.9",
+ "symfony/security-csrf": ">=2.4,<2.7.48|>=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11",
+ "symfony/security-guard": ">=2.8,<3.4.48|>=4,<4.4.23|>=5,<5.2.8",
+ "symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7|>=5.1,<5.2.8|>=5.3,<5.4.47|>=6,<6.4.15|>=7,<7.1.8",
+ "symfony/serializer": ">=2,<2.0.11|>=4.1,<4.4.35|>=5,<5.3.12",
+ "symfony/symfony": "<5.4.47|>=6,<6.4.15|>=7,<7.1.8",
+ "symfony/translation": ">=2,<2.0.17",
+ "symfony/twig-bridge": ">=2,<4.4.51|>=5,<5.4.31|>=6,<6.3.8",
+ "symfony/ux-autocomplete": "<2.11.2",
+ "symfony/validator": "<5.4.43|>=6,<6.4.11|>=7,<7.1.4",
+ "symfony/var-exporter": ">=4.2,<4.2.12|>=4.3,<4.3.8",
+ "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4",
+ "symfony/webhook": ">=6.3,<6.3.8",
+ "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7|>=2.2.0.0-beta1,<2.2.0.0-beta2",
+ "symphonycms/symphony-2": "<2.6.4",
+ "t3/dce": "<0.11.5|>=2.2,<2.6.2",
+ "t3g/svg-sanitizer": "<1.0.3",
+ "t3s/content-consent": "<1.0.3|>=2,<2.0.2",
+ "tastyigniter/tastyigniter": "<3.3",
+ "tcg/voyager": "<=1.4",
+ "tecnickcom/tcpdf": "<=6.7.5",
+ "terminal42/contao-tablelookupwizard": "<3.3.5",
+ "thelia/backoffice-default-template": ">=2.1,<2.1.2",
+ "thelia/thelia": ">=2.1,<2.1.3",
+ "theonedemon/phpwhois": "<=4.2.5",
+ "thinkcmf/thinkcmf": "<6.0.8",
+ "thorsten/phpmyfaq": "<4",
+ "tikiwiki/tiki-manager": "<=17.1",
+ "timber/timber": ">=0.16.6,<1.23.1|>=1.24,<1.24.1|>=2,<2.1",
+ "tinymce/tinymce": "<7.2",
+ "tinymighty/wiki-seo": "<1.2.2",
+ "titon/framework": "<9.9.99",
+ "tobiasbg/tablepress": "<=2.0.0.0-RC1",
+ "topthink/framework": "<6.0.17|>=6.1,<=8.0.4",
+ "topthink/think": "<=6.1.1",
+ "topthink/thinkphp": "<=3.2.3|>=6.1.3,<=8.0.4",
+ "torrentpier/torrentpier": "<=2.4.3",
+ "tpwd/ke_search": "<4.0.3|>=4.1,<4.6.6|>=5,<5.0.2",
+ "tribalsystems/zenario": "<=9.7.61188",
+ "truckersmp/phpwhois": "<=4.3.1",
+ "ttskch/pagination-service-provider": "<1",
+ "twbs/bootstrap": "<=3.4.1|>=4,<=4.6.2",
+ "twig/twig": "<3.11.2|>=3.12,<3.14.1",
+ "typo3/cms": "<9.5.29|>=10,<10.4.35|>=11,<11.5.23|>=12,<12.2",
+ "typo3/cms-backend": "<4.1.14|>=4.2,<4.2.15|>=4.3,<4.3.7|>=4.4,<4.4.4|>=7,<=7.6.50|>=8,<=8.7.39|>=9,<=9.5.24|>=10,<10.4.46|>=11,<11.5.40|>=12,<12.4.21|>=13,<13.3.1",
+ "typo3/cms-core": "<=8.7.56|>=9,<=9.5.47|>=10,<=10.4.44|>=11,<=11.5.36|>=12,<=12.4.14|>=13,<=13.1",
+ "typo3/cms-extbase": "<6.2.24|>=7,<7.6.8|==8.1.1",
+ "typo3/cms-fluid": "<4.3.4|>=4.4,<4.4.1",
+ "typo3/cms-form": ">=8,<=8.7.39|>=9,<=9.5.24|>=10,<=10.4.13|>=11,<=11.1",
+ "typo3/cms-frontend": "<4.3.9|>=4.4,<4.4.5",
+ "typo3/cms-install": "<4.1.14|>=4.2,<4.2.16|>=4.3,<4.3.9|>=4.4,<4.4.5|>=12.2,<12.4.8",
+ "typo3/cms-rte-ckeditor": ">=9.5,<9.5.42|>=10,<10.4.39|>=11,<11.5.30",
+ "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.12|>=3.1,<3.1.10|>=3.2,<3.2.13|>=3.3,<3.3.13|>=4,<4.0.6",
+ "typo3/html-sanitizer": ">=1,<=1.5.2|>=2,<=2.1.3",
+ "typo3/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4|>=2.3,<2.3.99|>=3,<3.0.20|>=3.1,<3.1.18|>=3.2,<3.2.14|>=3.3,<3.3.23|>=4,<4.0.17|>=4.1,<4.1.16|>=4.2,<4.2.12|>=4.3,<4.3.3",
+ "typo3/phar-stream-wrapper": ">=1,<2.1.1|>=3,<3.1.1",
+ "typo3/swiftmailer": ">=4.1,<4.1.99|>=5.4,<5.4.5",
+ "typo3fluid/fluid": ">=2,<2.0.8|>=2.1,<2.1.7|>=2.2,<2.2.4|>=2.3,<2.3.7|>=2.4,<2.4.4|>=2.5,<2.5.11|>=2.6,<2.6.10",
+ "ua-parser/uap-php": "<3.8",
+ "uasoft-indonesia/badaso": "<=2.9.7",
+ "unisharp/laravel-filemanager": "<2.6.4",
+ "unopim/unopim": "<0.1.5",
+ "userfrosting/userfrosting": ">=0.3.1,<4.6.3",
+ "usmanhalalit/pixie": "<1.0.3|>=2,<2.0.2",
+ "uvdesk/community-skeleton": "<=1.1.1",
+ "uvdesk/core-framework": "<=1.1.1",
+ "vanilla/safecurl": "<0.9.2",
+ "verbb/comments": "<1.5.5",
+ "verbb/formie": "<2.1.6",
+ "verbb/image-resizer": "<2.0.9",
+ "verbb/knock-knock": "<1.2.8",
+ "verot/class.upload.php": "<=2.1.6",
+ "villagedefrance/opencart-overclocked": "<=1.11.1",
+ "vova07/yii2-fileapi-widget": "<0.1.9",
+ "vrana/adminer": "<4.8.1",
+ "vufind/vufind": ">=2,<9.1.1",
+ "waldhacker/hcaptcha": "<2.1.2",
+ "wallabag/tcpdf": "<6.2.22",
+ "wallabag/wallabag": "<2.6.7",
+ "wanglelecc/laracms": "<=1.0.3",
+ "web-auth/webauthn-framework": ">=3.3,<3.3.4|>=4.5,<4.9",
+ "web-auth/webauthn-lib": ">=4.5,<4.9",
+ "web-feet/coastercms": "==5.5",
+ "webbuilders-group/silverstripe-kapost-bridge": "<0.4",
+ "webcoast/deferred-image-processing": "<1.0.2",
+ "webklex/laravel-imap": "<5.3",
+ "webklex/php-imap": "<5.3",
+ "webpa/webpa": "<3.1.2",
+ "wikibase/wikibase": "<=1.39.3",
+ "wikimedia/parsoid": "<0.12.2",
+ "willdurand/js-translation-bundle": "<2.1.1",
+ "winter/wn-backend-module": "<1.2.4",
+ "winter/wn-dusk-plugin": "<2.1",
+ "winter/wn-system-module": "<1.2.4",
+ "wintercms/winter": "<=1.2.3",
+ "wireui/wireui": "<1.19.3|>=2,<2.1.3",
+ "woocommerce/woocommerce": "<6.6|>=8.8,<8.8.5|>=8.9,<8.9.3",
+ "wp-cli/wp-cli": ">=0.12,<2.5",
+ "wp-graphql/wp-graphql": "<=1.14.5",
+ "wp-premium/gravityforms": "<2.4.21",
+ "wpanel/wpanel4-cms": "<=4.3.1",
+ "wpcloud/wp-stateless": "<3.2",
+ "wpglobus/wpglobus": "<=1.9.6",
+ "wwbn/avideo": "<14.3",
+ "xataface/xataface": "<3",
+ "xpressengine/xpressengine": "<3.0.15",
+ "yab/quarx": "<2.4.5",
+ "yeswiki/yeswiki": "<=4.4.4",
+ "yetiforce/yetiforce-crm": "<=6.4",
+ "yidashi/yii2cmf": "<=2",
+ "yii2mod/yii2-cms": "<1.9.2",
+ "yiisoft/yii": "<1.1.29",
+ "yiisoft/yii2": "<2.0.49.4-dev",
+ "yiisoft/yii2-authclient": "<2.2.15",
+ "yiisoft/yii2-bootstrap": "<2.0.4",
+ "yiisoft/yii2-dev": "<2.0.43",
+ "yiisoft/yii2-elasticsearch": "<2.0.5",
+ "yiisoft/yii2-gii": "<=2.2.4",
+ "yiisoft/yii2-jui": "<2.0.4",
+ "yiisoft/yii2-redis": "<2.0.8",
+ "yikesinc/yikes-inc-easy-mailchimp-extender": "<6.8.6",
+ "yoast-seo-for-typo3/yoast_seo": "<7.2.3",
+ "yourls/yourls": "<=1.8.2",
+ "yuan1994/tpadmin": "<=1.3.12",
+ "zencart/zencart": "<=1.5.7.0-beta",
+ "zendesk/zendesk_api_client_php": "<2.2.11",
+ "zendframework/zend-cache": ">=2.4,<2.4.8|>=2.5,<2.5.3",
+ "zendframework/zend-captcha": ">=2,<2.4.9|>=2.5,<2.5.2",
+ "zendframework/zend-crypt": ">=2,<2.4.9|>=2.5,<2.5.2",
+ "zendframework/zend-db": "<2.2.10|>=2.3,<2.3.5",
+ "zendframework/zend-developer-tools": ">=1.2.2,<1.2.3",
+ "zendframework/zend-diactoros": "<1.8.4",
+ "zendframework/zend-feed": "<2.10.3",
+ "zendframework/zend-form": ">=2,<2.2.7|>=2.3,<2.3.1",
+ "zendframework/zend-http": "<2.8.1",
+ "zendframework/zend-json": ">=2.1,<2.1.6|>=2.2,<2.2.6",
+ "zendframework/zend-ldap": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.8|>=2.3,<2.3.3",
+ "zendframework/zend-mail": "<2.4.11|>=2.5,<2.7.2",
+ "zendframework/zend-navigation": ">=2,<2.2.7|>=2.3,<2.3.1",
+ "zendframework/zend-session": ">=2,<2.2.9|>=2.3,<2.3.4",
+ "zendframework/zend-validator": ">=2.3,<2.3.6",
+ "zendframework/zend-view": ">=2,<2.2.7|>=2.3,<2.3.1",
+ "zendframework/zend-xmlrpc": ">=2.1,<2.1.6|>=2.2,<2.2.6",
+ "zendframework/zendframework": "<=3",
+ "zendframework/zendframework1": "<1.12.20",
+ "zendframework/zendopenid": "<2.0.2",
+ "zendframework/zendrest": "<2.0.2",
+ "zendframework/zendservice-amazon": "<2.0.3",
+ "zendframework/zendservice-api": "<1",
+ "zendframework/zendservice-audioscrobbler": "<2.0.2",
+ "zendframework/zendservice-nirvanix": "<2.0.2",
+ "zendframework/zendservice-slideshare": "<2.0.2",
+ "zendframework/zendservice-technorati": "<2.0.2",
+ "zendframework/zendservice-windowsazure": "<2.0.2",
+ "zendframework/zendxml": ">=1,<1.0.1",
+ "zenstruck/collection": "<0.2.1",
+ "zetacomponents/mail": "<1.8.2",
+ "zf-commons/zfc-user": "<1.2.2",
+ "zfcampus/zf-apigility-doctrine": ">=1,<1.0.3",
+ "zfr/zfr-oauth2-server-module": "<0.1.2",
+ "zoujingli/thinkadmin": "<=6.1.53"
+ },
+ "type": "metapackage",
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Marco Pivetta",
+ "email": "ocramius@gmail.com",
+ "role": "maintainer"
+ },
+ {
+ "name": "Ilya Tribusean",
+ "email": "slash3b@gmail.com",
+ "role": "maintainer"
+ }
+ ],
+ "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it",
+ "keywords": [
+ "dev"
+ ],
+ "support": {
+ "issues": "https://github.com/Roave/SecurityAdvisories/issues",
+ "source": "https://github.com/Roave/SecurityAdvisories/tree/latest"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/Ocramius",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/roave/security-advisories",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-12-06T23:05:03+00:00"
+ },
+ {
+ "name": "sebastian/cli-parser",
+ "version": "3.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/cli-parser.git",
+ "reference": "15c5dd40dc4f38794d383bb95465193f5e0ae180"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/15c5dd40dc4f38794d383bb95465193f5e0ae180",
+ "reference": "15c5dd40dc4f38794d383bb95465193f5e0ae180",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.0-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 for parsing CLI options",
+ "homepage": "https://github.com/sebastianbergmann/cli-parser",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/cli-parser/issues",
+ "security": "https://github.com/sebastianbergmann/cli-parser/security/policy",
+ "source": "https://github.com/sebastianbergmann/cli-parser/tree/3.0.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:41:36+00:00"
+ },
+ {
+ "name": "sebastian/code-unit",
+ "version": "3.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/code-unit.git",
+ "reference": "6bb7d09d6623567178cf54126afa9c2310114268"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/6bb7d09d6623567178cf54126afa9c2310114268",
+ "reference": "6bb7d09d6623567178cf54126afa9c2310114268",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.0-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": "Collection of value objects that represent the PHP code units",
+ "homepage": "https://github.com/sebastianbergmann/code-unit",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/code-unit/issues",
+ "security": "https://github.com/sebastianbergmann/code-unit/security/policy",
+ "source": "https://github.com/sebastianbergmann/code-unit/tree/3.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:44:28+00:00"
+ },
+ {
+ "name": "sebastian/code-unit-reverse-lookup",
+ "version": "4.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git",
+ "reference": "183a9b2632194febd219bb9246eee421dad8d45e"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/183a9b2632194febd219bb9246eee421dad8d45e",
+ "reference": "183a9b2632194febd219bb9246eee421dad8d45e",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "4.0-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/",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues",
+ "security": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/security/policy",
+ "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/4.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:45:54+00:00"
+ },
+ {
+ "name": "sebastian/comparator",
+ "version": "6.2.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/comparator.git",
+ "reference": "43d129d6a0f81c78bee378b46688293eb7ea3739"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/43d129d6a0f81c78bee378b46688293eb7ea3739",
+ "reference": "43d129d6a0f81c78bee378b46688293eb7ea3739",
+ "shasum": ""
+ },
+ "require": {
+ "ext-dom": "*",
+ "ext-mbstring": "*",
+ "php": ">=8.2",
+ "sebastian/diff": "^6.0",
+ "sebastian/exporter": "^6.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.4"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "6.2-dev"
+ }
+ },
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de"
+ },
+ {
+ "name": "Jeff Welch",
+ "email": "whatthejeff@gmail.com"
+ },
+ {
+ "name": "Volker Dusch",
+ "email": "github@wallbash.com"
+ },
+ {
+ "name": "Bernhard Schussek",
+ "email": "bschussek@2bepublished.at"
+ }
+ ],
+ "description": "Provides the functionality to compare PHP values for equality",
+ "homepage": "https://github.com/sebastianbergmann/comparator",
+ "keywords": [
+ "comparator",
+ "compare",
+ "equality"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/comparator/issues",
+ "security": "https://github.com/sebastianbergmann/comparator/security/policy",
+ "source": "https://github.com/sebastianbergmann/comparator/tree/6.2.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-10-31T05:30:08+00:00"
+ },
+ {
+ "name": "sebastian/complexity",
+ "version": "4.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/complexity.git",
+ "reference": "ee41d384ab1906c68852636b6de493846e13e5a0"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/ee41d384ab1906c68852636b6de493846e13e5a0",
+ "reference": "ee41d384ab1906c68852636b6de493846e13e5a0",
+ "shasum": ""
+ },
+ "require": {
+ "nikic/php-parser": "^5.0",
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "4.0-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 for calculating the complexity of PHP code units",
+ "homepage": "https://github.com/sebastianbergmann/complexity",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/complexity/issues",
+ "security": "https://github.com/sebastianbergmann/complexity/security/policy",
+ "source": "https://github.com/sebastianbergmann/complexity/tree/4.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:49:50+00:00"
+ },
+ {
+ "name": "sebastian/diff",
+ "version": "6.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/diff.git",
+ "reference": "b4ccd857127db5d41a5b676f24b51371d76d8544"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/b4ccd857127db5d41a5b676f24b51371d76d8544",
+ "reference": "b4ccd857127db5d41a5b676f24b51371d76d8544",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0",
+ "symfony/process": "^4.2 || ^5"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "6.0-dev"
+ }
+ },
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de"
+ },
+ {
+ "name": "Kore Nordmann",
+ "email": "mail@kore-nordmann.de"
+ }
+ ],
+ "description": "Diff implementation",
+ "homepage": "https://github.com/sebastianbergmann/diff",
+ "keywords": [
+ "diff",
+ "udiff",
+ "unidiff",
+ "unified diff"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/diff/issues",
+ "security": "https://github.com/sebastianbergmann/diff/security/policy",
+ "source": "https://github.com/sebastianbergmann/diff/tree/6.0.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:53:05+00:00"
+ },
+ {
+ "name": "sebastian/environment",
+ "version": "7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/environment.git",
+ "reference": "855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5",
+ "reference": "855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "suggest": {
+ "ext-posix": "*"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "7.2-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": "https://github.com/sebastianbergmann/environment",
+ "keywords": [
+ "Xdebug",
+ "environment",
+ "hhvm"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/environment/issues",
+ "security": "https://github.com/sebastianbergmann/environment/security/policy",
+ "source": "https://github.com/sebastianbergmann/environment/tree/7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:54:44+00:00"
+ },
+ {
+ "name": "sebastian/exporter",
+ "version": "6.3.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/exporter.git",
+ "reference": "3473f61172093b2da7de1fb5782e1f24cc036dc3"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/3473f61172093b2da7de1fb5782e1f24cc036dc3",
+ "reference": "3473f61172093b2da7de1fb5782e1f24cc036dc3",
+ "shasum": ""
+ },
+ "require": {
+ "ext-mbstring": "*",
+ "php": ">=8.2",
+ "sebastian/recursion-context": "^6.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.3"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "6.1-dev"
+ }
+ },
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de"
+ },
+ {
+ "name": "Jeff Welch",
+ "email": "whatthejeff@gmail.com"
+ },
+ {
+ "name": "Volker Dusch",
+ "email": "github@wallbash.com"
+ },
+ {
+ "name": "Adam Harvey",
+ "email": "aharvey@php.net"
+ },
+ {
+ "name": "Bernhard Schussek",
+ "email": "bschussek@gmail.com"
+ }
+ ],
+ "description": "Provides the functionality to export PHP variables for visualization",
+ "homepage": "https://www.github.com/sebastianbergmann/exporter",
+ "keywords": [
+ "export",
+ "exporter"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/exporter/issues",
+ "security": "https://github.com/sebastianbergmann/exporter/security/policy",
+ "source": "https://github.com/sebastianbergmann/exporter/tree/6.3.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-12-05T09:17:50+00:00"
+ },
+ {
+ "name": "sebastian/global-state",
+ "version": "7.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/global-state.git",
+ "reference": "3be331570a721f9a4b5917f4209773de17f747d7"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/3be331570a721f9a4b5917f4209773de17f747d7",
+ "reference": "3be331570a721f9a4b5917f4209773de17f747d7",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "sebastian/object-reflector": "^4.0",
+ "sebastian/recursion-context": "^6.0"
+ },
+ "require-dev": {
+ "ext-dom": "*",
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "7.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": "https://www.github.com/sebastianbergmann/global-state",
+ "keywords": [
+ "global state"
+ ],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/global-state/issues",
+ "security": "https://github.com/sebastianbergmann/global-state/security/policy",
+ "source": "https://github.com/sebastianbergmann/global-state/tree/7.0.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:57:36+00:00"
+ },
+ {
+ "name": "sebastian/lines-of-code",
+ "version": "3.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/lines-of-code.git",
+ "reference": "d36ad0d782e5756913e42ad87cb2890f4ffe467a"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/d36ad0d782e5756913e42ad87cb2890f4ffe467a",
+ "reference": "d36ad0d782e5756913e42ad87cb2890f4ffe467a",
+ "shasum": ""
+ },
+ "require": {
+ "nikic/php-parser": "^5.0",
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.0-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 for counting the lines of code in PHP source code",
+ "homepage": "https://github.com/sebastianbergmann/lines-of-code",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/lines-of-code/issues",
+ "security": "https://github.com/sebastianbergmann/lines-of-code/security/policy",
+ "source": "https://github.com/sebastianbergmann/lines-of-code/tree/3.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T04:58:38+00:00"
+ },
+ {
+ "name": "sebastian/object-enumerator",
+ "version": "6.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/object-enumerator.git",
+ "reference": "f5b498e631a74204185071eb41f33f38d64608aa"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/f5b498e631a74204185071eb41f33f38d64608aa",
+ "reference": "f5b498e631a74204185071eb41f33f38d64608aa",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "sebastian/object-reflector": "^4.0",
+ "sebastian/recursion-context": "^6.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "6.0-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/",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/object-enumerator/issues",
+ "security": "https://github.com/sebastianbergmann/object-enumerator/security/policy",
+ "source": "https://github.com/sebastianbergmann/object-enumerator/tree/6.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:00:13+00:00"
+ },
+ {
+ "name": "sebastian/object-reflector",
+ "version": "4.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/object-reflector.git",
+ "reference": "6e1a43b411b2ad34146dee7524cb13a068bb35f9"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/6e1a43b411b2ad34146dee7524cb13a068bb35f9",
+ "reference": "6e1a43b411b2ad34146dee7524cb13a068bb35f9",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "4.0-dev"
+ }
+ },
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de"
+ }
+ ],
+ "description": "Allows reflection of object attributes, including inherited and non-public ones",
+ "homepage": "https://github.com/sebastianbergmann/object-reflector/",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/object-reflector/issues",
+ "security": "https://github.com/sebastianbergmann/object-reflector/security/policy",
+ "source": "https://github.com/sebastianbergmann/object-reflector/tree/4.0.1"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:01:32+00:00"
+ },
+ {
+ "name": "sebastian/recursion-context",
+ "version": "6.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/recursion-context.git",
+ "reference": "694d156164372abbd149a4b85ccda2e4670c0e16"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/694d156164372abbd149a4b85ccda2e4670c0e16",
+ "reference": "694d156164372abbd149a4b85ccda2e4670c0e16",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "6.0-dev"
+ }
+ },
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Sebastian Bergmann",
+ "email": "sebastian@phpunit.de"
+ },
+ {
+ "name": "Jeff Welch",
+ "email": "whatthejeff@gmail.com"
+ },
+ {
+ "name": "Adam Harvey",
+ "email": "aharvey@php.net"
+ }
+ ],
+ "description": "Provides functionality to recursively process PHP variables",
+ "homepage": "https://github.com/sebastianbergmann/recursion-context",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/recursion-context/issues",
+ "security": "https://github.com/sebastianbergmann/recursion-context/security/policy",
+ "source": "https://github.com/sebastianbergmann/recursion-context/tree/6.0.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-07-03T05:10:34+00:00"
+ },
+ {
+ "name": "sebastian/type",
+ "version": "5.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/type.git",
+ "reference": "461b9c5da241511a2a0e8f240814fb23ce5c0aac"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/461b9c5da241511a2a0e8f240814fb23ce5c0aac",
+ "reference": "461b9c5da241511a2a0e8f240814fb23ce5c0aac",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^11.3"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "5.1-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": "Collection of value objects that represent the types of the PHP type system",
+ "homepage": "https://github.com/sebastianbergmann/type",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/type/issues",
+ "security": "https://github.com/sebastianbergmann/type/security/policy",
+ "source": "https://github.com/sebastianbergmann/type/tree/5.1.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-09-17T13:12:04+00:00"
+ },
+ {
+ "name": "sebastian/version",
+ "version": "5.0.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/sebastianbergmann/version.git",
+ "reference": "c687e3387b99f5b03b6caa64c74b63e2936ff874"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c687e3387b99f5b03b6caa64c74b63e2936ff874",
+ "reference": "c687e3387b99f5b03b6caa64c74b63e2936ff874",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "5.0-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",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/version/issues",
+ "security": "https://github.com/sebastianbergmann/version/security/policy",
+ "source": "https://github.com/sebastianbergmann/version/tree/5.0.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sebastianbergmann",
+ "type": "github"
+ }
+ ],
+ "time": "2024-10-09T05:16:32+00:00"
+ },
+ {
+ "name": "squizlabs/php_codesniffer",
+ "version": "3.11.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git",
+ "reference": "19473c30efe4f7b3cd42522d0b2e6e7f243c6f87"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/19473c30efe4f7b3cd42522d0b2e6e7f243c6f87",
+ "reference": "19473c30efe4f7b3cd42522d0b2e6e7f243c6f87",
+ "shasum": ""
+ },
+ "require": {
+ "ext-simplexml": "*",
+ "ext-tokenizer": "*",
+ "ext-xmlwriter": "*",
+ "php": ">=5.4.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.3.4"
+ },
+ "bin": [
+ "bin/phpcbf",
+ "bin/phpcs"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "3.x-dev"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Greg Sherwood",
+ "role": "Former lead"
+ },
+ {
+ "name": "Juliette Reinders Folmer",
+ "role": "Current lead"
+ },
+ {
+ "name": "Contributors",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors"
+ }
+ ],
+ "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
+ "keywords": [
+ "phpcs",
+ "standards",
+ "static analysis"
+ ],
+ "support": {
+ "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues",
+ "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy",
+ "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
+ "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2024-11-16T12:02:36+00:00"
+ },
+ {
+ "name": "staabm/side-effects-detector",
+ "version": "1.0.5",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/staabm/side-effects-detector.git",
+ "reference": "d8334211a140ce329c13726d4a715adbddd0a163"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/staabm/side-effects-detector/zipball/d8334211a140ce329c13726d4a715adbddd0a163",
+ "reference": "d8334211a140ce329c13726d4a715adbddd0a163",
+ "shasum": ""
+ },
+ "require": {
+ "ext-tokenizer": "*",
+ "php": "^7.4 || ^8.0"
+ },
+ "require-dev": {
+ "phpstan/extension-installer": "^1.4.3",
+ "phpstan/phpstan": "^1.12.6",
+ "phpunit/phpunit": "^9.6.21",
+ "symfony/var-dumper": "^5.4.43",
+ "tomasvotruba/type-coverage": "1.0.0",
+ "tomasvotruba/unused-public": "1.0.0"
+ },
+ "type": "library",
+ "autoload": {
+ "classmap": [
+ "lib/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "description": "A static analysis tool to detect side effects in PHP code",
+ "keywords": [
+ "static analysis"
+ ],
+ "support": {
+ "issues": "https://github.com/staabm/side-effects-detector/issues",
+ "source": "https://github.com/staabm/side-effects-detector/tree/1.0.5"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/staabm",
+ "type": "github"
+ }
+ ],
+ "time": "2024-10-20T05:08:20+00:00"
+ },
+ {
+ "name": "symfony/config",
+ "version": "v7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/config.git",
+ "reference": "bcd3c4adf0144dee5011bb35454728c38adec055"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/config/zipball/bcd3c4adf0144dee5011bb35454728c38adec055",
+ "reference": "bcd3c4adf0144dee5011bb35454728c38adec055",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "symfony/deprecation-contracts": "^2.5|^3",
+ "symfony/filesystem": "^7.1",
+ "symfony/polyfill-ctype": "~1.8"
+ },
+ "conflict": {
+ "symfony/finder": "<6.4",
+ "symfony/service-contracts": "<2.5"
+ },
+ "require-dev": {
+ "symfony/event-dispatcher": "^6.4|^7.0",
+ "symfony/finder": "^6.4|^7.0",
+ "symfony/messenger": "^6.4|^7.0",
+ "symfony/service-contracts": "^2.5|^3",
+ "symfony/yaml": "^6.4|^7.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Symfony\\Component\\Config\\": ""
+ },
+ "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": "Helps you find, load, combine, autofill and validate configuration values of any kind",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/config/tree/v7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-11-04T11:36:24+00:00"
+ },
+ {
+ "name": "symfony/dependency-injection",
+ "version": "v7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/dependency-injection.git",
+ "reference": "a475747af1a1c98272a5471abc35f3da81197c5d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/a475747af1a1c98272a5471abc35f3da81197c5d",
+ "reference": "a475747af1a1c98272a5471abc35f3da81197c5d",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "psr/container": "^1.1|^2.0",
+ "symfony/deprecation-contracts": "^2.5|^3",
+ "symfony/service-contracts": "^3.5",
+ "symfony/var-exporter": "^6.4|^7.0"
+ },
+ "conflict": {
+ "ext-psr": "<1.1|>=2",
+ "symfony/config": "<6.4",
+ "symfony/finder": "<6.4",
+ "symfony/yaml": "<6.4"
+ },
+ "provide": {
+ "psr/container-implementation": "1.1|2.0",
+ "symfony/service-implementation": "1.1|2.0|3.0"
+ },
+ "require-dev": {
+ "symfony/config": "^6.4|^7.0",
+ "symfony/expression-language": "^6.4|^7.0",
+ "symfony/yaml": "^6.4|^7.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Symfony\\Component\\DependencyInjection\\": ""
+ },
+ "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": "Allows you to standardize and centralize the way objects are constructed in your application",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/dependency-injection/tree/v7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-11-25T15:45:00+00:00"
+ },
+ {
+ "name": "symfony/deprecation-contracts",
+ "version": "v3.5.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/deprecation-contracts.git",
+ "reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6",
+ "reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.5-dev"
+ },
+ "thanks": {
+ "name": "symfony/contracts",
+ "url": "https://github.com/symfony/contracts"
+ }
+ },
+ "autoload": {
+ "files": [
+ "function.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": "A generic function and convention to trigger deprecation notices",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.1"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-09-25T14:20:29+00:00"
+ },
+ {
+ "name": "symfony/filesystem",
+ "version": "v7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/filesystem.git",
+ "reference": "b8dce482de9d7c9fe2891155035a7248ab5c7fdb"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/filesystem/zipball/b8dce482de9d7c9fe2891155035a7248ab5c7fdb",
+ "reference": "b8dce482de9d7c9fe2891155035a7248ab5c7fdb",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "symfony/polyfill-ctype": "~1.8",
+ "symfony/polyfill-mbstring": "~1.8"
+ },
+ "require-dev": {
+ "symfony/process": "^6.4|^7.0"
+ },
+ "type": "library",
+ "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": "Provides basic utilities for the filesystem",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/filesystem/tree/v7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-10-25T15:15:23+00:00"
+ },
+ {
+ "name": "symfony/polyfill-ctype",
+ "version": "v1.31.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/polyfill-ctype.git",
+ "reference": "a3cc8b044a6ea513310cbd48ef7333b384945638"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/a3cc8b044a6ea513310cbd48ef7333b384945638",
+ "reference": "a3cc8b044a6ea513310cbd48ef7333b384945638",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.2"
+ },
+ "provide": {
+ "ext-ctype": "*"
+ },
+ "suggest": {
+ "ext-ctype": "For best performance"
+ },
+ "type": "library",
+ "extra": {
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
+ }
+ },
+ "autoload": {
+ "files": [
+ "bootstrap.php"
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Ctype\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Gert de Pagter",
+ "email": "BackEndTea@gmail.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "Symfony polyfill for ctype functions",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "compatibility",
+ "ctype",
+ "polyfill",
+ "portable"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-ctype/tree/v1.31.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-09-09T11:45:10+00:00"
+ },
+ {
+ "name": "symfony/polyfill-mbstring",
+ "version": "v1.31.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/polyfill-mbstring.git",
+ "reference": "85181ba99b2345b0ef10ce42ecac37612d9fd341"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/85181ba99b2345b0ef10ce42ecac37612d9fd341",
+ "reference": "85181ba99b2345b0ef10ce42ecac37612d9fd341",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.2"
+ },
+ "provide": {
+ "ext-mbstring": "*"
+ },
+ "suggest": {
+ "ext-mbstring": "For best performance"
+ },
+ "type": "library",
+ "extra": {
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
+ }
+ },
+ "autoload": {
+ "files": [
+ "bootstrap.php"
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Mbstring\\": ""
+ }
+ },
+ "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"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.31.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-09-09T11:45:10+00:00"
+ },
+ {
+ "name": "symfony/service-contracts",
+ "version": "v3.5.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/service-contracts.git",
+ "reference": "e53260aabf78fb3d63f8d79d69ece59f80d5eda0"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/service-contracts/zipball/e53260aabf78fb3d63f8d79d69ece59f80d5eda0",
+ "reference": "e53260aabf78fb3d63f8d79d69ece59f80d5eda0",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1",
+ "psr/container": "^1.1|^2.0",
+ "symfony/deprecation-contracts": "^2.5|^3"
+ },
+ "conflict": {
+ "ext-psr": "<1.1|>=2"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.5-dev"
+ },
+ "thanks": {
+ "name": "symfony/contracts",
+ "url": "https://github.com/symfony/contracts"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Symfony\\Contracts\\Service\\": ""
+ },
+ "exclude-from-classmap": [
+ "/Test/"
+ ]
+ },
+ "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": "Generic abstractions related to writing services",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "abstractions",
+ "contracts",
+ "decoupling",
+ "interfaces",
+ "interoperability",
+ "standards"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/service-contracts/tree/v3.5.1"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-09-25T14:20:29+00:00"
+ },
+ {
+ "name": "symfony/var-dumper",
+ "version": "v7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/var-dumper.git",
+ "reference": "c6a22929407dec8765d6e2b6ff85b800b245879c"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/var-dumper/zipball/c6a22929407dec8765d6e2b6ff85b800b245879c",
+ "reference": "c6a22929407dec8765d6e2b6ff85b800b245879c",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2",
+ "symfony/polyfill-mbstring": "~1.0"
+ },
+ "conflict": {
+ "symfony/console": "<6.4"
+ },
+ "require-dev": {
+ "ext-iconv": "*",
+ "symfony/console": "^6.4|^7.0",
+ "symfony/http-kernel": "^6.4|^7.0",
+ "symfony/process": "^6.4|^7.0",
+ "symfony/uid": "^6.4|^7.0",
+ "twig/twig": "^3.12"
+ },
+ "bin": [
+ "Resources/bin/var-dump-server"
+ ],
+ "type": "library",
+ "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": "Provides mechanisms for walking through any arbitrary PHP variable",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "debug",
+ "dump"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/var-dumper/tree/v7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-11-08T15:48:14+00:00"
+ },
+ {
+ "name": "symfony/var-exporter",
+ "version": "v7.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/var-exporter.git",
+ "reference": "1a6a89f95a46af0f142874c9d650a6358d13070d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/var-exporter/zipball/1a6a89f95a46af0f142874c9d650a6358d13070d",
+ "reference": "1a6a89f95a46af0f142874c9d650a6358d13070d",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.2"
+ },
+ "require-dev": {
+ "symfony/property-access": "^6.4|^7.0",
+ "symfony/serializer": "^6.4|^7.0",
+ "symfony/var-dumper": "^6.4|^7.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Symfony\\Component\\VarExporter\\": ""
+ },
+ "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": "Allows exporting any serializable PHP data structure to plain PHP code",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "clone",
+ "construct",
+ "export",
+ "hydrate",
+ "instantiate",
+ "lazy-loading",
+ "proxy",
+ "serialize"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/var-exporter/tree/v7.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-10-18T07:58:17+00:00"
+ },
+ {
+ "name": "theseer/tokenizer",
+ "version": "1.2.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/theseer/tokenizer.git",
+ "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
+ "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
+ "shasum": ""
+ },
+ "require": {
+ "ext-dom": "*",
+ "ext-tokenizer": "*",
+ "ext-xmlwriter": "*",
+ "php": "^7.2 || ^8.0"
+ },
+ "type": "library",
+ "autoload": {
+ "classmap": [
+ "src/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Arne Blankerts",
+ "email": "arne@blankerts.de",
+ "role": "Developer"
+ }
+ ],
+ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats",
+ "support": {
+ "issues": "https://github.com/theseer/tokenizer/issues",
+ "source": "https://github.com/theseer/tokenizer/tree/1.2.3"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/theseer",
+ "type": "github"
+ }
+ ],
+ "time": "2024-03-03T12:36:25+00:00"
+ }
+ ],
+ "aliases": [],
+ "minimum-stability": "dev",
+ "stability-flags": {
+ "roave/security-advisories": 20
+ },
+ "prefer-stable": true,
+ "prefer-lowest": false,
+ "platform": {
+ "php": "^8.3",
+ "ext-curl": "*",
+ "ext-json": "*"
+ },
+ "platform-dev": {
+ "ext-simplexml": "*"
+ },
+ "plugin-api-version": "2.3.0"
+}
diff --git a/samples/OrderCreate.php b/samples/OrderCreate.php
index a616041..d70ddf2 100644
--- a/samples/OrderCreate.php
+++ b/samples/OrderCreate.php
@@ -15,7 +15,7 @@
$request->setDescription('Order ABC0123456789');
$request->setAmount((float)($_REQUEST['amount'] ?? 5.3));
$request->setCurrency('EUR');
-$request->setExpire(date('Y-m-d H:i:s', strtotime('+1 DAY')));
+$request->setExpire(date('c', time() + 60));
$request->setReturnurl($_REQUEST['returnUrl'] ?? 'https://yourdomain/finish.php');
$request->setExchangeUrl($_REQUEST['exchangeUrl'] ?? 'https://yourdomain/exchange.php');
$request->setPaymentMethodId((int)($_REQUEST['paymentMethodId'] ?? 10));
@@ -92,8 +92,7 @@
->setExtra1('ex1')
->setExtra2('ex2')
->setExtra3('ex3')
- ->setDomainId('WU-1234-1234')
-);
+ ->setDomainId('WU-1234-1234'));
$request->setNotification('EMAIL', 'youremail@yourdomain.ext');
$request->setTransferData([['yourField' => 'yourData'], ['tracker' => 'trackerinfo']]);
diff --git a/samples/OrderStatus.php b/samples/OrderStatus.php
index c0257e2..e608530 100644
--- a/samples/OrderStatus.php
+++ b/samples/OrderStatus.php
@@ -28,7 +28,7 @@
}
echo '';
-echo 'Success, values:' . PHP_EOL.PHP_EOL;
+echo 'Success, values:' . PHP_EOL . PHP_EOL;
echo 'type: ' . $payOrder->getType() . PHP_EOL;
echo 'isPending: ' . ($payOrder->isPending() ? 'YES' : 'no') . PHP_EOL;
@@ -41,14 +41,15 @@
echo 'isRefunded: ' . ($payOrder->isRefunded() ? 'YES' : 'no') . PHP_EOL;
echo 'isPartiallyRefunded: ' . ($payOrder->isRefundedPartial() ? 'YES' : 'no') . PHP_EOL . PHP_EOL;
echo 'isFastcheckout: ' . ($payOrder->isFastcheckout() ? 'YES' : 'no') . PHP_EOL;
+echo 'getAmountRefunded: ' . ($payOrder->getAmountRefunded()) . PHP_EOL . PHP_EOL;
echo 'getStatusCode: ' . $payOrder->getStatusCode() . PHP_EOL;
echo 'getStatusName: ' . $payOrder->getStatusName() . PHP_EOL;
echo 'getId: ' . $payOrder->getId() . PHP_EOL;
echo 'getOrderId: ' . $payOrder->getOrderId() . PHP_EOL;
echo 'getDescription: ' . $payOrder->getDescription() . PHP_EOL;
echo 'getReference: ' . $payOrder->getReference() . PHP_EOL;
-echo 'getAmount: ' . $payOrder->getAmount(). PHP_EOL;
+echo 'getAmount: ' . $payOrder->getAmount() . PHP_EOL;
echo 'getCurrency: ' . $payOrder->getCurrency() . PHP_EOL;
echo 'paymentMethod: ' . $payOrder->getPaymentMethod() . PHP_EOL;
-print_r($payOrder->getFastCheckoutData());
\ No newline at end of file
+print_r($payOrder->getFastCheckoutData());
diff --git a/samples/ServiceGetConfig.php b/samples/ServiceGetConfig.php
index 4b5d75e..b24da48 100644
--- a/samples/ServiceGetConfig.php
+++ b/samples/ServiceGetConfig.php
@@ -36,7 +36,7 @@
$terminals = $config->getTerminals();
print_r($terminals);
-$tguList = $config->getTguList();
+$tguList = $config->getCores();
print_r($tguList);
$paymentMethods = $config->getPaymentMethods();
@@ -53,4 +53,4 @@
foreach ($config->getCheckoutOptions() as $checkoutOption) {
echo '=> TAG: ' . $checkoutOption->getTag() . PHP_EOL;
-}
\ No newline at end of file
+}
diff --git a/samples/TransactionStatus.php b/samples/TransactionStatus.php
index 3563465..a28425e 100644
--- a/samples/TransactionStatus.php
+++ b/samples/TransactionStatus.php
@@ -27,7 +27,7 @@
}
echo '';
-echo 'Success, values:' . PHP_EOL.PHP_EOL;
+echo 'Success, values:' . PHP_EOL . PHP_EOL;
echo 'isPending: ' . ($payOrder->isPending() ? 'YES' : 'no') . PHP_EOL;
echo 'isPaid: ' . ($payOrder->isPaid() ? 'YES' : 'no') . PHP_EOL;
@@ -38,6 +38,8 @@
echo 'isPartialPayment: ' . ($payOrder->isPartialPayment() ? 'YES' : 'no') . PHP_EOL;
echo 'isRefunded: ' . ($payOrder->isRefunded() ? 'YES' : 'no') . PHP_EOL;
echo 'isPartiallyRefunded: ' . ($payOrder->isRefundedPartial() ? 'YES' : 'no') . PHP_EOL . PHP_EOL;
+echo 'getAmount: ' . ($payOrder->getAmount()) . PHP_EOL;
+echo 'getAmountRefunded: ' . ($payOrder->getAmountRefunded()) . PHP_EOL . PHP_EOL;
echo 'getStatusCode: ' . $payOrder->getStatusCode() . PHP_EOL;
echo 'getStatusName: ' . $payOrder->getStatusName() . PHP_EOL;
echo 'getId: ' . $payOrder->getId() . PHP_EOL;
diff --git a/src/Api/Api.php b/src/Api/Api.php
index dfe43cc..e1daa04 100644
--- a/src/Api/Api.php
+++ b/src/Api/Api.php
@@ -4,7 +4,6 @@
namespace PayNL\Sdk\Api;
-use PayNL\GuzzleHttp\Client as GuzzleClient;
use PayNL\Sdk\{
AuthAdapter\AdapterInterface as AuthAdapterInterface,
Common\DebugAwareInterface,
@@ -16,6 +15,7 @@
Request\RequestInterface,
Response\ResponseInterface
};
+use GuzzleHttp\Client;
/**
* Class Api
@@ -28,7 +28,7 @@ class Api implements OptionsAwareInterface, DebugAwareInterface
use OptionsAwareTrait;
/**
- * @var GuzzleClient
+ * @var Client
*/
protected $client;
@@ -41,10 +41,10 @@ class Api implements OptionsAwareInterface, DebugAwareInterface
* Api constructor.
*
* @param AuthAdapterInterface $authenticationAdapter
- * @param GuzzleClient $client
+ * @param Client $client
* @param array $options
*/
- public function __construct(AuthAdapterInterface $authenticationAdapter, GuzzleClient $client, array $options = [])
+ public function __construct(AuthAdapterInterface $authenticationAdapter, Client $client, array $options = [])
{
$this->setAuthAdapter($authenticationAdapter)
->setClient($client)
@@ -53,20 +53,20 @@ public function __construct(AuthAdapterInterface $authenticationAdapter, GuzzleC
}
/**
- * @param GuzzleClient $client
+ * @param Client $client
*
* @return Api
*/
- protected function setClient(GuzzleClient $client): self
+ protected function setClient(Client $client): self
{
$this->client = $client;
return $this;
}
/**
- * @return GuzzleClient
+ * @return Client
*/
- public function getClient(): GuzzleClient
+ public function getClient(): Client
{
return $this->client;
}
diff --git a/src/Api/Factory.php b/src/Api/Factory.php
index 1beac0f..052650c 100644
--- a/src/Api/Factory.php
+++ b/src/Api/Factory.php
@@ -4,8 +4,8 @@
namespace PayNL\Sdk\Api;
+use GuzzleHttp\Client;
use Psr\Container\ContainerInterface;
-use PayNL\GuzzleHttp\Client as GuzzleClient;
use PayNL\Sdk\{
AuthAdapter\AdapterInterface as AuthAdapterInterface,
Config\Config,
@@ -23,10 +23,10 @@
class Factory implements FactoryInterface
{
/**
- * @inheritDoc
- *
- * @throws ServiceNotFoundException
- * @throws InvalidArgumentException
+ * @param ContainerInterface $container
+ * @param string $requestedName
+ * @param array|null $options
+ * @return Api|Service
*/
public function __invoke(ContainerInterface $container, string $requestedName, array $options = null)
{
@@ -59,7 +59,7 @@ public function __invoke(ContainerInterface $container, string $requestedName, a
$version = $options->get('api')->get('version');
$pathVersion = empty($version) ? '' : '/v' . $version;
- $guzzleClient = new GuzzleClient([
+ $guzzleClient = new Client([
'base_uri' => $filteredApiUrl . "{$pathVersion}/",
]);
diff --git a/src/Config/Config.php b/src/Config/Config.php
index a334f0f..d9573e0 100644
--- a/src/Config/Config.php
+++ b/src/Config/Config.php
@@ -8,779 +8,405 @@
use Iterator;
use ArrayAccess;
-if (PHP_VERSION_ID >= 80000) {
+/**
+ * Class Config
+ *
+ * @package PayNL\Sdk
+ *
+ * @SuppressWarnings(PHPMD.TooManyPublicMethods)
+ */
+class Config implements Countable, Iterator, ArrayAccess
+{
+ public const TGU1 = 'https://connect.pay.nl';
+ public const TGU2 = 'https://connect.payments.nl';
+ public const TGU3 = 'https://connect.achterelkebetaling.nl';
+
+ protected array $data = [];
+ private static Config $configObject;
+
/**
- * Class Config
- *
- * @package PayNL\Sdk
+ * Config constructor.
*
- * @SuppressWarnings(PHPMD.TooManyPublicMethods)
- */
- class Config implements Countable, Iterator, ArrayAccess
- {
- const TGU1 = 'https://connect.pay.nl';
- const TGU2 = 'https://connect.payments.nl';
- const TGU3 = 'https://connect.achterelkebetaling.nl';
-
- protected array $data = [];
- private static Config $configObject;
-
- /**
- * Config constructor.
- *
- * @param array $data
- */
- public function __construct(array $data = [])
- {
- foreach ($data as $key => $value) {
- if (true === is_array($value)) {
- $value = new self($value);
- }
- $this->data[$key] = $value;
- }
- }
-
- /**
- * @return void
- */
- public function __clone()
- {
- $data = [];
-
- foreach ($this->data as $key => $value) {
- if ($value instanceof self) {
- $value = clone $value;
- }
- $data[$key] = $value;
- }
-
- $this->data = $data;
- }
-
- /**
- * @param $key
- * @param null $default
- */
- public function get($key, $default = null)
- {
- return $this->data[$key] ?? $default;
- }
-
- /**
- * @param string|int $key
- */
- public function __get($key)
- {
- return $this->get($key);
- }
-
- /**
- * @param string|int $key
- * @param $value
- *
- * @return void
- */
- public function set($key, $value): void
- {
+ * @param array $data
+ */
+ public function __construct(array $data = [])
+ {
+ foreach ($data as $key => $value) {
if (true === is_array($value)) {
$value = new self($value);
}
-
$this->data[$key] = $value;
}
+ }
- /**
- * @param string|int $key
- * @param $value
- *
- * @return void
- */
- public function __set($key, $value): void
- {
- $this->set($key, $value);
- }
+ /**
+ * @return void
+ */
+ public function __clone()
+ {
+ $data = [];
- /**
- * @param string|int $key
- *
- * @return void
- */
- public function remove($key): void
- {
- if (true === $this->has($key)) {
- unset($this->data[$key]);
+ foreach ($this->data as $key => $value) {
+ if ($value instanceof self) {
+ $value = clone $value;
}
+ $data[$key] = $value;
}
- /**
- * @param string|int $key
- *
- * @return void
- */
- public function __unset($key): void
- {
- $this->remove($key);
- }
-
- /**
- * @param string|int $key
- *
- * @return bool
- */
- public function has($key): bool
- {
- return isset($this->data[$key]);
- }
-
- /**
- * @param string|int $key
- *
- * @return bool
- */
- public function __isset($key): bool
- {
- return $this->has($key);
- }
-
- /**
- * @return array
- */
- public function toArray(): array
- {
- $array = [];
- $data = $this->data;
-
- foreach ($data as $key => $value) {
- if ($value instanceof self) {
- $value = $value->toArray();
- }
- $array[$key] = $value;
- }
-
- return $array;
- }
-
- /**
- * @inheritDoc
- */
- public function current(): mixed
- {
- return current($this->data);
- }
+ $this->data = $data;
+ }
+ /**
+ * @param mixed $key
+ * @param mixed $default
+ * @return mixed|null
+ */
+ public function get(mixed $key, mixed $default = null)
+ {
+ return $this->data[$key] ?? $default;
+ }
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function next(): void
- {
- next($this->data);
- }
+ /**
+ * @param string|integer $key
+ * @return mixed|null
+ */
+ public function __get(string|int $key)
+ {
+ return $this->get($key);
+ }
- /**
- * @inheritDoc
- *
- * @return
- */
- public function key(): mixed
- {
- return key($this->data);
+ /**
+ * @param mixed $key
+ * @param mixed $value
+ * @return void
+ */
+ public function set(mixed $key, mixed $value): void
+ {
+ if (true === is_array($value)) {
+ $value = new self($value);
}
- /**
- * @inheritDoc
- *
- * @return bool
- */
- public function valid(): bool
- {
- return null !== $this->key();
- }
+ $this->data[$key] = $value;
+ }
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function rewind(): void
- {
- reset($this->data);
- }
+ /**
+ * @param mixed $key
+ * @param mixed $value
+ * @return void
+ */
+ public function __set(mixed $key, mixed $value): void
+ {
+ $this->set($key, $value);
+ }
- /**
- * @inheritDoc
- *
- * @return bool
- */
- public function offsetExists($offset): bool
- {
- return $this->has($offset);
+ /**
+ * @param string|integer $key
+ *
+ * @return void
+ */
+ public function remove(string|int $key): void
+ {
+ if (true === $this->has($key)) {
+ unset($this->data[$key]);
}
+ }
- /**
- * @inheritDoc
- *
- * @return
- */
- public function offsetGet($offset): mixed
- {
- return $this->get($offset);
- }
+ /**
+ * @param string|integer $key
+ *
+ * @return void
+ */
+ public function __unset(string|int $key): void
+ {
+ $this->remove($key);
+ }
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function offsetSet($offset, $value): void
- {
- $this->set($offset, $value);
- }
+ /**
+ * @param string|integer $key
+ *
+ * @return boolean
+ */
+ public function has(string|int $key): bool
+ {
+ return isset($this->data[$key]);
+ }
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function offsetUnset($offset): void
- {
- $this->remove($offset);
- }
+ /**
+ * @param string|integer $key
+ *
+ * @return boolean
+ */
+ public function __isset(string|int $key): bool
+ {
+ return $this->has($key);
+ }
- /**
- * @inheritDoc
- */
- public function count(): int
- {
- return count($this->data);
- }
+ /**
+ * @return array
+ */
+ public function toArray(): array
+ {
+ $array = [];
+ $data = $this->data;
- /**
- * Merge the current config object with the given one
- *
- * @param Config $mergeConfig
- *
- * @return Config
- */
- public function merge(Config $mergeConfig): self
- {
- foreach ($mergeConfig as $key => $value) {
- $currentValue = $this->get($key);
- if ($value instanceof self && $currentValue instanceof self) {
- $value = $currentValue->merge($value);
- }
- if (is_array($value)) {
- foreach ($value as $k => $v) {
- $currentValue[$k] = $v;
- }
- $value = $currentValue;
- }
- $this->set($key, $value);
+ foreach ($data as $key => $value) {
+ if ($value instanceof self) {
+ $value = $value->toArray();
}
- return $this;
+ $array[$key] = $value;
}
- /**
- * @param bool $debug
- * @return $this
- */
- public function setDebug(bool $debug): self
- {
- $this->data['debug'] = $debug;
- return $this;
- }
+ return $array;
+ }
- /**
- * @return bool
- */
- public function getDebug(): bool
- {
- return $this->data['debug'] == 1;
- }
+ /**
+ * @return mixed
+ */
+ public function current(): mixed
+ {
+ return current($this->data);
+ }
- /**
- * @return string
- */
- public function getFailoverUrl(): string
- {
- if (!empty($this->data['failoverUrl'])) {
- return trim($this->data['failoverUrl']);
- }
- return '';
- }
- /**
- * Set destination(core) url
- *
- * @param string $url
- * @return void
- */
- public function setCore(string $url): self
- {
- if (!empty($url)) {
- $this->data['api']['url'] = $url;
- }
- return $this;
- }
+ /**
+ * @inheritDoc
+ *
+ * @return void
+ */
+ public function next(): void
+ {
+ next($this->data);
+ }
- /**
- * Set version of API URL
- *
- * @param integer $version
- * @return $this
- */
- public function setVersion(int $version): self
- {
- $this->data['api']['version'] = $version;
- return $this;
- }
+ /**
+ * @return mixed
+ */
+ public function key(): mixed
+ {
+ return key($this->data);
+ }
- /**
- * @return string
- */
- public function getCore(): string
- {
- return $this->data['api']['url'] ?? '';
- }
+ /**
+ * @inheritDoc
+ * @return boolean
+ */
+ public function valid(): bool
+ {
+ return null !== $this->key();
+ }
- /**
- * @param string $username
- * @return $this
- */
- public function setUsername(string $username): self
- {
- $this->data['authentication']['username'] = $username;
- return $this;
- }
+ /**
+ * @inheritDoc
+ *
+ * @return void
+ */
+ public function rewind(): void
+ {
+ reset($this->data);
+ }
- /**
- * @return string
- */
- public function getUsername()
- {
- return $this->data['authentication']['username'] ?? '';
- }
+ /**
+ * @param mixed $offset
+ * @return boolean
+ */
+ public function offsetExists(mixed $offset): bool
+ {
+ return $this->has($offset);
+ }
- /**
- * @param string $password
- * @return $this
- */
- public function setPassword(string $password): self
- {
- $this->data['authentication']['password'] = $password;
- return $this;
- }
+ /**
+ * @param mixed $offset
+ * @return mixed
+ */
+ public function offsetGet(mixed $offset): mixed
+ {
+ return $this->get($offset);
+ }
- /**
- * @return string
- */
- public function getPassword()
- {
- return $this->data['authentication']['password'] ?? '';
- }
+ /**
+ * @param mixed $offset
+ * @param mixed $value
+ * @return void
+ */
+ public function offsetSet(mixed $offset, mixed $value): void
+ {
+ $this->set($offset, $value);
+ }
- /**
- * Get global config
- *
- * @return Config
- */
- public static function getConfig()
- {
- if (empty(self::$configObject)) {
- self::$configObject = (new Config(require __DIR__ . '/../../config/config.global.php'));
- }
- return self::$configObject;
- }
+ /**
+ * @param mixed $offset
+ * @return void
+ */
+ public function offsetUnset(mixed $offset): void
+ {
+ $this->remove($offset);
+ }
+ /**
+ * @return integer
+ */
+ public function count(): int
+ {
+ return count($this->data);
}
-} else {
+
/**
- * Class Config
+ * Merge the current config object with the given one
*
- * @package PayNL\Sdk
+ * @param Config $mergeConfig
*
- * @SuppressWarnings(PHPMD.TooManyPublicMethods)
- */
- class Config implements Countable, Iterator, ArrayAccess
- {
- const TGU1 = 'https://connect.pay.nl';
- const TGU2 = 'https://connect.payments.nl';
- const TGU3 = 'https://connect.achterelkebetaling.nl';
-
- protected array $data = [];
- private static Config $configObject;
-
- /**
- * Config constructor.
- *
- * @param array $data
- */
- public function __construct(array $data = [])
- {
- foreach ($data as $key => $value) {
- if (true === is_array($value)) {
- $value = new self($value);
- }
- $this->data[$key] = $value;
+ * @return Config
+ */
+ public function merge(Config $mergeConfig): self
+ {
+ foreach ($mergeConfig as $key => $value) {
+ $currentValue = $this->get($key);
+ if ($value instanceof self && $currentValue instanceof self) {
+ $value = $currentValue->merge($value);
}
- }
-
- /**
- * @return void
- */
- public function __clone()
- {
- $data = [];
-
- foreach ($this->data as $key => $value) {
- if ($value instanceof self) {
- $value = clone $value;
+ if (is_array($value)) {
+ foreach ($value as $k => $v) {
+ $currentValue[$k] = $v;
}
- $data[$key] = $value;
- }
-
- $this->data = $data;
- }
-
- /**
- * @param $key
- * @param null $default
- */
- public function get($key, $default = null)
- {
- return $this->data[$key] ?? $default;
- }
-
- /**
- * @param string|int $key
- */
- public function __get($key)
- {
- return $this->get($key);
- }
-
- /**
- * @param string|int $key
- * @param $value
- *
- * @return void
- */
- public function set($key, $value): void
- {
- if (true === is_array($value)) {
- $value = new self($value);
+ $value = $currentValue;
}
-
- $this->data[$key] = $value;
- }
-
- /**
- * @param string|int $key
- * @param $value
- *
- * @return void
- */
- public function __set($key, $value): void
- {
$this->set($key, $value);
}
+ return $this;
+ }
- /**
- * @param string|int $key
- *
- * @return void
- */
- public function remove($key): void
- {
- if (true === $this->has($key)) {
- unset($this->data[$key]);
- }
- }
-
- /**
- * @param string|int $key
- *
- * @return void
- */
- public function __unset($key): void
- {
- $this->remove($key);
- }
-
- /**
- * @param string|int $key
- *
- * @return bool
- */
- public function has($key): bool
- {
- return isset($this->data[$key]);
- }
-
- /**
- * @param string|int $key
- *
- * @return bool
- */
- public function __isset($key): bool
- {
- return $this->has($key);
- }
-
- /**
- * @return array
- */
- public function toArray(): array
- {
- $array = [];
- $data = $this->data;
-
- foreach ($data as $key => $value) {
- if ($value instanceof self) {
- $value = $value->toArray();
- }
- $array[$key] = $value;
- }
-
- return $array;
- }
-
- /**
- * @inheritDoc
- */
- public function current()
- {
- return current($this->data);
- }
-
-
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function next(): void
- {
- next($this->data);
- }
-
- /**
- * @inheritDoc
- *
- * @return
- */
- public function key()
- {
- return key($this->data);
- }
-
- /**
- * @inheritDoc
- *
- * @return bool
- */
- public function valid(): bool
- {
- return null !== $this->key();
- }
-
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function rewind(): void
- {
- reset($this->data);
- }
-
- /**
- * @inheritDoc
- *
- * @return bool
- */
- public function offsetExists($offset): bool
- {
- return $this->has($offset);
- }
-
- /**
- * @inheritDoc
- *
- * @return
- */
- public function offsetGet($offset)
- {
- return $this->get($offset);
- }
-
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function offsetSet($offset, $value): void
- {
- $this->set($offset, $value);
- }
-
- /**
- * @inheritDoc
- *
- * @return void
- */
- public function offsetUnset($offset): void
- {
- $this->remove($offset);
- }
-
- /**
- * @inheritDoc
- */
- public function count(): int
- {
- return count($this->data);
- }
+ /**
+ * @param boolean $debug
+ * @return $this
+ */
+ public function setDebug(bool $debug): self
+ {
+ $this->data['debug'] = $debug;
+ return $this;
+ }
- /**
- * Merge the current config object with the given one
- *
- * @param Config $mergeConfig
- *
- * @return Config
- */
- public function merge(Config $mergeConfig): self
- {
- foreach ($mergeConfig as $key => $value) {
- $currentValue = $this->get($key);
- if ($value instanceof self && $currentValue instanceof self) {
- $value = $currentValue->merge($value);
- }
- if (is_array($value)) {
- foreach ($value as $k => $v) {
- $currentValue[$k] = $v;
- }
- $value = $currentValue;
- }
- $this->set($key, $value);
- }
- return $this;
- }
+ /**
+ * @return boolean
+ */
+ public function getDebug(): bool
+ {
+ return $this->data['debug'] == 1;
+ }
- /**
- * @param bool $debug
- * @return $this
- */
- public function setDebug(bool $debug): self
- {
- $this->data['debug'] = $debug;
- return $this;
- }
+ /**
+ * @param string $url
+ * @return self
+ */
+ public function setupFailoverUrl(string $url): self
+ {
+ $this->data['failoverUrl'] = $url;
+ return $this;
+ }
- /**
- * @return bool
- */
- public function getDebug(): bool
- {
- return $this->data['debug'] == 1;
+ /**
+ * @return string
+ */
+ public function getFailoverUrl(): string
+ {
+ if (!empty($this->data['failoverUrl'])) {
+ return trim($this->data['failoverUrl']);
}
+ return '';
+ }
- /**
- * @return string
- */
- public function getFailoverUrl(): string
- {
- if (!empty($this->data['failoverUrl'])) {
- return trim($this->data['failoverUrl']);
- }
- return '';
+ /**
+ * Set destination(core) url
+ * @param string $url
+ * @return $this
+ */
+ public function setCore(string $url): self
+ {
+ if (!empty($url)) {
+ $this->data['api']['url'] = $url;
}
+ return $this;
+ }
- /**
- * Set destination(core) url
- *
- * @param string $url
- * @return void
- */
- public function setCore(string $url): self
- {
- if (!empty($url)) {
- $this->data['api']['url'] = $url;
- }
- return $this;
- }
+ /**
+ * Set version of API URL
+ *
+ * @param integer $version
+ * @return $this
+ */
+ public function setVersion(int $version): self
+ {
+ $this->data['api']['version'] = $version;
+ return $this;
+ }
- /**
- * Set version of API URL
- *
- * @param integer $version
- * @return $this
- */
- public function setVersion(int $version): self
- {
- $this->data['api']['version'] = $version;
- return $this;
- }
+ /**
+ * @return string
+ */
+ public function getCore(): string
+ {
+ return $this->data['api']['url'] ?? '';
+ }
- /**
- * @return string
- */
- public function getCore(): string
- {
- return $this->data['api']['url'] ?? '';
- }
+ /**
+ * @param string $username
+ * @return $this
+ */
+ public function setUsername(string $username): self
+ {
+ $this->data['authentication']['username'] = $username;
+ return $this;
+ }
- /**
- * @param string $username
- * @return $this
- */
- public function setUsername(string $username): self
- {
- $this->data['authentication']['username'] = $username;
- return $this;
+ /**
+ * @return boolean
+ */
+ public function isEmpty()
+ {
+ if (
+ empty($this->data['authentication']['password']) ||
+ empty($this->data['authentication']['username'])
+ ) {
+ return true;
}
+ return false;
+ }
- /**
- * @return string
- */
- public function getUsername()
- {
- return $this->data['authentication']['username'] ?? '';
- }
+ /**
+ * @return string
+ */
+ public function getUsername()
+ {
+ return $this->data['authentication']['username'] ?? '';
+ }
- /**
- * @param string $password
- * @return $this
- */
- public function setPassword(string $password): self
- {
- $this->data['authentication']['password'] = $password;
- return $this;
- }
+ /**
+ * @param string $password
+ * @return $this
+ */
+ public function setPassword(string $password): self
+ {
+ $this->data['authentication']['password'] = $password;
+ return $this;
+ }
- /**
- * @return string
- */
- public function getPassword()
- {
- return $this->data['authentication']['password'] ?? '';
- }
+ /**
+ * @return string
+ */
+ public function getPassword()
+ {
+ return $this->data['authentication']['password'] ?? '';
+ }
- /**
- * Get global config
- *
- * @return Config
- */
- public static function getConfig()
- {
- if (empty(self::$configObject)) {
- self::$configObject = (new Config(require __DIR__ . '/../../config/config.global.php'));
- }
- return self::$configObject;
+ /**
+ * Get global config
+ *
+ * @return Config
+ */
+ public static function getConfig()
+ {
+ if (empty(self::$configObject)) {
+ self::$configObject = (new Config(require __DIR__ . '/../../config/config.global.php'));
}
-
+ return self::$configObject;
}
}
-
diff --git a/src/Model/Method.php b/src/Model/Method.php
index 2c61031..fd632e5 100644
--- a/src/Model/Method.php
+++ b/src/Model/Method.php
@@ -11,9 +11,10 @@
*/
class Method implements ModelInterface
{
- const IDEAL = 10;
- const PIN = 1927;
- const PAYPAL = 138;
+ public const IDEAL = 10;
+ public const PIN = 1927;
+ public const PAYPAL = 138;
+ public const RETOURPIN = 2351;
/**
* @var int
@@ -61,7 +62,7 @@ class Method implements ModelInterface
protected $maxAmount;
/**
- * @return int
+ * @return integer
*/
public function getId(): int
{
@@ -69,7 +70,7 @@ public function getId(): int
}
/**
- * @param int $id
+ * @param integer $id
* @return $this
*/
public function setId(int $id): self
@@ -79,15 +80,15 @@ public function setId(int $id): self
}
/**
- * @param $language
+ * @param string|null $language
* @return string
*/
- public function getName($language = null): string
+ public function getName(string $language = null): string
{
if (!empty($language) && isset($this->translations['name'][$language])) {
return $this->translations['name'][$language];
}
- return (string)$this->name;
+ return $this->name;
}
/**
@@ -159,7 +160,7 @@ public function setOptions(array $options): self
*/
public function getSettings(): array
{
- return $this->settings;
+ return $this->settings ?? [];
}
/**
@@ -172,16 +173,19 @@ public function setSettings(array $settings): self
return $this;
}
+ /**
+ * @return boolean
+ */
public function hasOptions(): bool
{
return !empty($this->options);
}
/**
- * @param $language
+ * @param string|null $language
* @return string
*/
- public function getDescription($language = null): string
+ public function getDescription(string $language = null): string
{
if (!empty($language)) {
if (isset($this->translations['description'][$language])) {
@@ -203,7 +207,7 @@ public function getDescription($language = null): string
/**
* @param string $description
- * @return void
+ * @return $this
*/
public function setDescription(string $description): self
{
@@ -212,7 +216,7 @@ public function setDescription(string $description): self
}
/**
- * @return int
+ * @return integer
*/
public function getMinAmount(): int
{
@@ -220,7 +224,8 @@ public function getMinAmount(): int
}
/**
- * @param int $minAmount
+ * @param integer $minAmount
+ * @return $this
*/
public function setMinAmount(int $minAmount): self
{
@@ -229,7 +234,7 @@ public function setMinAmount(int $minAmount): self
}
/**
- * @return int
+ * @return integer
*/
public function getMaxAmount(): int
{
@@ -237,7 +242,8 @@ public function getMaxAmount(): int
}
/**
- * @param int $maxAmount
+ * @param integer $maxAmount
+ * @return $this
*/
public function setMaxAmount(int $maxAmount): self
{
diff --git a/src/Model/Order.php b/src/Model/Order.php
index 8bfd5ef..3476dba 100644
--- a/src/Model/Order.php
+++ b/src/Model/Order.php
@@ -4,7 +4,7 @@
namespace PayNL\Sdk\Model;
-use JsonSerializable, DateTime;
+use JsonSerializable;
use PayNL\Sdk\Common\JsonSerializeTrait;
/**
@@ -150,6 +150,16 @@ public function setDeliveryAddress(Address $deliveryAddress): self
return $this;
}
+ /**
+ * Alias for setDeliveryAddress
+ * @param Address $shippingAddress
+ * @return $this
+ */
+ public function setShippingAddress(Address $shippingAddress): self
+ {
+ return $this->setDeliveryAddress($shippingAddress);
+ }
+
/**
* @return Address
*/
diff --git a/src/Model/Pay/PayLoad.php b/src/Model/Pay/PayLoad.php
index 3cd394d..5de2eaf 100644
--- a/src/Model/Pay/PayLoad.php
+++ b/src/Model/Pay/PayLoad.php
@@ -64,7 +64,7 @@ public function getReference()
{
return $this->reference;
}
-
+
/**
* @return array
*/
@@ -74,7 +74,7 @@ public function getFullPayLoad(): array
}
/**
- * @return int
+ * @return integer
*/
public function getInternalStateId(): int
{
@@ -100,13 +100,13 @@ public function getPayOrderId(): string
/**
* @return string
*/
- public function nce(): string
+ public function nce(): string
{
return $this->reference;
}
/**
- * @return int
+ * @return integer
*/
public function getAmount(): int
{
@@ -138,11 +138,18 @@ public function getAmountAuth(): float
}
/**
- * @return int
+ * @return integer
*/
public function getPaymentProfile(): int
{
return $this->paymentProfile;
}
-}
\ No newline at end of file
+ /**
+ * @return array
+ */
+ public function getCheckoutData(): array
+ {
+ return $this->checkoutData;
+ }
+}
diff --git a/src/Model/Pay/PayOrder.php b/src/Model/Pay/PayOrder.php
index 0f5c839..b3ca0cc 100644
--- a/src/Model/Pay/PayOrder.php
+++ b/src/Model/Pay/PayOrder.php
@@ -4,6 +4,7 @@
namespace PayNL\Sdk\Model\Pay;
+use Exception;
use PayNL\Sdk\Model\ModelInterface;
use PayNL\Sdk\Model\Amount;
@@ -14,7 +15,6 @@
*/
class PayOrder implements ModelInterface
{
-
/**
* @var string
*/
@@ -130,15 +130,20 @@ class PayOrder implements ModelInterface
*/
protected $completedAt;
+ /**
+ * @var Amount
+ */
+ protected $amountRefunded;
+
/**
* @var array
*/
protected $links;
/**
- * @param $payload
+ * @param array $payload
*/
- public function __construct($payload = null)
+ public function __construct(array $payload = null)
{
if (!empty($payload['object'])) {
foreach ($payload['object'] as $_key => $_val) {
@@ -153,6 +158,27 @@ public function __construct($payload = null)
}
}
+ /**
+ * @return mixed
+ */
+ public function getAmountRefunded()
+ {
+ if (!empty($this->amountRefunded) && $this->amountRefunded instanceof Amount) {
+ return $this->amountRefunded->getValue() / 100;
+ }
+ return null;
+ }
+
+ /**
+ * @param Amount $amountRefunded
+ * @return $this
+ */
+ public function setAmountRefunded(Amount $amountRefunded): self
+ {
+ $this->amountRefunded = $amountRefunded;
+ return $this;
+ }
+
/**
* @return string
*/
@@ -172,7 +198,7 @@ public function setType(string $type): self
}
/**
- * @return bool
+ * @return boolean
*/
public function isFastCheckout(): bool
{
@@ -188,7 +214,7 @@ public function getFastCheckoutData(): array
}
/**
- * @return int
+ * @return integer
*/
public function getStatusCode(): int
{
@@ -357,11 +383,11 @@ public function getStatus(): array
}
/**
- * @param $code
- * @param $name
+ * @param mixed $code
+ * @param mixed $name
* @return $this
*/
- public function setStatusCodeName($code, $name): self
+ public function setStatusCodeName(mixed $code, mixed $name): self
{
$this->status = ['code' => $code, 'action' => $name];
return $this;
@@ -396,7 +422,7 @@ public function setReceipt(string $receipt): self
}
/**
- * @return bool
+ * @return boolean
*/
public function isTestmode(): bool
{
@@ -423,7 +449,7 @@ public function setIntegration(array $integration): self
}
/**
- * @return float|int
+ * @return float|integer
*/
public function getAmount()
{
@@ -673,82 +699,90 @@ public function getStatusUrl()
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isPaid()
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::PAID;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::PAID;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isPending()
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::PENDING;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::PENDING;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isCancelled()
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::CANCEL;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::CANCEL;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isPartialPayment()
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::PARTIAL_PAYMENT;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::PARTIAL_PAYMENT;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isAuthorized(): bool
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::AUTHORIZE;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::AUTHORIZE;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
- public function isRefundedFully()
+ public function isRefundedFully(): bool
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::REFUND;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::REFUND;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
- public function isRefundedPartial()
+ public function isRefundedPartial(): bool
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::PARTIAL_REFUND;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::PARTIAL_REFUND;
+ }
+ /**
+ * @return boolean
+ * @throws Exception
+ */
+ public function isVoided(): bool
+ {
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::VOID;
}
/**
- * @return bool
- * @throws \Exception
+ * @return boolean
+ * @throws Exception
*/
public function isBeingVerified()
{
- return (new PayStatus)->get($this->getStatusCode()) === PayStatus::VERIFY;
+ return (new PayStatus())->get($this->getStatusCode()) === PayStatus::VERIFY;
}
/**
* Check whether the status of the transaction is chargeback
*
- * @return bool
+ * @return boolean
*/
public function isChargeBack(): bool
{
@@ -756,9 +790,9 @@ public function isChargeBack(): bool
}
/**
- * @param bool $allowPartialRefunds
- * @return bool
- * @throws \Exception
+ * @param boolean $allowPartialRefunds
+ * @return boolean
+ * @throws Exception
*/
public function isRefunded(bool $allowPartialRefunds = true): bool
{
@@ -772,5 +806,4 @@ public function isRefunded(bool $allowPartialRefunds = true): bool
return false;
}
-
}
diff --git a/src/Model/Pay/PayStatus.php b/src/Model/Pay/PayStatus.php
index ad0e91e..c3e5bd2 100644
--- a/src/Model/Pay/PayStatus.php
+++ b/src/Model/Pay/PayStatus.php
@@ -14,28 +14,32 @@
*/
class PayStatus
{
- const PENDING = 20;
- const PAID = 100;
- const AUTHORIZE = 95;
- const CANCEL = -1;
- const REFUND = -81;
- const VERIFY = 85;
- const PARTIAL_PAYMENT = 80;
- const CHARGEBACK = -71;
- const PARTIAL_REFUND = -82;
- const PARTLY_CAPTURED = 97;
- const CONFIRMED = 75;
+ public const PENDING = 20;
+ public const PAID = 100;
+ public const AUTHORIZE = 95;
+ public const CANCEL = -1;
+ public const VOID = -61;
+ public const REFUND = -81;
+ public const VERIFY = 85;
+ public const PARTIAL_PAYMENT = 80;
+ public const CHARGEBACK = -71;
+ public const PARTIAL_REFUND = -82;
+ public const PARTLY_CAPTURED = 97;
+ public const CONFIRMED = 75;
- const EVENT_PAID = 'new_ppt';
- const EVENT_PENDING = 'pending';
+ public const EVENT_PAID = 'new_ppt';
+ public const EVENT_PENDING = 'pending';
+ public const EVENT_CHARGEBACK = 'chargeback';
+ public const EVENT_REFUND = 'refund';
+ public const EVENT_CAPTURE = 'capture';
/**
- * @param int $stateId
+ * @param integer $stateId
*
* Source:
* https://developer.pay.nl/docs/transaction-statuses#processing-statusses
*
- * @return int|mixed
+ * @return integer|mixed
* @throws Exception
*/
public function get(int $stateId)
@@ -45,6 +49,7 @@ public function get(int $stateId)
$mapper[-72] = self::REFUND;
$mapper[-81] = self::REFUND;
$mapper[-82] = self::PARTIAL_REFUND;
+ $mapper[-61] = self::VOID;
$mapper[20] = self::PENDING;
$mapper[25] = self::PENDING;
$mapper[50] = self::PENDING;
@@ -68,5 +73,4 @@ public function get(int $stateId)
}
}
}
-
-}
\ No newline at end of file
+}
diff --git a/src/Model/Response/ServiceGetConfigResponse.php b/src/Model/Response/ServiceGetConfigResponse.php
index cdc85d4..4d8d2c4 100644
--- a/src/Model/Response/ServiceGetConfigResponse.php
+++ b/src/Model/Response/ServiceGetConfigResponse.php
@@ -16,7 +16,6 @@
*/
class ServiceGetConfigResponse implements ModelInterface
{
-
/**
* @required
*
@@ -93,9 +92,8 @@ public function getCode(): string
}
/**
- * @param string $id
- *
- * @return Config
+ * @param string $code
+ * @return $this
*/
public function setCode(string $code): self
{
@@ -123,7 +121,7 @@ public function setName(string $name): self
}
/**
- * @return bool
+ * @return boolean
*/
public function isTestMode(): bool
{
@@ -172,6 +170,7 @@ public function getTranslations(): array
/**
* @param array $translations
+ * @return void
*/
public function setTranslations(array $translations): void
{
@@ -188,6 +187,7 @@ public function getStatus(): string
/**
* @param string $status
+ * @return void
*/
public function setStatus(string $status): void
{
@@ -204,6 +204,7 @@ public function getMerchant(): array
/**
* @param array $merchant
+ * @return void
*/
public function setMerchant(array $merchant): void
{
@@ -211,7 +212,7 @@ public function setMerchant(array $merchant): void
}
/**
- * @return bool
+ * @return boolean
*/
public function getTestMode(): bool
{
@@ -228,6 +229,7 @@ public function getCheckoutSequence(): array
/**
* @param array $checkoutSequence
+ * @return void
*/
public function setCheckoutSequence(array $checkoutSequence): void
{
@@ -257,6 +259,7 @@ public function getPaymentMethods(): array
/**
* @param CheckoutOptions $checkoutOptions
+ * @return void
*/
public function setCheckoutOptions(CheckoutOptions $checkoutOptions): void
{
@@ -273,6 +276,7 @@ public function getLayout(): array
/**
* @param array $layout
+ * @return void
*/
public function setLayout(array $layout): void
{
@@ -289,6 +293,7 @@ public function getTurnoverGroup(): array
/**
* @param array $turnoverGroup
+ * @return void
*/
public function setTurnoverGroup(array $turnoverGroup): void
{
@@ -305,6 +310,7 @@ public function getCategory(): array
/**
* @param array $category
+ * @return void
*/
public function setCategory(array $category): void
{
@@ -316,11 +322,12 @@ public function setCategory(array $category): void
*/
public function getTguList(): array
{
- return $this->tguList;
+ return $this->tguList ?? [];
}
/**
* @param array $tguList
+ * @return void
*/
public function setTguList(array $tguList): void
{
diff --git a/src/Request/AbstractRequest.php b/src/Request/AbstractRequest.php
index 1c6267b..97033b3 100644
--- a/src/Request/AbstractRequest.php
+++ b/src/Request/AbstractRequest.php
@@ -1,15 +1,11 @@
-setOptions($options);
- if (true === $this->hasOption('format')
- && true === is_string($this->getOption('format'))
- ) {
+ if (true === $this->hasOption('format') && true === is_string($this->getOption('format'))) {
$this->setFormat($this->getOption('format'));
}
- if (true === $this->hasOption('headers')
- && true === is_array($this->getOption('headers'))
- ) {
+ if (true === $this->hasOption('headers') && true === is_array($this->getOption('headers'))) {
$this->setHeaders($this->getOption('headers'));
}
@@ -141,7 +136,7 @@ public function getParams(): array
}
/**
- * @param string|int $name
+ * @param string|integer $name
*
* @return mixed|null
*/
@@ -154,9 +149,9 @@ public function getParam($name)
}
/**
- * @param string|int $name
+ * @param string|integer $name
*
- * @return bool
+ * @return boolean
*/
public function hasParam($name): bool
{
@@ -191,7 +186,7 @@ public function setParams(array $params): self
$optionalParams = [];
foreach ($this->getOptionalParams() as $paramName => $paramDefinition) {
# If optional paramater is provided...
- if(isset($params[$paramName])) {
+ if (isset($params[$paramName])) {
if (true === is_string($paramDefinition) && '' !== $paramDefinition && 1 !== preg_match("/^{$paramDefinition}$/", $this->getParam($paramName))) {
throw new InvalidArgumentException(sprintf('Optional param %s is not valid. It must match "%s"', $paramName, $paramDefinition));
}
@@ -207,7 +202,7 @@ public function setParams(array $params): self
}
/**
- * @inheritDoc
+ * @return string
*/
public function getUri(): string
{
@@ -226,7 +221,7 @@ public function setUri(string $uri): self
}
/**
- * @inheritDoc
+ * @return string
*/
public function getMethod(): string
{
@@ -349,16 +344,15 @@ public function getBody(): string
*
* @return AbstractRequest
*/
- public function setBody($body): self
+ public function setBody(mixed $body): self
{
$this->body = $body;
return $this;
}
/**
- * @inheritDoc
- *
- * @return AbstractRequest
+ * @param Client $client
+ * @return $this
*/
public function applyClient(Client $client): self
{
@@ -436,7 +430,7 @@ public function addFilter(FilterInterface $filter): self
*
* @return string
*/
- private function encodeBody($body): string
+ private function encodeBody(mixed $body): string
{
$encoder = new JsonEncoder();
$contentTypeHeader = 'application/json';
@@ -488,7 +482,7 @@ public function execute(Response $response): void
$requestBody = $this->getBody();
# Create a Guzzle PSR 7 Request
- $guzzleRequest = new Request($this->getMethod(), $uri, $this->getHeaders(), $requestBody);
+ $guzzleRequest = new \GuzzleHttp\Psr7\Request($this->getMethod(), $uri, $this->getHeaders(), $requestBody);
$curlRequest = 'curl -X ' . $this->getMethod() . ' ' . $guzzleClient->getConfig('base_uri') . $uri;
foreach ($this->getHeaders() as $headerfield => $headervalue) {
@@ -501,7 +495,7 @@ public function execute(Response $response): void
$this->dumpPreString(rtrim((string)$guzzleClient->getConfig('base_uri'), '/') . '/' . $guzzleRequest->getUri(), 'Requested URL');
$this->dumpPreString(implode(PHP_EOL, array_map(static function ($item, $key) {
return "{$key}: {$item}";
- }, $this->getHeaders(), array_keys($this->getHeaders()))) , 'Headers');
+ }, $this->getHeaders(), array_keys($this->getHeaders()))), 'Headers');
$guzzleResponse = $guzzleClient->send($guzzleRequest);
@@ -547,7 +541,7 @@ public function execute(Response $response): void
/**
* @param string $responseFormat
- * @param int $statusCode
+ * @param integer $statusCode
* @param string $rawBody
*
* @return string
@@ -619,7 +613,7 @@ protected function flattenErrors(array $errors, string $context = ''): array
*
* @return void
*/
- protected function validateBody($body): void
+ protected function validateBody(mixed $body): void
{
if (true === is_string($body)) {
return;
diff --git a/src/Request/RequestData.php b/src/Request/RequestData.php
index 83a5220..f357fad 100644
--- a/src/Request/RequestData.php
+++ b/src/Request/RequestData.php
@@ -18,6 +18,7 @@
*/
abstract class RequestData implements RequestDataInterface
{
+ protected Application $application;
protected string $mapperName = '';
protected string $uri = '';
protected string $methodType = 'GET';
@@ -46,6 +47,15 @@ public function setConfig(Config $config): self
return $this;
}
+ /**
+ * @param Application $application
+ * @return void
+ */
+ public function setApplication(Application $application): void
+ {
+ $this->application = $application;
+ }
+
/**
* @return mixed
* @throws PayException
@@ -62,8 +72,16 @@ public function start()
$config->setCore($config->getFailoverUrl());
}
+ if ($config->isEmpty()) {
+ throw new PayException('Please check your config', 0, 0);
+ }
+
try {
- $response = (Application::init($config))->request($this)->run();
+ if (empty($this->application)) {
+ $this->application = Application::init($config);
+ }
+
+ $response = $this->application->request($this)->run();
} catch (\Throwable $e) {
throw (new PayException('Could not initiate API call:' . $e->getMessage(), 0, 0))
->setFriendlyMessage(Text::getFriendlyMessage($e->getMessage()));
@@ -95,14 +113,13 @@ public function start()
}
}
-
- /*
- * For defining the arguments used in the requestpath
+ /**
+ * @return array
*/
abstract public function getPathParameters(): array;
- /*
- * For defining the arguments used in the body of the request
+ /**
+ * @return array
*/
abstract public function getBodyParameters(): array;
@@ -129,4 +146,4 @@ public function getMethodName(): string
{
return $this->mapperName;
}
-}
\ No newline at end of file
+}
diff --git a/src/Request/RequestInterface.php b/src/Request/RequestInterface.php
index d23d904..4783578 100644
--- a/src/Request/RequestInterface.php
+++ b/src/Request/RequestInterface.php
@@ -4,9 +4,9 @@
namespace PayNL\Sdk\Request;
+use GuzzleHttp\Client;
use PayNL\Sdk\Common\FormatAwareInterface;
use PayNL\Sdk\Response\Response;
-use PayNL\GuzzleHttp\Client;
/**
* Interface RequestInterface
diff --git a/src/Resources/functions/misc.php b/src/Resources/functions/misc.php
new file mode 100644
index 0000000..eb273ab
--- /dev/null
+++ b/src/Resources/functions/misc.php
@@ -0,0 +1,27 @@
+splitAddress($address);
+ }
+}
+
+if (false === function_exists('paynl_get_ip')) {
+ /**
+ * @return mixed
+ */
+ function paynl_get_ip(): mixed
+ {
+ return (new Misc())->getIp();
+ }
+}
diff --git a/src/Resources/functions/text.php b/src/Resources/functions/text.php
index 9426642..3f3baab 100644
--- a/src/Resources/functions/text.php
+++ b/src/Resources/functions/text.php
@@ -2,25 +2,10 @@
declare(strict_types=1);
-use PayNL\Sdk\Util\Text;
-
-if (false === function_exists('paynl_split_address')) {
- /**
- * @param string $address
- *
- * @return array
- */
- function paynl_split_address(string $address): array
- {
- return (new Text())->splitAddress($address);
- }
-}
-
-
if (false === function_exists('dbg')) {
/**
* @param string $message
- * @return string
+ * @return void
*/
function dbg(string $message): void
{
@@ -28,4 +13,4 @@ function dbg(string $message): void
displayPayDebug($message);
}
}
-}
\ No newline at end of file
+}
diff --git a/src/Util/Exchange.php b/src/Util/Exchange.php
index cae6240..06e54a1 100644
--- a/src/Util/Exchange.php
+++ b/src/Util/Exchange.php
@@ -4,9 +4,9 @@
namespace PayNL\Sdk\Util;
-use PayNL\Sdk\Config\Config as PayConfig;
use PayNL\Sdk\Config\Config;
use PayNL\Sdk\Model\Amount;
+use PayNL\Sdk\Util\ExchangeResponse;
use PayNL\Sdk\Model\Request\OrderStatusRequest;
use PayNL\Sdk\Model\Pay\PayStatus;
use PayNL\Sdk\Model\Pay\PayOrder;
@@ -24,7 +24,7 @@ class Exchange
{
private PayLoad $payload;
private ?array $custom_payload;
- private $headers;
+ private mixed $headers;
/**
* @param array|null $payload
@@ -35,23 +35,54 @@ public function __construct(array $payload = null)
}
/**
- * @return bool
+ * @param boolean $includeAuth If yes, treat authorize as "paid"
+ * @return boolean
+ * @throws PayException
*/
- public function eventStateChangeToPaid()
+ public function eventPaid(bool $includeAuth = false): bool
{
- return $this->getAction() === PayStatus::EVENT_PAID;
+ return $this->getAction() === PayStatus::EVENT_PAID || ($includeAuth == true && $this->getAction() === PayStatus::AUTHORIZE);
+ }
+
+ /**
+ * @return boolean
+ * @throws PayException
+ */
+ public function eventChargeback(): bool
+ {
+ return substr($this->getAction(), 0, 10) === PayStatus::EVENT_CHARGEBACK;
+ }
+
+ /**
+ * @return boolean
+ * @throws PayException
+ */
+ public function eventRefund()
+ {
+ return substr($this->getAction(), 0, 6) === PayStatus::EVENT_REFUND;
+ }
+
+ /**
+ * @return boolean
+ * @throws PayException
+ */
+ public function eventCapture()
+ {
+ return $this->getAction() == PayStatus::EVENT_CAPTURE;
}
/**
* Set your exchange response in the end of your exchange processing
*
- * @param bool $result
+ * @param boolean $result
* @param string $message
- * @param bool $returnOutput If true, then this method returs the output string
+ * @param boolean $returnOutput If true, then this method returs the output string
* @return false|string|void
*/
- public function setResponse(bool $result, string $message, $returnOutput = false)
+ public function setResponse(bool $result, string $message, bool $returnOutput = false)
{
+ $message = ucfirst(strtolower($message));
+
if ($this->isSignExchange() === true) {
$response = json_encode(['result' => $result, 'description' => $message]);
} else {
@@ -66,41 +97,54 @@ public function setResponse(bool $result, string $message, $returnOutput = false
}
}
+ /**
+ * @param \PayNL\Sdk\Util\ExchangeResponse $e
+ * @param boolean $returnOutput
+ * @return false|string|null
+ */
+ public function setExchangeResponse(ExchangeResponse $e, bool $returnOutput = false)
+ {
+ return $this->setResponse($e->getResult(), $e->getMessage(), $returnOutput);
+ }
+
/**
* @return string
+ * @throws PayException
*/
public function getAction()
{
try {
$payload = $this->getPayload();
} catch (\Throwable $e) {
- return false;
+ throw new PayException('Could not retrieve action: ' . $e->getMessage());
}
return $payload->getAction();
}
/**
- * @return mixed|string
+ * @return string
+ * @throws PayException
*/
public function getReference()
{
try {
$payload = $this->getPayload();
} catch (\Throwable $e) {
- return false;
+ throw new PayException('Could not retrieve reference: ' . $e->getMessage());
}
return $payload->getReference();
}
/**
* @return string
+ * @throws PayException
*/
public function getPayOrderId()
{
try {
$payload = $this->getPayload();
} catch (\Throwable $e) {
- return false;
+ throw new Exception('Could not retrieve payOrderId: ' . $e->getMessage());
}
return $payload->getPayOrderId();
}
@@ -142,15 +186,10 @@ public function getPayLoad()
} else {
$rawBody = file_get_contents('php://input');
if (empty(trim($rawBody))) {
- throw new Exception('Empty payload', 8002);
+ throw new Exception('Empty or incomplete payload', 8002);
}
- $tguData = json_decode($rawBody, true, 512, 4194304);
-
- $exchangeType = $tguData['type'] ?? null;
- if ($exchangeType != 'order') {
- throw new Exception('Cant handle exchange type other then order', 8003);
- }
+ $tguData = json_decode($rawBody, true, 512, JSON_BIGINT_AS_STRING);
}
if (empty($tguData['object'])) {
@@ -201,11 +240,11 @@ public function getPayLoad()
/**
* Process the exchange request.
*
- * @param Config|null $config
+ * @param Config |null $config
* @return PayOrder
* @throws Exception
*/
- public function process(PayConfig $config = null): PayOrder
+ public function process(Config $config = null): PayOrder
{
$payload = $this->getPayload();
@@ -236,6 +275,7 @@ public function process(PayConfig $config = null): PayOrder
# Not a signing request...
if ($payloadState === PayStatus::PENDING) {
$payOrder = new PayOrder();
+ $payOrder->setType($payload->getType());
$payOrder->setStatusCodeName(PayStatus::PENDING, 'PENDING');
} else {
# Continue to check the order status manually
@@ -254,7 +294,6 @@ public function process(PayConfig $config = null): PayOrder
}
$payOrder = $request->setConfig($config)->start();
-
} catch (PayException $e) {
dbg($e->getMessage());
throw new Exception('API Retrieval error: ' . $e->getFriendlyMessage());
@@ -268,7 +307,7 @@ public function process(PayConfig $config = null): PayOrder
/**
* @param string $username Token code
* @param string $password API Token
- * @return bool Returns true if the signing is successful and authorised
+ * @return boolean Returns true if the signing is successful and authorised
*/
public function checkSignExchange(string $username = '', string $password = ''): bool
{
@@ -306,7 +345,7 @@ public function checkSignExchange(string $username = '', string $password = ''):
}
/**
- * @return bool
+ * @return boolean
*/
public function isSignExchange(): bool
{
@@ -318,12 +357,11 @@ public function isSignExchange(): bool
/**
* @return array|false|string
*/
- private function getRequestHeaders()
+ private function getRequestHeaders(): bool|array|string
{
if (empty($this->headers)) {
$this->headers = array_change_key_case(getallheaders());
}
return $this->headers;
}
-
-}
\ No newline at end of file
+}
diff --git a/src/Util/ExchangeResponse.php b/src/Util/ExchangeResponse.php
new file mode 100644
index 0000000..d235b4f
--- /dev/null
+++ b/src/Util/ExchangeResponse.php
@@ -0,0 +1,35 @@
+result = $result;
+ $this->message = $message;
+ }
+
+ /**
+ * @return boolean
+ */
+ public function getResult(): bool
+ {
+ return $this->result;
+ }
+
+ /**
+ * @return string
+ */
+ public function getMessage(): string
+ {
+ return $this->message;
+ }
+}
diff --git a/src/Util/Misc.php b/src/Util/Misc.php
index 677cef5..6756208 100644
--- a/src/Util/Misc.php
+++ b/src/Util/Misc.php
@@ -20,14 +20,14 @@ class Misc
/**
* @param string $file
*
- * @throws InvalidArgumentException when given file can not be found or read
+ * @return string
* @throws LogicException when the class name is not the same as the terminating class file name
* (PSR-4 3.3 - https://www.php-fig.org/psr/psr-4/)
*
* @SuppressWarnings(PHPMD.NPathComplexity)
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
*
- * @return string
+ * @throws InvalidArgumentException when given file can not be found or read
*/
public static function getClassNameByFile(string $file): string
{
@@ -73,9 +73,9 @@ public static function getClassNameByFile(string $file): string
}
if ($tokens[$counter][0] === T_CLASS) {
- for ($nextCounter = $counter+1; $nextCounter < $tokenCount; $nextCounter++) {
+ for ($nextCounter = $counter + 1; $nextCounter < $tokenCount; $nextCounter++) {
if ($tokens[$nextCounter] === '{') {
- $class = $tokens[$counter+2][1];
+ $class = $tokens[$counter + 2][1];
}
}
}
@@ -107,4 +107,60 @@ public static function getClassNameByFQN(string $fqn): string
$parts = explode($namespaceSeparator, $fqn);
return array_pop($parts) ?? '';
}
+
+ /**
+ * Get the IP of the user
+ *
+ * @return mixed
+ */
+ public function getIp()
+ {
+ // Use $_SERVER or get the headers if we can
+ $headers = $_SERVER;
+ if (function_exists('apache_request_headers')) {
+ $headers = apache_request_headers();
+ }
+
+ // Get the forwarded IP if it exists
+ $the_ip = $_SERVER['REMOTE_ADDR'];
+ if (array_key_exists('X-Forwarded-For', $headers)) {
+ $the_ip = $headers['X-Forwarded-For'];
+ } elseif (array_key_exists('HTTP_X_FORWARDED_FOR', $headers)) {
+ $the_ip = $headers['HTTP_X_FORWARDED_FOR'];
+ }
+ $arrIp = explode(',', $the_ip);
+
+ return filter_var(trim(trim(!empty($arrIp[0]) ? $arrIp[0] : ''), '[]'), FILTER_VALIDATE_IP);
+ }
+
+ /**
+ * @param string $address
+ *
+ * @return array
+ */
+ public function splitAddress(string $address): array
+ {
+ $street = $number = '';
+
+ $address = trim($address);
+ $addressParts = preg_split('/(\s+)(\d+)/', $address, 2, PREG_SPLIT_DELIM_CAPTURE);
+
+ if (true === is_array($addressParts)) {
+ $street = trim(array_shift($addressParts) ?? '');
+ $number = trim(implode('', $addressParts));
+ }
+
+ if (true === empty($street) || true === empty($number)) {
+ $addressParts = preg_split('/([A-z]{2,})/', $address, 2, PREG_SPLIT_DELIM_CAPTURE);
+
+ if (true === is_array($addressParts)) {
+ $number = trim(array_shift($addressParts) ?? '');
+ $street = trim(implode('', $addressParts));
+ }
+ }
+
+ $number = substr($number, 0, 45);
+
+ return compact('street', 'number');
+ }
}
diff --git a/src/Util/Text.php b/src/Util/Text.php
index ec8f836..acba9a6 100644
--- a/src/Util/Text.php
+++ b/src/Util/Text.php
@@ -1,6 +1,6 @@
'Transaction not ready for refund.',