diff --git a/classes/vendor/composer/ClassLoader.php b/classes/vendor/composer/ClassLoader.php deleted file mode 100644 index 03b9bb9..0000000 --- a/classes/vendor/composer/ClassLoader.php +++ /dev/null @@ -1,445 +0,0 @@ - - * Jordi Boggiano - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Composer\Autoload; - -/** - * ClassLoader implements a PSR-0, PSR-4 and classmap class loader. - * - * $loader = new \Composer\Autoload\ClassLoader(); - * - * // register classes with namespaces - * $loader->add('Symfony\Component', __DIR__.'/component'); - * $loader->add('Symfony', __DIR__.'/framework'); - * - * // activate the autoloader - * $loader->register(); - * - * // to enable searching the include path (eg. for PEAR packages) - * $loader->setUseIncludePath(true); - * - * In this example, if you try to use a class in the Symfony\Component - * namespace or one of its children (Symfony\Component\Console for instance), - * the autoloader will first look for the class under the component/ - * directory, and it will then fallback to the framework/ directory if not - * found before giving up. - * - * This class is loosely based on the Symfony UniversalClassLoader. - * - * @author Fabien Potencier - * @author Jordi Boggiano - * @see http://www.php-fig.org/psr/psr-0/ - * @see http://www.php-fig.org/psr/psr-4/ - */ -class ClassLoader -{ - // PSR-4 - private $prefixLengthsPsr4 = array(); - private $prefixDirsPsr4 = array(); - private $fallbackDirsPsr4 = array(); - - // PSR-0 - private $prefixesPsr0 = array(); - private $fallbackDirsPsr0 = array(); - - private $useIncludePath = false; - private $classMap = array(); - private $classMapAuthoritative = false; - private $missingClasses = array(); - private $apcuPrefix; - - public function getPrefixes() - { - if (!empty($this->prefixesPsr0)) { - return call_user_func_array('array_merge', array_values($this->prefixesPsr0)); - } - - return array(); - } - - public function getPrefixesPsr4() - { - return $this->prefixDirsPsr4; - } - - public function getFallbackDirs() - { - return $this->fallbackDirsPsr0; - } - - public function getFallbackDirsPsr4() - { - return $this->fallbackDirsPsr4; - } - - public function getClassMap() - { - return $this->classMap; - } - - /** - * @param array $classMap Class to filename map - */ - public function addClassMap(array $classMap) - { - if ($this->classMap) { - $this->classMap = array_merge($this->classMap, $classMap); - } else { - $this->classMap = $classMap; - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, either - * appending or prepending to the ones previously set for this prefix. - * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories - */ - public function add($prefix, $paths, $prepend = false) - { - if (!$prefix) { - if ($prepend) { - $this->fallbackDirsPsr0 = array_merge( - (array) $paths, - $this->fallbackDirsPsr0 - ); - } else { - $this->fallbackDirsPsr0 = array_merge( - $this->fallbackDirsPsr0, - (array) $paths - ); - } - - return; - } - - $first = $prefix[0]; - if (!isset($this->prefixesPsr0[$first][$prefix])) { - $this->prefixesPsr0[$first][$prefix] = (array) $paths; - - return; - } - if ($prepend) { - $this->prefixesPsr0[$first][$prefix] = array_merge( - (array) $paths, - $this->prefixesPsr0[$first][$prefix] - ); - } else { - $this->prefixesPsr0[$first][$prefix] = array_merge( - $this->prefixesPsr0[$first][$prefix], - (array) $paths - ); - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, either - * appending or prepending to the ones previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories - * @param bool $prepend Whether to prepend the directories - * - * @throws \InvalidArgumentException - */ - public function addPsr4($prefix, $paths, $prepend = false) - { - if (!$prefix) { - // Register directories for the root namespace. - if ($prepend) { - $this->fallbackDirsPsr4 = array_merge( - (array) $paths, - $this->fallbackDirsPsr4 - ); - } else { - $this->fallbackDirsPsr4 = array_merge( - $this->fallbackDirsPsr4, - (array) $paths - ); - } - } elseif (!isset($this->prefixDirsPsr4[$prefix])) { - // Register directories for a new namespace. - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = (array) $paths; - } elseif ($prepend) { - // Prepend directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - (array) $paths, - $this->prefixDirsPsr4[$prefix] - ); - } else { - // Append directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - $this->prefixDirsPsr4[$prefix], - (array) $paths - ); - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, - * replacing any others previously set for this prefix. - * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 base directories - */ - public function set($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr0 = (array) $paths; - } else { - $this->prefixesPsr0[$prefix[0]][$prefix] = (array) $paths; - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, - * replacing any others previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories - * - * @throws \InvalidArgumentException - */ - public function setPsr4($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr4 = (array) $paths; - } else { - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = (array) $paths; - } - } - - /** - * Turns on searching the include path for class files. - * - * @param bool $useIncludePath - */ - public function setUseIncludePath($useIncludePath) - { - $this->useIncludePath = $useIncludePath; - } - - /** - * Can be used to check if the autoloader uses the include path to check - * for classes. - * - * @return bool - */ - public function getUseIncludePath() - { - return $this->useIncludePath; - } - - /** - * Turns off searching the prefix and fallback directories for classes - * that have not been registered with the class map. - * - * @param bool $classMapAuthoritative - */ - public function setClassMapAuthoritative($classMapAuthoritative) - { - $this->classMapAuthoritative = $classMapAuthoritative; - } - - /** - * Should class lookup fail if not found in the current class map? - * - * @return bool - */ - public function isClassMapAuthoritative() - { - return $this->classMapAuthoritative; - } - - /** - * APCu prefix to use to cache found/not-found classes, if the extension is enabled. - * - * @param string|null $apcuPrefix - */ - public function setApcuPrefix($apcuPrefix) - { - $this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null; - } - - /** - * The APCu prefix in use, or null if APCu caching is not enabled. - * - * @return string|null - */ - public function getApcuPrefix() - { - return $this->apcuPrefix; - } - - /** - * Registers this instance as an autoloader. - * - * @param bool $prepend Whether to prepend the autoloader or not - */ - public function register($prepend = false) - { - spl_autoload_register(array($this, 'loadClass'), true, $prepend); - } - - /** - * Unregisters this instance as an autoloader. - */ - public function unregister() - { - spl_autoload_unregister(array($this, 'loadClass')); - } - - /** - * Loads the given class or interface. - * - * @param string $class The name of the class - * @return bool|null True if loaded, null otherwise - */ - public function loadClass($class) - { - if ($file = $this->findFile($class)) { - includeFile($file); - - return true; - } - } - - /** - * Finds the path to the file where the class is defined. - * - * @param string $class The name of the class - * - * @return string|false The path if found, false otherwise - */ - public function findFile($class) - { - // class map lookup - if (isset($this->classMap[$class])) { - return $this->classMap[$class]; - } - if ($this->classMapAuthoritative || isset($this->missingClasses[$class])) { - return false; - } - if (null !== $this->apcuPrefix) { - $file = apcu_fetch($this->apcuPrefix.$class, $hit); - if ($hit) { - return $file; - } - } - - $file = $this->findFileWithExtension($class, '.php'); - - // Search for Hack files if we are running on HHVM - if (false === $file && defined('HHVM_VERSION')) { - $file = $this->findFileWithExtension($class, '.hh'); - } - - if (null !== $this->apcuPrefix) { - apcu_add($this->apcuPrefix.$class, $file); - } - - if (false === $file) { - // Remember that this class does not exist. - $this->missingClasses[$class] = true; - } - - return $file; - } - - private function findFileWithExtension($class, $ext) - { - // PSR-4 lookup - $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext; - - $first = $class[0]; - if (isset($this->prefixLengthsPsr4[$first])) { - $subPath = $class; - while (false !== $lastPos = strrpos($subPath, '\\')) { - $subPath = substr($subPath, 0, $lastPos); - $search = $subPath . '\\'; - if (isset($this->prefixDirsPsr4[$search])) { - $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); - foreach ($this->prefixDirsPsr4[$search] as $dir) { - if (file_exists($file = $dir . $pathEnd)) { - return $file; - } - } - } - } - } - - // PSR-4 fallback dirs - foreach ($this->fallbackDirsPsr4 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) { - return $file; - } - } - - // PSR-0 lookup - if (false !== $pos = strrpos($class, '\\')) { - // namespaced class name - $logicalPathPsr0 = substr($logicalPathPsr4, 0, $pos + 1) - . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR); - } else { - // PEAR-like class name - $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext; - } - - if (isset($this->prefixesPsr0[$first])) { - foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) { - if (0 === strpos($class, $prefix)) { - foreach ($dirs as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - } - } - } - - // PSR-0 fallback dirs - foreach ($this->fallbackDirsPsr0 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - - // PSR-0 include paths. - if ($this->useIncludePath && $file = stream_resolve_include_path($logicalPathPsr0)) { - return $file; - } - - return false; - } -} - -/** - * Scope isolated include. - * - * Prevents access to $this/self from included files. - */ -function includeFile($file) -{ - include $file; -} diff --git a/classes/vendor/composer/LICENSE b/classes/vendor/composer/LICENSE deleted file mode 100644 index f27399a..0000000 --- a/classes/vendor/composer/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ - -Copyright (c) Nils Adermann, Jordi Boggiano - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. - diff --git a/classes/vendor/composer/autoload_classmap.php b/classes/vendor/composer/autoload_classmap.php deleted file mode 100644 index c3a0d5a..0000000 --- a/classes/vendor/composer/autoload_classmap.php +++ /dev/null @@ -1,48 +0,0 @@ - $vendorDir . '/dallgoot/yaml/sources/Yaml.php', - 'Dallgoot\\Yaml\\Builder' => $vendorDir . '/dallgoot/yaml/sources/Builder.php', - 'Dallgoot\\Yaml\\Compact' => $vendorDir . '/dallgoot/yaml/sources/types/Compact.php', - 'Dallgoot\\Yaml\\Dumper' => $vendorDir . '/dallgoot/yaml/sources/Dumper.php', - 'Dallgoot\\Yaml\\DumperHandlers' => $vendorDir . '/dallgoot/yaml/sources/DumperHandlers.php', - 'Dallgoot\\Yaml\\Loader' => $vendorDir . '/dallgoot/yaml/sources/Loader.php', - 'Dallgoot\\Yaml\\NodeFactory' => $vendorDir . '/dallgoot/yaml/sources/NodeFactory.php', - 'Dallgoot\\Yaml\\NodeList' => $vendorDir . '/dallgoot/yaml/sources/NodeList.php', - 'Dallgoot\\Yaml\\Nodes\\Actions' => $vendorDir . '/dallgoot/yaml/sources/nodes/abstract/Actions.php', - 'Dallgoot\\Yaml\\Nodes\\Anchor' => $vendorDir . '/dallgoot/yaml/sources/nodes/Anchor.php', - 'Dallgoot\\Yaml\\Nodes\\Blank' => $vendorDir . '/dallgoot/yaml/sources/nodes/Blank.php', - 'Dallgoot\\Yaml\\Nodes\\Comment' => $vendorDir . '/dallgoot/yaml/sources/nodes/Comment.php', - 'Dallgoot\\Yaml\\Nodes\\CompactMapping' => $vendorDir . '/dallgoot/yaml/sources/nodes/CompactMapping.php', - 'Dallgoot\\Yaml\\Nodes\\CompactSequence' => $vendorDir . '/dallgoot/yaml/sources/nodes/CompactSequence.php', - 'Dallgoot\\Yaml\\Nodes\\Directive' => $vendorDir . '/dallgoot/yaml/sources/nodes/Directive.php', - 'Dallgoot\\Yaml\\Nodes\\DocEnd' => $vendorDir . '/dallgoot/yaml/sources/nodes/DocEnd.php', - 'Dallgoot\\Yaml\\Nodes\\DocStart' => $vendorDir . '/dallgoot/yaml/sources/nodes/DocStart.php', - 'Dallgoot\\Yaml\\Nodes\\Item' => $vendorDir . '/dallgoot/yaml/sources/nodes/Item.php', - 'Dallgoot\\Yaml\\Nodes\\JSON' => $vendorDir . '/dallgoot/yaml/sources/nodes/JSON.php', - 'Dallgoot\\Yaml\\Nodes\\Key' => $vendorDir . '/dallgoot/yaml/sources/nodes/Key.php', - 'Dallgoot\\Yaml\\Nodes\\Literal' => $vendorDir . '/dallgoot/yaml/sources/nodes/Literal.php', - 'Dallgoot\\Yaml\\Nodes\\LiteralFolded' => $vendorDir . '/dallgoot/yaml/sources/nodes/LiteralFolded.php', - 'Dallgoot\\Yaml\\Nodes\\Literals' => $vendorDir . '/dallgoot/yaml/sources/nodes/abstract/Literals.php', - 'Dallgoot\\Yaml\\Nodes\\NodeGeneric' => $vendorDir . '/dallgoot/yaml/sources/nodes/abstract/NodeGeneric.php', - 'Dallgoot\\Yaml\\Nodes\\Partial' => $vendorDir . '/dallgoot/yaml/sources/nodes/Partial.php', - 'Dallgoot\\Yaml\\Nodes\\Quoted' => $vendorDir . '/dallgoot/yaml/sources/nodes/Quoted.php', - 'Dallgoot\\Yaml\\Nodes\\Root' => $vendorDir . '/dallgoot/yaml/sources/nodes/Root.php', - 'Dallgoot\\Yaml\\Nodes\\Scalar' => $vendorDir . '/dallgoot/yaml/sources/nodes/Scalar.php', - 'Dallgoot\\Yaml\\Nodes\\SetKey' => $vendorDir . '/dallgoot/yaml/sources/nodes/SetKey.php', - 'Dallgoot\\Yaml\\Nodes\\SetValue' => $vendorDir . '/dallgoot/yaml/sources/nodes/SetValue.php', - 'Dallgoot\\Yaml\\Nodes\\Tag' => $vendorDir . '/dallgoot/yaml/sources/nodes/Tag.php', - 'Dallgoot\\Yaml\\Regex' => $vendorDir . '/dallgoot/yaml/sources/Regex.php', - 'Dallgoot\\Yaml\\TagFactory' => $vendorDir . '/dallgoot/yaml/sources/tag/TagFactory.php', - 'Dallgoot\\Yaml\\Tag\\CoreSchema' => $vendorDir . '/dallgoot/yaml/sources/tag/CoreSchema.php', - 'Dallgoot\\Yaml\\Tag\\SchemaInterface' => $vendorDir . '/dallgoot/yaml/sources/tag/SchemaInterface.php', - 'Dallgoot\\Yaml\\Tag\\SymfonySchema' => $vendorDir . '/dallgoot/yaml/sources/tag/SymfonySchema.php', - 'Dallgoot\\Yaml\\Tagged' => $vendorDir . '/dallgoot/yaml/sources/types/Tagged.php', - 'Dallgoot\\Yaml\\YamlObject' => $vendorDir . '/dallgoot/yaml/sources/types/YamlObject.php', - 'Dallgoot\\Yaml\\YamlProperties' => $vendorDir . '/dallgoot/yaml/sources/YamlProperties.php', -); diff --git a/classes/vendor/composer/autoload_namespaces.php b/classes/vendor/composer/autoload_namespaces.php deleted file mode 100644 index 4a9c20b..0000000 --- a/classes/vendor/composer/autoload_namespaces.php +++ /dev/null @@ -1,9 +0,0 @@ - array($vendorDir . '/goat1000/svggraph'), -); diff --git a/classes/vendor/composer/autoload_real.php b/classes/vendor/composer/autoload_real.php deleted file mode 100644 index ae19197..0000000 --- a/classes/vendor/composer/autoload_real.php +++ /dev/null @@ -1,55 +0,0 @@ -= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); - if ($useStaticLoader) { - require_once __DIR__ . '/autoload_static.php'; - - call_user_func(\Composer\Autoload\ComposerStaticInit0b5f153730a4a4fe6e88cb8865fd9823::getInitializer($loader)); - } else { - $map = require __DIR__ . '/autoload_namespaces.php'; - foreach ($map as $namespace => $path) { - $loader->set($namespace, $path); - } - - $map = require __DIR__ . '/autoload_psr4.php'; - foreach ($map as $namespace => $path) { - $loader->setPsr4($namespace, $path); - } - - $classMap = require __DIR__ . '/autoload_classmap.php'; - if ($classMap) { - $loader->addClassMap($classMap); - } - } - - $loader->register(true); - - return $loader; - } -} diff --git a/classes/vendor/composer/autoload_static.php b/classes/vendor/composer/autoload_static.php deleted file mode 100644 index 80bdb87..0000000 --- a/classes/vendor/composer/autoload_static.php +++ /dev/null @@ -1,74 +0,0 @@ - - array ( - 'Goat1000\\SVGGraph\\' => 18, - ), - ); - - public static $prefixDirsPsr4 = array ( - 'Goat1000\\SVGGraph\\' => - array ( - 0 => __DIR__ . '/..' . '/goat1000/svggraph', - ), - ); - - public static $classMap = array ( - 'Dallgoot\\Yaml' => __DIR__ . '/..' . '/dallgoot/yaml/sources/Yaml.php', - 'Dallgoot\\Yaml\\Builder' => __DIR__ . '/..' . '/dallgoot/yaml/sources/Builder.php', - 'Dallgoot\\Yaml\\Compact' => __DIR__ . '/..' . '/dallgoot/yaml/sources/types/Compact.php', - 'Dallgoot\\Yaml\\Dumper' => __DIR__ . '/..' . '/dallgoot/yaml/sources/Dumper.php', - 'Dallgoot\\Yaml\\DumperHandlers' => __DIR__ . '/..' . '/dallgoot/yaml/sources/DumperHandlers.php', - 'Dallgoot\\Yaml\\Loader' => __DIR__ . '/..' . '/dallgoot/yaml/sources/Loader.php', - 'Dallgoot\\Yaml\\NodeFactory' => __DIR__ . '/..' . '/dallgoot/yaml/sources/NodeFactory.php', - 'Dallgoot\\Yaml\\NodeList' => __DIR__ . '/..' . '/dallgoot/yaml/sources/NodeList.php', - 'Dallgoot\\Yaml\\Nodes\\Actions' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/abstract/Actions.php', - 'Dallgoot\\Yaml\\Nodes\\Anchor' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Anchor.php', - 'Dallgoot\\Yaml\\Nodes\\Blank' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Blank.php', - 'Dallgoot\\Yaml\\Nodes\\Comment' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Comment.php', - 'Dallgoot\\Yaml\\Nodes\\CompactMapping' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/CompactMapping.php', - 'Dallgoot\\Yaml\\Nodes\\CompactSequence' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/CompactSequence.php', - 'Dallgoot\\Yaml\\Nodes\\Directive' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Directive.php', - 'Dallgoot\\Yaml\\Nodes\\DocEnd' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/DocEnd.php', - 'Dallgoot\\Yaml\\Nodes\\DocStart' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/DocStart.php', - 'Dallgoot\\Yaml\\Nodes\\Item' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Item.php', - 'Dallgoot\\Yaml\\Nodes\\JSON' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/JSON.php', - 'Dallgoot\\Yaml\\Nodes\\Key' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Key.php', - 'Dallgoot\\Yaml\\Nodes\\Literal' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Literal.php', - 'Dallgoot\\Yaml\\Nodes\\LiteralFolded' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/LiteralFolded.php', - 'Dallgoot\\Yaml\\Nodes\\Literals' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/abstract/Literals.php', - 'Dallgoot\\Yaml\\Nodes\\NodeGeneric' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/abstract/NodeGeneric.php', - 'Dallgoot\\Yaml\\Nodes\\Partial' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Partial.php', - 'Dallgoot\\Yaml\\Nodes\\Quoted' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Quoted.php', - 'Dallgoot\\Yaml\\Nodes\\Root' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Root.php', - 'Dallgoot\\Yaml\\Nodes\\Scalar' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Scalar.php', - 'Dallgoot\\Yaml\\Nodes\\SetKey' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/SetKey.php', - 'Dallgoot\\Yaml\\Nodes\\SetValue' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/SetValue.php', - 'Dallgoot\\Yaml\\Nodes\\Tag' => __DIR__ . '/..' . '/dallgoot/yaml/sources/nodes/Tag.php', - 'Dallgoot\\Yaml\\Regex' => __DIR__ . '/..' . '/dallgoot/yaml/sources/Regex.php', - 'Dallgoot\\Yaml\\TagFactory' => __DIR__ . '/..' . '/dallgoot/yaml/sources/tag/TagFactory.php', - 'Dallgoot\\Yaml\\Tag\\CoreSchema' => __DIR__ . '/..' . '/dallgoot/yaml/sources/tag/CoreSchema.php', - 'Dallgoot\\Yaml\\Tag\\SchemaInterface' => __DIR__ . '/..' . '/dallgoot/yaml/sources/tag/SchemaInterface.php', - 'Dallgoot\\Yaml\\Tag\\SymfonySchema' => __DIR__ . '/..' . '/dallgoot/yaml/sources/tag/SymfonySchema.php', - 'Dallgoot\\Yaml\\Tagged' => __DIR__ . '/..' . '/dallgoot/yaml/sources/types/Tagged.php', - 'Dallgoot\\Yaml\\YamlObject' => __DIR__ . '/..' . '/dallgoot/yaml/sources/types/YamlObject.php', - 'Dallgoot\\Yaml\\YamlProperties' => __DIR__ . '/..' . '/dallgoot/yaml/sources/YamlProperties.php', - ); - - public static function getInitializer(ClassLoader $loader) - { - return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInit0b5f153730a4a4fe6e88cb8865fd9823::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInit0b5f153730a4a4fe6e88cb8865fd9823::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInit0b5f153730a4a4fe6e88cb8865fd9823::$classMap; - - }, null, ClassLoader::class); - } -} diff --git a/classes/vendor/composer/installed.json b/classes/vendor/composer/installed.json deleted file mode 100644 index 6686f07..0000000 --- a/classes/vendor/composer/installed.json +++ /dev/null @@ -1,97 +0,0 @@ -[ - { - "name": "dallgoot/yaml", - "version": "v0.3.2", - "version_normalized": "0.3.2.0", - "source": { - "type": "git", - "url": "https://github.com/dallgoot/yaml.git", - "reference": "505ce0f23b40767d3016ea16e1f101085f3a63c0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/dallgoot/yaml/zipball/505ce0f23b40767d3016ea16e1f101085f3a63c0", - "reference": "505ce0f23b40767d3016ea16e1f101085f3a63c0", - "shasum": "" - }, - "require": { - "ext-json": "*", - "ext-pcre": "*", - "ext-spl": "*", - "lib-pcre": "*", - "php": ">=7.1.10" - }, - "require-dev": { - "composer/xdebug-handler": "^1.3", - "ext-reflection": "*", - "paulthebaud/phpunit-generator": "^2.1", - "phan/phan": "^1.3", - "phploc/phploc": "^4.0", - "phpmetrics/phpmetrics": "^2.4", - "phpunit/phpunit": "^7", - "roave/better-reflection": "dev-master#c87d856" - }, - "time": "2020-01-08T19:03:03+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "classmap": [ - "sources" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "Apache-2.0" - ], - "authors": [ - { - "name": "dallgoot", - "email": "stephane.rebai@gmail.com" - } - ], - "description": "Provides loader, dumper and an API for YAML content. Loader builds to equivalent data types in PHP 7.x", - "homepage": "https://github.com/dallgoot/yaml", - "keywords": [ - "parser", - "yaml" - ] - }, - { - "name": "goat1000/svggraph", - "version": "3.10.0", - "version_normalized": "3.10.0.0", - "source": { - "type": "git", - "url": "https://github.com/goat1000/SVGGraph.git", - "reference": "e97249ce511b20650b82e4df178c0ec2ea4db20c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/goat1000/SVGGraph/zipball/e97249ce511b20650b82e4df178c0ec2ea4db20c", - "reference": "e97249ce511b20650b82e4df178c0ec2ea4db20c", - "shasum": "" - }, - "require": { - "ext-json": "*", - "lib-pcre": "*", - "php": ">=5.4.0" - }, - "suggest": { - "ext-iconv": "For non-ASCII text measurement support" - }, - "time": "2021-07-19T14:38:40+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "Goat1000\\SVGGraph\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-only" - ], - "description": "Generates SVG graphs", - "homepage": "http://www.goat1000.com/svggraph.php" - } -] diff --git a/classes/vendor/dallgoot/yaml/CHANGELOG.md b/classes/vendor/dallgoot/yaml/CHANGELOG.md index b1c0cab..4c51ec6 100644 --- a/classes/vendor/dallgoot/yaml/CHANGELOG.md +++ b/classes/vendor/dallgoot/yaml/CHANGELOG.md @@ -1,9 +1,30 @@ # Changelog + All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [Unreleased] -Actual version is not stable enough, nor finished, nor fully tested to be used in production +## 0.9.0.0 + +### Changed + +- minimum PHP version supported is now 8.1.14 +- autoloading for PSR-4 (sorry to have polluted autoloads files worldwide 😢) +- parsing in NodeFactory +- logic in Dallgoot\Yaml\Dumper + +### Removed + +- support for PHP before 8.1.14 +- some dev dependencies +- Dallgoot\Yaml class replaced by Dallgoot\Yaml\Yaml + +### Fixed + +- PHP Notice reported by in +- dumping bug in Dallgoot\Yaml\DumperHandlers reported by in > + +## 0.3.2.0 +this version is not stable enough, nor finished, nor fully tested to be used in production, please prefer the 1.0.0 diff --git a/classes/vendor/dallgoot/yaml/README.md b/classes/vendor/dallgoot/yaml/README.md index 71f401a..42fc084 100644 --- a/classes/vendor/dallgoot/yaml/README.md +++ b/classes/vendor/dallgoot/yaml/README.md @@ -1,6 +1,6 @@ -# Dallgoot : YAML library for PHP - Beta !!! +# Dallgoot : YAML library for PHP - Beta -[![Build Status](https://travis-ci.org/dallgoot/yaml.svg?branch=master)](https://travis-ci.org/dallgoot/yaml) [![PHP from Packagist](https://img.shields.io/packagist/php-v/dallgoot/yaml)](https://packagist.org/packages/dallgoot/yaml) [![Packagist](https://img.shields.io/packagist/dt/dallgoot/yaml)](https://packagist.org/packages/dallgoot/yaml) +[![Build Status](https://api.travis-ci.com/dallgoot/yaml.svg?branch=master)](https://travis-ci.org/dallgoot/yaml) [![PHP from Packagist](https://img.shields.io/packagist/php-v/dallgoot/yaml)](https://packagist.org/packages/dallgoot/yaml) [![Packagist](https://img.shields.io/packagist/dt/dallgoot/yaml)](https://packagist.org/packages/dallgoot/yaml) [![Maintainability](https://api.codeclimate.com/v1/badges/dfae4b8e665a1d728e3d/maintainability)](https://codeclimate.com/github/dallgoot/yaml/maintainability) [![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/dallgoot/yaml/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/dallgoot/yaml/?branch=master) [![Code Coverage](https://scrutinizer-ci.com/g/dallgoot/yaml/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/dallgoot/yaml/?branch=master) @@ -12,7 +12,7 @@ PHP library to load and parse YAML file to coherent PHP datatypes equivalent - Dependencies are only useful for building documentation or for code contribution, so the "--update-no-dev" prevent from downloading and managing packages that you probably won't use. -You first need [Composer](https://getcomposer.org/) and PHP ^7.1.10 +You first need [Composer](https://getcomposer.org/) and PHP ^8.1.14 ```bash composer require --update-no-dev dallgoot/yaml @@ -20,9 +20,9 @@ composer require --update-no-dev dallgoot/yaml ## Usage -See examples files in [examples folder](./examples) +See [examples folder](./examples) -## Features: +## Features - *consistent* PHP datatypes : - object for mappings @@ -30,23 +30,23 @@ See examples files in [examples folder](./examples) - common scalars : string, integer, float, INF, NAN - JSON, DateTime(option), etc. - specific types (objects) - - **YamlObject** for each Yaml content (inherits from PHP class ArrayIterator) - - **Compact** for compact/short YAML syntax (inherits from PHP class ArrayIterator) + - **YamlObject** for each Yaml content (multi-documents YAML is an array of YamlObject) + - **Compact** for compact/short YAML syntax - **Tagged** object when tag is not determinable - recover from some parsing errors - tolerant to tabulations - debug levels : - 1 : print each line Node Type class and exit - - 2 : print Loader global map structure and exit + - 2 : print Loader global tree structure and exit - 3 : print each document NodeList and exit -## Support: +## Support - YAML specifications [version 1.2](http://yaml.org/spec/1.2/spec.html) - multi-line values (simple|double quoted or not, compact mapping|sequence or JSON) - multiple documents in a content (file or string) - compact syntax for mappings and sequences -- comments (option : enabled by default) +- comments (not yet implemented) - references (option : enabled by default) - tags with behaviour customization (overriding for common(CoreSchema), or specifying for custom) via implementing Tag/SchemaInterface. @@ -54,14 +54,14 @@ See examples files in [examples folder](./examples) | | YAML version supported | coherent data types | multiple documents | JSON format validation | complex mapping | real reference behaviour | custom tags handling | | -------------------------------------------------------------------- |:----------------------:|:-------------------:|:------------------:|:----------------------:|:---------------:|:------------------------:|:--------------------:| -| [Symfony Yaml](https://symfony.com/doc/current/components/yaml.html) | 1.2 | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | -| [php-yaml](https://pecl.php.net/package/yaml) | 1.1 | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | +| [Symfony Yaml](https://symfony.com/doc/current/components/yaml.html) | 1.2 | ❌ | ❌ | ❌ | ❌ | ❌ | ✔️ | +| [php-yaml](https://pecl.php.net/package/yaml) | 1.1 | ❌ | ✔️ | ❌ | ❌ | ❌ | ✔️ | | [syck](http://pecl.php.net/package/syck) | 1.0 | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | | [spyc](https://github.com/mustangostang/spyc) | 1.0 | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | | **Dallgoot/Yaml** | 1.2 | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | - coherent data types (see [coherence.md](./documentation/coherence.md) for explanations) -- JSON format validation (Option, Note: if valid as per PHP function *json_encode*) +- JSON format validation (Option, Note: if valid as per PHP function [json_encode](https://www.php.net/manual/en/function.json-encode.php)) - complex mapping (Note: keys are JSON formatted strings) - real reference behaviour : changing reference value modify other reference calls @@ -87,13 +87,18 @@ See examples files in [examples folder](./examples) - OPTION: Force renaming key names that are not valid PHP property name - TAG : function for 'php/object' that provides the correct namespace to build - NEON compatibility??? +- make immutable YamlObject ## Performances - TBD + - TBD + - improved memory using SplFixedArray instead of regular arrays where possible + +## Sponsor +That is greatly appreciated : Buy Me A Coffee ## Thanks -- (https://yaml.org) -- (https://www.json2yaml.com/convert-yaml-to-json) +- https://yaml.org +- https://www.json2yaml.com/convert-yaml-to-json - [Symfony Yaml](https://symfony.com/doc/current/components/yaml.html) diff --git a/classes/vendor/dallgoot/yaml/composer.json b/classes/vendor/dallgoot/yaml/composer.json index 939c797..b54b649 100644 --- a/classes/vendor/dallgoot/yaml/composer.json +++ b/classes/vendor/dallgoot/yaml/composer.json @@ -1,8 +1,13 @@ { "name": "dallgoot/yaml", - "description": "Provides loader, dumper and an API for YAML content. Loader builds to equivalent data types in PHP 7.x", + "description": "Provides loader, dumper and an API for YAML content. Loader builds to equivalent data types in PHP 8.x", "type": "library", - "keywords": ["yaml", "parser"], + "keywords": [ + "yaml", + "parser", + "reader", + "writer" + ], "homepage": "https://github.com/dallgoot/yaml", "license": "Apache-2.0", "authors": [ @@ -11,22 +16,18 @@ "email": "stephane.rebai@gmail.com" } ], - "autoload": { - "classmap": [ - "sources" - ] + "autoload": { + "psr-4": { + "Dallgoot\\Yaml\\": "src/" + } }, - "autoload-dev": { - "classmap": [ - "tests/CasesTest.php", - "tests/DumpingTest.php", - "tests/SymfonyYamlTest.php", - "tests/units", - "vendor/phpunit" - ] + "autoload-dev": { + "psr-4": { + "Dallgoot\\Yaml\\Tests\\": "tests/" + } }, "require": { - "php": ">=7.1.10", + "php": ">=8.1.14", "ext-json": "*", "ext-pcre": "*", "ext-SPL": "*", @@ -34,19 +35,14 @@ }, "require-dev": { "ext-Reflection": "*", - "phan/phan": "^1.3", - "roave/better-reflection": "dev-master#c87d856", - "composer/xdebug-handler": "^1.3", - "phploc/phploc": "^4.0", - "paulthebaud/phpunit-generator": "^2.1", - "phpmetrics/phpmetrics": "^2.4", - "phpunit/phpunit": "^7" + "phan/phan": "*", + "phpmetrics/phpmetrics": "*", + "phpunit/phpunit": "*" }, - "scripts" : { - "test" : "phpunit --verbose --configuration ./configuration/phpunit.xml --testsuite All", - "metrics" : "phpmetrics --report-html=documentation/phpmetrics_report ./sources", - "phploc" : "phploc sources/ --count-tests --log-xml=./documentation/codecoverage/phploc.xml", - "docs" : "phpdox -f configuration/phpdox.xml", - "phan" : "phan -k configuration/phan.php -C -j2 -3sources/tag" + "scripts": { + "test": "phpunit -c ./configuration/phpunit.xml --no-coverage --testsuite All", + "coverage": "XDEBUG_MODE=coverage phpunit -c ./configuration/phpunit.xml --testsuite All", + "metrics": "phpmetrics --report-html=documentation/phpmetrics_report ./src", + "phan": "phan -k configuration/phan.php -C -j2 -3src/Tag" } -} +} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/composer.lock b/classes/vendor/dallgoot/yaml/composer.lock index 49749fd..b583855 100644 --- a/classes/vendor/dallgoot/yaml/composer.lock +++ b/classes/vendor/dallgoot/yaml/composer.lock @@ -4,39 +4,40 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4e98852568c21ec649eef558886bcb85", + "content-hash": "99e92f298d7c52a0955d879093380722", "packages": [], "packages-dev": [ { - "name": "composer/semver", - "version": "1.5.0", + "name": "composer/pcre", + "version": "3.1.0", "source": { "type": "git", - "url": "https://github.com/composer/semver.git", - "reference": "46d9139568ccb8d9e7cdd4539cab7347568a5e2e" + "url": "https://github.com/composer/pcre.git", + "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/46d9139568ccb8d9e7cdd4539cab7347568a5e2e", - "reference": "46d9139568ccb8d9e7cdd4539cab7347568a5e2e", + "url": "https://api.github.com/repos/composer/pcre/zipball/4bff79ddd77851fe3cdd11616ed3f92841ba5bd2", + "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2", "shasum": "" }, "require": { - "php": "^5.3.2 || ^7.0" + "php": "^7.4 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "^4.5 || ^5.0.5", - "phpunit/phpunit-mock-objects": "2.3.0 || ^3.0" + "phpstan/phpstan": "^1.3", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { "psr-4": { - "Composer\\Semver\\": "src" + "Composer\\Pcre\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -44,107 +45,69 @@ "MIT" ], "authors": [ - { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, { "name": "Jordi Boggiano", "email": "j.boggiano@seld.be", "homepage": "http://seld.be" - }, - { - "name": "Rob Bast", - "email": "rob.bast@gmail.com", - "homepage": "http://robbast.nl" } ], - "description": "Semver library that offers utilities, version constraint parsing and validation.", + "description": "PCRE wrapping library that offers type-safe preg_* replacements.", "keywords": [ - "semantic", - "semver", - "validation", - "versioning" + "PCRE", + "preg", + "regex", + "regular expression" ], - "time": "2019-03-19T17:25:45+00:00" - }, - { - "name": "composer/xdebug-handler", - "version": "1.4.0", - "source": { - "type": "git", - "url": "https://github.com/composer/xdebug-handler.git", - "reference": "cbe23383749496fe0f373345208b79568e4bc248" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/cbe23383749496fe0f373345208b79568e4bc248", - "reference": "cbe23383749496fe0f373345208b79568e4bc248", - "shasum": "" - }, - "require": { - "php": "^5.3.2 || ^7.0 || ^8.0", - "psr/log": "^1.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" + "support": { + "issues": "https://github.com/composer/pcre/issues", + "source": "https://github.com/composer/pcre/tree/3.1.0" }, - "type": "library", - "autoload": { - "psr-4": { - "Composer\\XdebugHandler\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ + "funding": [ { - "name": "John Stevenson", - "email": "john-stevenson@blueyonder.co.uk" + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" } ], - "description": "Restarts a process without Xdebug.", - "keywords": [ - "Xdebug", - "performance" - ], - "time": "2019-11-06T16:40:04+00:00" + "time": "2022-11-17T09:50:14+00:00" }, { - "name": "doctrine/collections", - "version": "v1.6.2", + "name": "composer/semver", + "version": "3.3.2", "source": { "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "c5e0bc17b1620e97c968ac409acbff28b8b850be" + "url": "https://github.com/composer/semver.git", + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/c5e0bc17b1620e97c968ac409acbff28b8b850be", - "reference": "c5e0bc17b1620e97c968ac409acbff28b8b850be", + "url": "https://api.github.com/repos/composer/semver/zipball/3953f23262f2bff1919fc82183ad9acb13ff62c9", + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9", "shasum": "" }, "require": { - "php": "^7.1.3" + "php": "^5.3.2 || ^7.0 || ^8.0" }, "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan-shim": "^0.9.2", - "phpunit/phpunit": "^7.0", - "vimeo/psalm": "^3.2.2" + "phpstan/phpstan": "^1.4", + "symfony/phpunit-bridge": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.6.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { "psr-4": { - "Doctrine\\Common\\Collections\\": "lib/Doctrine/Common/Collections" + "Composer\\Semver\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -153,71 +116,77 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" }, { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" }, { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } + ], + "description": "Semver library that offers utilities, version constraint parsing and validation.", + "keywords": [ + "semantic", + "semver", + "validation", + "versioning" + ], + "support": { + "irc": "irc://irc.freenode.org/composer", + "issues": "https://github.com/composer/semver/issues", + "source": "https://github.com/composer/semver/tree/3.3.2" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" }, { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" + "url": "https://github.com/composer", + "type": "github" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" } ], - "description": "PHP Doctrine Collections library that adds additional functionality on top of PHP arrays.", - "homepage": "https://www.doctrine-project.org/projects/collections.html", - "keywords": [ - "array", - "collections", - "iterators", - "php" - ], - "time": "2019-06-09T13:48:14+00:00" + "time": "2022-04-01T19:23:25+00:00" }, { - "name": "doctrine/instantiator", - "version": "1.3.0", + "name": "composer/xdebug-handler", + "version": "3.0.3", "source": { "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" + "url": "https://github.com/composer/xdebug-handler.git", + "reference": "ced299686f41dce890debac69273b47ffe98a40c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c", + "reference": "ced299686f41dce890debac69273b47ffe98a40c", "shasum": "" }, "require": { - "php": "^7.1" + "composer/pcre": "^1 || ^2 || ^3", + "php": "^7.2.5 || ^8.0", + "psr/log": "^1 || ^2 || ^3" }, "require-dev": { - "doctrine/coding-standard": "^6.0", - "ext-pdo": "*", - "ext-phar": "*", - "phpbench/phpbench": "^0.13", - "phpstan/phpstan-phpunit": "^0.11", - "phpstan/phpstan-shim": "^0.11", - "phpunit/phpunit": "^7.0" + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^6.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, "autoload": { "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + "Composer\\XdebugHandler\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -226,269 +195,143 @@ ], "authors": [ { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" + "name": "John Stevenson", + "email": "john-stevenson@blueyonder.co.uk" } ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://www.doctrine-project.org/projects/instantiator.html", + "description": "Restarts a process without Xdebug.", "keywords": [ - "constructor", - "instantiate" + "Xdebug", + "performance" ], - "time": "2019-10-21T16:45:58+00:00" - }, - { - "name": "doctrine/lexer", - "version": "1.1.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "e17f069ede36f7534b95adec71910ed1b49c74ea" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/e17f069ede36f7534b95adec71910ed1b49c74ea", - "reference": "e17f069ede36f7534b95adec71910ed1b49c74ea", - "shasum": "" - }, - "require": { - "php": "^7.2" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan": "^0.11.8", - "phpunit/phpunit": "^8.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Lexer\\": "lib/Doctrine/Common/Lexer" - } + "support": { + "irc": "irc://irc.freenode.org/composer", + "issues": "https://github.com/composer/xdebug-handler/issues", + "source": "https://github.com/composer/xdebug-handler/tree/3.0.3" }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ + "funding": [ { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "url": "https://packagist.com", + "type": "custom" }, { - "name": "Roman Borschel", - "email": "roman@code-factory.org" + "url": "https://github.com/composer", + "type": "github" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" } ], - "description": "PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.", - "homepage": "https://www.doctrine-project.org/projects/lexer.html", - "keywords": [ - "annotations", - "docblock", - "lexer", - "parser", - "php" - ], - "time": "2019-07-30T19:33:28+00:00" + "time": "2022-02-25T21:32:43+00:00" }, { - "name": "felixfbecker/advanced-json-rpc", - "version": "v3.0.4", + "name": "doctrine/deprecations", + "version": "v1.0.0", "source": { "type": "git", - "url": "https://github.com/felixfbecker/php-advanced-json-rpc.git", - "reference": "23366dd0cab0a0f3fd3016bf3c0b36dec74348e7" + "url": "https://github.com/doctrine/deprecations.git", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/felixfbecker/php-advanced-json-rpc/zipball/23366dd0cab0a0f3fd3016bf3c0b36dec74348e7", - "reference": "23366dd0cab0a0f3fd3016bf3c0b36dec74348e7", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", "shasum": "" }, "require": { - "netresearch/jsonmapper": "^1.0", - "php": ">=7.0", - "phpdocumentor/reflection-docblock": "^4.0.0" + "php": "^7.1|^8.0" }, "require-dev": { - "phpunit/phpunit": "^6.0.0" + "doctrine/coding-standard": "^9", + "phpunit/phpunit": "^7.5|^8.5|^9.5", + "psr/log": "^1|^2|^3" + }, + "suggest": { + "psr/log": "Allows logging deprecations via PSR-3 logger implementation" }, "type": "library", "autoload": { "psr-4": { - "AdvancedJsonRpc\\": "lib/" + "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "ISC" - ], - "authors": [ - { - "name": "Felix Becker", - "email": "felix.b@outlook.com" - } + "MIT" ], - "description": "A more advanced JSONRPC implementation", - "time": "2019-09-12T22:41:08+00:00" - }, - { - "name": "jetbrains/phpstorm-stubs", - "version": "v2019.2", - "source": { - "type": "git", - "url": "https://github.com/JetBrains/phpstorm-stubs.git", - "reference": "0eb16807e8406e775ef602974b104454fc7ffb5c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/JetBrains/phpstorm-stubs/zipball/0eb16807e8406e775ef602974b104454fc7ffb5c", - "reference": "0eb16807e8406e775ef602974b104454fc7ffb5c", - "shasum": "" - }, - "require-dev": { - "nikic/php-parser": "v4.0.1", - "php": "^7.1", - "phpdocumentor/reflection-docblock": "^4.3", - "phpunit/phpunit": "7.1.4" - }, - "type": "library", - "autoload": { - "files": [ - "PhpStormStubsMap.php" - ] + "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", + "homepage": "https://www.doctrine-project.org/", + "support": { + "issues": "https://github.com/doctrine/deprecations/issues", + "source": "https://github.com/doctrine/deprecations/tree/v1.0.0" }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "Apache-2.0" - ], - "description": "PHP runtime & extensions header files for PhpStorm", - "homepage": "https://www.jetbrains.com/phpstorm", - "keywords": [ - "autocomplete", - "code", - "inference", - "inspection", - "jetbrains", - "phpstorm", - "stubs", - "type" - ], - "time": "2019-07-22T14:52:46+00:00" + "time": "2022-05-02T15:47:09+00:00" }, { - "name": "league/flysystem", - "version": "1.0.57", + "name": "felixfbecker/advanced-json-rpc", + "version": "v3.2.1", "source": { "type": "git", - "url": "https://github.com/thephpleague/flysystem.git", - "reference": "0e9db7f0b96b9f12dcf6f65bc34b72b1a30ea55a" + "url": "https://github.com/felixfbecker/php-advanced-json-rpc.git", + "reference": "b5f37dbff9a8ad360ca341f3240dc1c168b45447" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/0e9db7f0b96b9f12dcf6f65bc34b72b1a30ea55a", - "reference": "0e9db7f0b96b9f12dcf6f65bc34b72b1a30ea55a", + "url": "https://api.github.com/repos/felixfbecker/php-advanced-json-rpc/zipball/b5f37dbff9a8ad360ca341f3240dc1c168b45447", + "reference": "b5f37dbff9a8ad360ca341f3240dc1c168b45447", "shasum": "" }, "require": { - "ext-fileinfo": "*", - "php": ">=5.5.9" - }, - "conflict": { - "league/flysystem-sftp": "<1.0.6" + "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", + "php": "^7.1 || ^8.0", + "phpdocumentor/reflection-docblock": "^4.3.4 || ^5.0.0" }, "require-dev": { - "phpspec/phpspec": "^3.4", - "phpunit/phpunit": "^5.7.10" - }, - "suggest": { - "ext-fileinfo": "Required for MimeType", - "ext-ftp": "Allows you to use FTP server storage", - "ext-openssl": "Allows you to use FTPS server storage", - "league/flysystem-aws-s3-v2": "Allows you to use S3 storage with AWS SDK v2", - "league/flysystem-aws-s3-v3": "Allows you to use S3 storage with AWS SDK v3", - "league/flysystem-azure": "Allows you to use Windows Azure Blob storage", - "league/flysystem-cached-adapter": "Flysystem adapter decorator for metadata caching", - "league/flysystem-eventable-filesystem": "Allows you to use EventableFilesystem", - "league/flysystem-rackspace": "Allows you to use Rackspace Cloud Files", - "league/flysystem-sftp": "Allows you to use SFTP server storage via phpseclib", - "league/flysystem-webdav": "Allows you to use WebDAV storage", - "league/flysystem-ziparchive": "Allows you to use ZipArchive adapter", - "spatie/flysystem-dropbox": "Allows you to use Dropbox storage", - "srmklive/flysystem-dropbox-v2": "Allows you to use Dropbox storage for PHP 5 applications" + "phpunit/phpunit": "^7.0 || ^8.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1-dev" - } - }, "autoload": { "psr-4": { - "League\\Flysystem\\": "src/" + "AdvancedJsonRpc\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "ISC" ], "authors": [ { - "name": "Frank de Jonge", - "email": "info@frenky.net" + "name": "Felix Becker", + "email": "felix.b@outlook.com" } ], - "description": "Filesystem abstraction: Many filesystems, one API.", - "keywords": [ - "Cloud Files", - "WebDAV", - "abstraction", - "aws", - "cloud", - "copy.com", - "dropbox", - "file systems", - "files", - "filesystem", - "filesystems", - "ftp", - "rackspace", - "remote", - "s3", - "sftp", - "storage" - ], - "time": "2019-10-16T21:01:05+00:00" + "description": "A more advanced JSONRPC implementation", + "support": { + "issues": "https://github.com/felixfbecker/php-advanced-json-rpc/issues", + "source": "https://github.com/felixfbecker/php-advanced-json-rpc/tree/v3.2.1" + }, + "time": "2021-06-11T22:34:44+00:00" }, { "name": "microsoft/tolerant-php-parser", - "version": "v0.0.17", + "version": "v0.1.2", "source": { "type": "git", - "url": "https://github.com/Microsoft/tolerant-php-parser.git", - "reference": "89386de8dec9c004c8ea832692e236c92f34b542" + "url": "https://github.com/microsoft/tolerant-php-parser.git", + "reference": "3eccfd273323aaf69513e2f1c888393f5947804b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Microsoft/tolerant-php-parser/zipball/89386de8dec9c004c8ea832692e236c92f34b542", - "reference": "89386de8dec9c004c8ea832692e236c92f34b542", + "url": "https://api.github.com/repos/microsoft/tolerant-php-parser/zipball/3eccfd273323aaf69513e2f1c888393f5947804b", + "reference": "3eccfd273323aaf69513e2f1c888393f5947804b", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.2" }, "require-dev": { - "phpunit/phpunit": "^6.4" + "phpunit/phpunit": "^8.5.15" }, "type": "library", "autoload": { @@ -509,41 +352,46 @@ } ], "description": "Tolerant PHP-to-AST parser designed for IDE usage scenarios", - "time": "2019-03-09T19:24:59+00:00" + "support": { + "issues": "https://github.com/microsoft/tolerant-php-parser/issues", + "source": "https://github.com/microsoft/tolerant-php-parser/tree/v0.1.2" + }, + "time": "2022-10-05T17:30:19+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.9.3", + "version": "1.11.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "007c053ae6f31bba39dfa19a7726f56e9763bbea" + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/007c053ae6f31bba39dfa19a7726f56e9763bbea", - "reference": "007c053ae6f31bba39dfa19a7726f56e9763bbea", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.1 || ^8.0" }, - "replace": { - "myclabs/deep-copy": "self.version" + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" }, "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, "files": [ "src/DeepCopy/deep_copy.php" - ] + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -557,20 +405,30 @@ "object", "object graph" ], - "time": "2019-08-09T12:45:53+00:00" + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2023-03-08T13:26:56+00:00" }, { "name": "netresearch/jsonmapper", - "version": "v1.6.0", + "version": "v4.1.0", "source": { "type": "git", "url": "https://github.com/cweiske/jsonmapper.git", - "reference": "0d4d1b48d682a93b6bfedf60b88c7750e9cb0b06" + "reference": "cfa81ea1d35294d64adb9c68aa4cb9e92400e53f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/cweiske/jsonmapper/zipball/0d4d1b48d682a93b6bfedf60b88c7750e9cb0b06", - "reference": "0d4d1b48d682a93b6bfedf60b88c7750e9cb0b06", + "url": "https://api.github.com/repos/cweiske/jsonmapper/zipball/cfa81ea1d35294d64adb9c68aa4cb9e92400e53f", + "reference": "cfa81ea1d35294d64adb9c68aa4cb9e92400e53f", "shasum": "" }, "require": { @@ -578,11 +436,11 @@ "ext-pcre": "*", "ext-reflection": "*", "ext-spl": "*", - "php": ">=5.6" + "php": ">=7.1" }, "require-dev": { - "phpunit/phpunit": "~4.8.35 || ~5.7 || ~6.4", - "squizlabs/php_codesniffer": "~1.5" + "phpunit/phpunit": "~7.5 || ~8.0 || ~9.0", + "squizlabs/php_codesniffer": "~3.5" }, "type": "library", "autoload": { @@ -597,26 +455,31 @@ "authors": [ { "name": "Christian Weiske", - "role": "Developer", "email": "cweiske@cweiske.de", - "homepage": "http://github.com/cweiske/jsonmapper/" + "homepage": "http://github.com/cweiske/jsonmapper/", + "role": "Developer" } ], "description": "Map nested JSON structures onto PHP classes", - "time": "2019-08-15T19:41:25+00:00" + "support": { + "email": "cweiske@cweiske.de", + "issues": "https://github.com/cweiske/jsonmapper/issues", + "source": "https://github.com/cweiske/jsonmapper/tree/v4.1.0" + }, + "time": "2022-12-08T20:46:14+00:00" }, { "name": "nikic/php-parser", - "version": "v4.2.5", + "version": "v4.15.4", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "b76bbc3c51f22c570648de48e8c2d941ed5e2cf2" + "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/b76bbc3c51f22c570648de48e8c2d941ed5e2cf2", - "reference": "b76bbc3c51f22c570648de48e8c2d941ed5e2cf2", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/6bb5176bc4af8bcb7d926f88718db9b96a2d4290", + "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290", "shasum": "" }, "require": { @@ -624,8 +487,8 @@ "php": ">=7.0" }, "require-dev": { - "ircmaxell/php-yacc": "0.0.4", - "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0" + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" }, "bin": [ "bin/php-parse" @@ -633,7 +496,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "4.9-dev" } }, "autoload": { @@ -655,107 +518,52 @@ "parser", "php" ], - "time": "2019-10-25T18:33:07+00:00" - }, - { - "name": "paulthebaud/phpunit-generator", - "version": "2.1.5", - "source": { - "type": "git", - "url": "https://github.com/paul-thebaud/phpunit-generator.git", - "reference": "24ca729900187279ff4f83ef0bda0af72cc7c92e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/paul-thebaud/phpunit-generator/zipball/24ca729900187279ff4f83ef0bda0af72cc7c92e", - "reference": "24ca729900187279ff4f83ef0bda0af72cc7c92e", - "shasum": "" - }, - "require": { - "doctrine/collections": "^1.5", - "doctrine/lexer": "^1.0", - "league/flysystem": "^1.0", - "nikic/php-parser": "^4.0", - "php": "~7.1", - "psr/container": "^1.0.0", - "respect/validation": "^1.1", - "slim/php-view": "^2.2", - "symfony/console": "^4.0", - "symfony/stopwatch": "^4.0", - "symfony/yaml": "^4.0" - }, - "require-dev": { - "php-coveralls/php-coveralls": "^2.1", - "phploc/phploc": "^4.0", - "phpunit/phpunit": "^8.0|^7.0", - "squizlabs/php_codesniffer": "^3.0" - }, - "bin": [ - "phpunitgen" - ], - "type": "library", - "autoload": { - "psr-4": { - "PhpUnitGen\\": "src/" - } + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.4" }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Paul Thébaud", - "email": "paul.thebaud29@gmail.com" - } - ], - "description": "A PHPUnit 6 / 7 tests skeletons generator", - "homepage": "https://github.com/paul-thebaud/phpunit-generator", - "keywords": [ - "PHP7", - "generator", - "php", - "phpunit", - "test", - "tests", - "unit" - ], - "time": "2019-03-02T19:14:20+00:00" + "time": "2023-03-05T19:49:14+00:00" }, { "name": "phan/phan", - "version": "1.3.5", + "version": "5.4.2", "source": { "type": "git", "url": "https://github.com/phan/phan.git", - "reference": "f872949b366d84bd9ce79d8b0ea991edbe258377" + "reference": "4f2870ed6fea320f62f3c3c63f3274d357a7980e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phan/phan/zipball/f872949b366d84bd9ce79d8b0ea991edbe258377", - "reference": "f872949b366d84bd9ce79d8b0ea991edbe258377", + "url": "https://api.github.com/repos/phan/phan/zipball/4f2870ed6fea320f62f3c3c63f3274d357a7980e", + "reference": "4f2870ed6fea320f62f3c3c63f3274d357a7980e", "shasum": "" }, "require": { - "composer/semver": "^1.4", - "composer/xdebug-handler": "^1.3.2", + "composer/semver": "^1.4|^2.0|^3.0", + "composer/xdebug-handler": "^2.0|^3.0", "ext-filter": "*", "ext-json": "*", - "felixfbecker/advanced-json-rpc": "^3.0.3", - "microsoft/tolerant-php-parser": "0.0.17", - "php": "^7.0.0", - "sabre/event": "^5.0", - "symfony/console": "^2.3|^3.0|~4.0", - "symfony/polyfill-mbstring": "^1.11.0" + "ext-tokenizer": "*", + "felixfbecker/advanced-json-rpc": "^3.0.4", + "microsoft/tolerant-php-parser": "0.1.2", + "netresearch/jsonmapper": "^1.6.0|^2.0|^3.0|^4.0", + "php": "^7.2.0|^8.0.0", + "sabre/event": "^5.1.3", + "symfony/console": "^3.2|^4.0|^5.0|^6.0", + "symfony/polyfill-mbstring": "^1.11.0", + "symfony/polyfill-php80": "^1.20.0", + "tysonandre/var_representation_polyfill": "^0.0.2|^0.1.0" }, "require-dev": { - "brianium/paratest": "^1.1", - "phpunit/phpunit": "^6.3.0" + "phpunit/phpunit": "^8.5.0" }, "suggest": { - "ext-ast": "Needed for parsing ASTs (unless --use-fallback-parser is used). 1.0.1+ is recommended, php-ast ^0.1.5|^1.0.0 is needed.", + "ext-ast": "Needed for parsing ASTs (unless --use-fallback-parser is used). 1.0.1+ is needed, 1.0.16+ is recommended.", + "ext-iconv": "Either iconv or mbstring is needed to ensure issue messages are valid utf-8", "ext-igbinary": "Improves performance of polyfill when ext-ast is unavailable", - "ext-tokenizer": "Needed for non-AST support and file/line-based suppressions." + "ext-mbstring": "Either iconv or mbstring is needed to ensure issue messages are valid utf-8", + "ext-tokenizer": "Needed for fallback/polyfill parser support and file/line-based suppressions.", + "ext-var_representation": "Suggested for converting values to strings in issue messages" }, "bin": [ "phan", @@ -774,13 +582,13 @@ ], "authors": [ { - "name": "Rasmus Lerdorf" + "name": "Tyson Andre" }, { - "name": "Andrew S. Morrison" + "name": "Rasmus Lerdorf" }, { - "name": "Tyson Andre" + "name": "Andrew S. Morrison" } ], "description": "A static analyzer for PHP", @@ -789,32 +597,37 @@ "php", "static" ], - "time": "2019-05-23T00:25:02+00:00" + "support": { + "issues": "https://github.com/phan/phan/issues", + "source": "https://github.com/phan/phan/tree/5.4.2" + }, + "time": "2023-03-03T17:20:24+00:00" }, { "name": "phar-io/manifest", - "version": "1.0.3", + "version": "2.0.3", "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4" + "reference": "97803eca37d319dfa7826cc2437fc020857acb53" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/97803eca37d319dfa7826cc2437fc020857acb53", + "reference": "97803eca37d319dfa7826cc2437fc020857acb53", "shasum": "" }, "require": { "ext-dom": "*", "ext-phar": "*", - "phar-io/version": "^2.0", - "php": "^5.6 || ^7.0" + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -844,24 +657,28 @@ } ], "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", - "time": "2018-07-08T19:23:20+00:00" + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/2.0.3" + }, + "time": "2021-07-20T11:28:43+00:00" }, { "name": "phar-io/version", - "version": "2.0.1", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6" + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": "^7.2 || ^8.0" }, "type": "library", "autoload": { @@ -891,32 +708,33 @@ } ], "description": "Library for handling version information and constraints", - "time": "2018-07-08T19:19:57+00:00" + "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": "phpdocumentor/reflection-common", - "version": "2.0.0", + "version": "2.2.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a" + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/63a995caa1ca9e5590304cd845c15ad6d482a62a", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/1d01c49d4ed62f25aa84a747ad35d5a16924662b", + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b", "shasum": "" }, "require": { - "php": ">=7.1" - }, - "require-dev": { - "phpunit/phpunit": "~6" + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.x-dev" + "dev-2.x": "2.x-dev" } }, "autoload": { @@ -943,44 +761,46 @@ "reflection", "static analysis" ], - "time": "2018-08-07T13:53:10+00:00" + "support": { + "issues": "https://github.com/phpDocumentor/ReflectionCommon/issues", + "source": "https://github.com/phpDocumentor/ReflectionCommon/tree/2.x" + }, + "time": "2020-06-27T09:03:43+00:00" }, { "name": "phpdocumentor/reflection-docblock", - "version": "4.3.2", + "version": "5.3.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "b83ff7cfcfee7827e1e78b637a5904fe6a96698e" + "reference": "622548b623e81ca6d78b721c5e029f4ce664f170" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/b83ff7cfcfee7827e1e78b637a5904fe6a96698e", - "reference": "b83ff7cfcfee7827e1e78b637a5904fe6a96698e", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/622548b623e81ca6d78b721c5e029f4ce664f170", + "reference": "622548b623e81ca6d78b721c5e029f4ce664f170", "shasum": "" }, "require": { - "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0.0 || ^2.0.0", - "phpdocumentor/type-resolver": "~0.4 || ^1.0.0", - "webmozart/assert": "^1.0" + "ext-filter": "*", + "php": "^7.2 || ^8.0", + "phpdocumentor/reflection-common": "^2.2", + "phpdocumentor/type-resolver": "^1.3", + "webmozart/assert": "^1.9.1" }, "require-dev": { - "doctrine/instantiator": "^1.0.5", - "mockery/mockery": "^1.0", - "phpunit/phpunit": "^6.4" + "mockery/mockery": "~1.3.2", + "psalm/phar": "^4.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev" + "dev-master": "5.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "phpDocumentor\\Reflection\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -991,38 +811,53 @@ { "name": "Mike van Riel", "email": "me@mikevanriel.com" + }, + { + "name": "Jaap van Otterdijk", + "email": "account@ijaap.nl" } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2019-09-12T14:27:41+00:00" + "support": { + "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", + "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.3.0" + }, + "time": "2021-10-19T17:43:47+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "1.0.1", + "version": "1.7.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9" + "reference": "dfc078e8af9c99210337325ff5aa152872c98714" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", - "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/dfc078e8af9c99210337325ff5aa152872c98714", + "reference": "dfc078e8af9c99210337325ff5aa152872c98714", "shasum": "" }, "require": { - "php": "^7.1", - "phpdocumentor/reflection-common": "^2.0" + "doctrine/deprecations": "^1.0", + "php": "^7.4 || ^8.0", + "phpdocumentor/reflection-common": "^2.0", + "phpstan/phpdoc-parser": "^1.13" }, "require-dev": { - "ext-tokenizer": "^7.1", - "mockery/mockery": "~1", - "phpunit/phpunit": "^7.0" + "ext-tokenizer": "*", + "phpbench/phpbench": "^1.2", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan": "^1.8", + "phpstan/phpstan-phpunit": "^1.1", + "phpunit/phpunit": "^9.5", + "rector/rector": "^0.13.9", + "vimeo/psalm": "^4.25" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.x-dev" + "dev-1.x": "1.x-dev" } }, "autoload": { @@ -1041,69 +876,24 @@ } ], "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", - "time": "2019-08-22T18:11:29+00:00" + "support": { + "issues": "https://github.com/phpDocumentor/TypeResolver/issues", + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.7.1" + }, + "time": "2023-03-27T19:02:04+00:00" }, { - "name": "phploc/phploc", - "version": "4.0.1", + "name": "phpmetrics/phpmetrics", + "version": "v2.8.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/phploc.git", - "reference": "6a8a9416517b82d6326ac9c2d040ad53c13654eb" + "url": "https://github.com/phpmetrics/PhpMetrics.git", + "reference": "4b77140a11452e63c7a9b98e0648320bf6710090" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phploc/zipball/6a8a9416517b82d6326ac9c2d040ad53c13654eb", - "reference": "6a8a9416517b82d6326ac9c2d040ad53c13654eb", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0", - "sebastian/finder-facade": "^1.1", - "sebastian/version": "^2.0", - "symfony/console": "^2.7|^3.0|^4.0" - }, - "bin": [ - "phploc" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "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": "A tool for quickly measuring the size of a PHP project.", - "homepage": "https://github.com/sebastianbergmann/phploc", - "time": "2017-11-18T17:35:43+00:00" - }, - { - "name": "phpmetrics/phpmetrics", - "version": "v2.4.1", - "source": { - "type": "git", - "url": "https://github.com/phpmetrics/PhpMetrics.git", - "reference": "39095017413805cd6d9ada16cfaf8aaffcb2fec4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpmetrics/PhpMetrics/zipball/39095017413805cd6d9ada16cfaf8aaffcb2fec4", - "reference": "39095017413805cd6d9ada16cfaf8aaffcb2fec4", + "url": "https://api.github.com/repos/phpmetrics/PhpMetrics/zipball/4b77140a11452e63c7a9b98e0648320bf6710090", + "reference": "4b77140a11452e63c7a9b98e0648320bf6710090", "shasum": "" }, "require": { @@ -1117,20 +907,22 @@ "halleck45/phpmetrics": "*" }, "require-dev": { - "phpunit/phpunit": ">=4.8.27,<=5.7.13", - "sebastian/comparator": ">=1.2.3" + "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14", + "sebastian/comparator": ">=1.2.3", + "squizlabs/php_codesniffer": "^3.5", + "symfony/dom-crawler": "^3.0 || ^4.0 || ^5.0" }, "bin": [ "bin/phpmetrics" ], "type": "library", "autoload": { - "psr-0": { - "Hal\\": "./src/" - }, "files": [ "./src/functions.php" - ] + ], + "psr-0": { + "Hal\\": "./src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1152,107 +944,97 @@ "quality", "testing" ], - "time": "2018-07-10T17:19:33+00:00" + "support": { + "issues": "https://github.com/PhpMetrics/PhpMetrics/issues", + "source": "https://github.com/phpmetrics/PhpMetrics/tree/v2.8.2" + }, + "time": "2023-03-08T15:03:36+00:00" }, { - "name": "phpspec/prophecy", - "version": "1.9.0", + "name": "phpstan/phpdoc-parser", + "version": "1.18.0", "source": { "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "f6811d96d97bdf400077a0cc100ae56aa32b9203" + "url": "https://github.com/phpstan/phpdoc-parser.git", + "reference": "882eabc9b6a12e25c27091a261397f9c8792e722" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/f6811d96d97bdf400077a0cc100ae56aa32b9203", - "reference": "f6811d96d97bdf400077a0cc100ae56aa32b9203", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/882eabc9b6a12e25c27091a261397f9c8792e722", + "reference": "882eabc9b6a12e25c27091a261397f9c8792e722", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0", - "sebastian/comparator": "^1.1|^2.0|^3.0", - "sebastian/recursion-context": "^1.0|^2.0|^3.0" + "php": "^7.2 || ^8.0" }, "require-dev": { - "phpspec/phpspec": "^2.5|^3.2", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1" + "php-parallel-lint/php-parallel-lint": "^1.2", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^1.5", + "phpstan/phpstan-phpunit": "^1.1", + "phpstan/phpstan-strict-rules": "^1.0", + "phpunit/phpunit": "^9.5", + "symfony/process": "^5.2" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.8.x-dev" - } - }, "autoload": { "psr-4": { - "Prophecy\\": "src/Prophecy" + "PHPStan\\PhpDocParser\\": [ + "src/" + ] } }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "time": "2019-10-03T11:07:50+00:00" + "description": "PHPDoc parser with support for nullable, intersection and generic types", + "support": { + "issues": "https://github.com/phpstan/phpdoc-parser/issues", + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.18.0" + }, + "time": "2023-04-06T07:26:43+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "6.1.4", + "version": "10.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" + "reference": "20800e84296ea4732f9a125e08ce86b4004ae3e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/20800e84296ea4732f9a125e08ce86b4004ae3e4", + "reference": "20800e84296ea4732f9a125e08ce86b4004ae3e4", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" + "nikic/php-parser": "^4.15", + "php": ">=8.1", + "phpunit/php-file-iterator": "^4.0", + "phpunit/php-text-template": "^3.0", + "sebastian/code-unit-reverse-lookup": "^3.0", + "sebastian/complexity": "^3.0", + "sebastian/environment": "^6.0", + "sebastian/lines-of-code": "^2.0", + "sebastian/version": "^4.0", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^10.0" }, "suggest": { - "ext-xdebug": "^2.6.0" + "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-master": "6.1-dev" + "dev-main": "10.0-dev" } }, "autoload": { @@ -1278,32 +1060,42 @@ "testing", "xunit" ], - "time": "2018-10-31T16:06:48+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-03-06T13:00:19+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "2.0.2", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "050bedf145a257b1ff02746c31894800e5122946" + "reference": "fd9329ab3368f59fe1fe808a189c51086bd4b6bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/050bedf145a257b1ff02746c31894800e5122946", - "reference": "050bedf145a257b1ff02746c31894800e5122946", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/fd9329ab3368f59fe1fe808a189c51086bd4b6bd", + "reference": "fd9329ab3368f59fe1fe808a189c51086bd4b6bd", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -1328,26 +1120,48 @@ "filesystem", "iterator" ], - "time": "2018-09-13T20:33:42+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/4.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-10T16:53:14+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "4.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=8.1" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^10.0" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-main": "4.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -1364,37 +1178,47 @@ "role": "lead" } ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", "keywords": [ - "template" + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/4.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2015-06-21T13:50:34+00:00" + "time": "2023-02-03T06:56:09+00:00" }, { - "name": "phpunit/php-timer", - "version": "2.1.2", + "name": "phpunit/php-text-template", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/9f3d3709577a527025f55bcf0f7ab8052c8bb37d", + "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -1413,38 +1237,47 @@ "role": "lead" } ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", + "description": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", "keywords": [ - "timer" + "template" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2019-06-07T04:22:29+00:00" + "time": "2023-02-03T06:56:46+00:00" }, { - "name": "phpunit/php-token-stream", - "version": "3.1.1", + "name": "phpunit/php-timer", + "version": "6.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/e2a2d67966e740530f4a3343fe2e030ffdc1161d", + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d", "shasum": "" }, "require": { - "ext-tokenizer": "*", - "php": "^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -1459,65 +1292,71 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", + "description": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", "keywords": [ - "tokenizer" + "timer" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/6.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2019-09-17T06:23:10+00:00" + "time": "2023-02-03T06:57:52+00:00" }, { "name": "phpunit/phpunit", - "version": "7.5.17", + "version": "10.0.19", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "4c92a15296e58191a4cd74cff3b34fc8e374174a" + "reference": "20c23e85c86e5c06d63538ba464e8054f4744e62" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/4c92a15296e58191a4cd74cff3b34fc8e374174a", - "reference": "4c92a15296e58191a4cd74cff3b34fc8e374174a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/20c23e85c86e5c06d63538ba464e8054f4744e62", + "reference": "20c23e85c86e5c06d63538ba464e8054f4744e62", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.1", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", - "php": "^7.1", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", - "phpunit/php-file-iterator": "^2.0.1", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0", - "sebastian/version": "^2.0.1" - }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" - }, - "require-dev": { - "ext-pdo": "*" + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.3", + "phar-io/version": "^3.0.2", + "php": ">=8.1", + "phpunit/php-code-coverage": "^10.0", + "phpunit/php-file-iterator": "^4.0", + "phpunit/php-invoker": "^4.0", + "phpunit/php-text-template": "^3.0", + "phpunit/php-timer": "^6.0", + "sebastian/cli-parser": "^2.0", + "sebastian/code-unit": "^2.0", + "sebastian/comparator": "^5.0", + "sebastian/diff": "^5.0", + "sebastian/environment": "^6.0", + "sebastian/exporter": "^5.0", + "sebastian/global-state": "^6.0", + "sebastian/object-enumerator": "^5.0", + "sebastian/recursion-context": "^5.0", + "sebastian/type": "^4.0", + "sebastian/version": "^4.0" }, "suggest": { - "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" + "ext-soap": "To be able to generate mocks based on WSDL files" }, "bin": [ "phpunit" @@ -1525,10 +1364,13 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.5-dev" + "dev-main": "10.0-dev" } }, "autoload": { + "files": [ + "src/Framework/Assert/Functions.php" + ], "classmap": [ "src/" ] @@ -1551,29 +1393,48 @@ "testing", "xunit" ], - "time": "2019-10-28T10:37:36+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.0.19" + }, + "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": "2023-03-27T11:46:33+00:00" }, { "name": "psr/container", - "version": "1.0.0", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/php-fig/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=7.4.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -1588,7 +1449,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common Container Interface (PHP FIG PSR-11)", @@ -1600,34 +1461,38 @@ "container-interop", "psr" ], - "time": "2017-02-14T16:28:37+00:00" + "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": "1.0.1", + "name": "psr/log", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/php-fig/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + "url": "https://github.com/php-fig/log.git", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "3.x-dev" } }, "autoload": { "psr-4": { - "Psr\\Http\\Message\\": "src/" + "Psr\\Log\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -1637,111 +1502,117 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], - "description": "Common interface for HTTP messages", - "homepage": "https://github.com/php-fig/http-message", + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", "keywords": [ - "http", - "http-message", + "log", "psr", - "psr-7", - "request", - "response" + "psr-3" ], - "time": "2016-08-06T14:39:51+00:00" + "support": { + "source": "https://github.com/php-fig/log/tree/3.0.0" + }, + "time": "2021-07-14T16:46:02+00:00" }, { - "name": "psr/log", - "version": "1.1.2", + "name": "sabre/event", + "version": "5.1.4", "source": { "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801" + "url": "https://github.com/sabre-io/event.git", + "reference": "d7da22897125d34d7eddf7977758191c06a74497" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/446d54b4cb6bf489fc9d75f55843658e6f25d801", - "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801", + "url": "https://api.github.com/repos/sabre-io/event/zipball/d7da22897125d34d7eddf7977758191c06a74497", + "reference": "d7da22897125d34d7eddf7977758191c06a74497", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^7.1 || ^8.0" }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } + "require-dev": { + "friendsofphp/php-cs-fixer": "~2.17.1", + "phpstan/phpstan": "^0.12", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.0" }, + "type": "library", "autoload": { + "files": [ + "lib/coroutine.php", + "lib/Loop/functions.php", + "lib/Promise/functions.php" + ], "psr-4": { - "Psr\\Log\\": "Psr/Log/" + "Sabre\\Event\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Evert Pot", + "email": "me@evertpot.com", + "homepage": "http://evertpot.com/", + "role": "Developer" } ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", + "description": "sabre/event is a library for lightweight event-based programming", + "homepage": "http://sabre.io/event/", "keywords": [ - "log", - "psr", - "psr-3" + "EventEmitter", + "async", + "coroutine", + "eventloop", + "events", + "hooks", + "plugin", + "promise", + "reactor", + "signal" ], - "time": "2019-11-01T11:05:21+00:00" + "support": { + "forum": "https://groups.google.com/group/sabredav-discuss", + "issues": "https://github.com/sabre-io/event/issues", + "source": "https://github.com/fruux/sabre-event" + }, + "time": "2021-11-04T06:51:17+00:00" }, { - "name": "respect/validation", - "version": "1.1.31", + "name": "sebastian/cli-parser", + "version": "2.0.0", "source": { "type": "git", - "url": "https://github.com/Respect/Validation.git", - "reference": "45d109fc830644fecc1145200d6351ce4f2769d0" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Respect/Validation/zipball/45d109fc830644fecc1145200d6351ce4f2769d0", - "reference": "45d109fc830644fecc1145200d6351ce4f2769d0", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/efdc130dbbbb8ef0b545a994fd811725c5282cae", + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae", "shasum": "" }, "require": { - "php": ">=5.4", - "symfony/polyfill-mbstring": "^1.2" + "php": ">=8.1" }, "require-dev": { - "egulias/email-validator": "~1.2 || ~2.1", - "mikey179/vfsstream": "^1.5", - "phpunit/phpunit": "~4.0 || ~5.0", - "symfony/validator": "~2.6.9", - "zendframework/zend-validator": "~2.3" - }, - "suggest": { - "egulias/email-validator": "Strict (RFC compliant) email validation", - "ext-bcmath": "Arbitrary Precision Mathematics", - "ext-mbstring": "Multibyte String Functions", - "friendsofphp/php-cs-fixer": "Fix PSR2 and other coding style issues", - "symfony/validator": "Use Symfony validator through Respect\\Validation", - "zendframework/zend-validator": "Use Zend Framework validator through Respect\\Validation" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-main": "2.0-dev" } }, "autoload": { - "psr-4": { - "Respect\\Validation\\": "library/" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1749,206 +1620,164 @@ ], "authors": [ { - "name": "Respect/Validation Contributors", - "homepage": "https://github.com/Respect/Validation/graphs/contributors" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "The most awesome validation engine ever created for PHP", - "homepage": "http://respect.github.io/Validation/", - "keywords": [ - "respect", - "validation", - "validator" + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2019-05-28T06:10:06+00:00" + "time": "2023-02-03T06:58:15+00:00" }, { - "name": "roave/better-reflection", - "version": "dev-master", + "name": "sebastian/code-unit", + "version": "2.0.0", "source": { "type": "git", - "url": "https://github.com/Roave/BetterReflection.git", - "reference": "14f329c5a3201ee890d3d8c4959c8779b9de7f63" + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/BetterReflection/zipball/14f329c5a3201ee890d3d8c4959c8779b9de7f63", - "reference": "14f329c5a3201ee890d3d8c4959c8779b9de7f63", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/a81fee9eef0b7a76af11d121767abc44c104e503", + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503", "shasum": "" }, "require": { - "ext-json": "*", - "jetbrains/phpstorm-stubs": "2019.2", - "nikic/php-parser": "^4.2.1", - "php": ">=7.2.0,<7.5.0", - "phpdocumentor/reflection-docblock": "^4.3.2", - "phpdocumentor/type-resolver": "^1.0.0", - "roave/signature": "^1.0" + "php": ">=8.1" }, "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpunit/phpunit": "^8.1.6" - }, - "suggest": { - "composer/composer": "Required to use the ComposerSourceLocator" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "2.0-dev" } }, "autoload": { - "psr-4": { - "Roave\\BetterReflection\\": "src" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "James Titcumb", - "email": "james@asgrim.com", - "homepage": "https://github.com/asgrim" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "https://ocramius.github.io/" - }, - { - "name": "Gary Hockin", - "email": "gary@roave.com", - "homepage": "https://github.com/geeh" - }, + "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", + "source": "https://github.com/sebastianbergmann/code-unit/tree/2.0.0" + }, + "funding": [ { - "name": "Jaroslav Hanslík", - "email": "kukulich@kukulich.cz", - "homepage": "https://github.com/kukulich" + "url": "https://github.com/sebastianbergmann", + "type": "github" } ], - "description": "Better Reflection - an improved code reflection API", - "time": "2019-10-03T09:08:48+00:00" + "time": "2023-02-03T06:58:43+00:00" }, { - "name": "roave/signature", - "version": "1.0.0", + "name": "sebastian/code-unit-reverse-lookup", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/Roave/Signature.git", - "reference": "bed4ecbdd7f312ab6bb39561ac191f520bcee386" + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/Signature/zipball/bed4ecbdd7f312ab6bb39561ac191f520bcee386", - "reference": "bed4ecbdd7f312ab6bb39561ac191f520bcee386", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", "shasum": "" }, "require": { - "php": "^7.0|^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^5.6" + "phpunit/phpunit": "^10.0" }, "type": "library", - "autoload": { - "psr-4": { - "Roave\\Signature\\": "src" + "extra": { + "branch-alias": { + "dev-main": "3.0-dev" } }, + "autoload": { + "classmap": [ + "src/" + ] + }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "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", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "description": "Sign and verify stuff", - "time": "2017-02-17T13:53:21+00:00" + "time": "2023-02-03T06:59:15+00:00" }, { - "name": "sabre/event", - "version": "5.0.3", + "name": "sebastian/comparator", + "version": "5.0.0", "source": { "type": "git", - "url": "https://github.com/sabre-io/event.git", - "reference": "f5cf802d240df1257866d8813282b98aee3bc548" + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sabre-io/event/zipball/f5cf802d240df1257866d8813282b98aee3bc548", - "reference": "f5cf802d240df1257866d8813282b98aee3bc548", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/72f01e6586e0caf6af81297897bd112eb7e9627c", + "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c", "shasum": "" }, "require": { - "php": ">=7.0" + "ext-dom": "*", + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/diff": "^5.0", + "sebastian/exporter": "^5.0" }, "require-dev": { - "phpunit/phpunit": ">=6", - "sabre/cs": "~1.0.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Sabre\\Event\\": "lib/" - }, - "files": [ - "lib/coroutine.php", - "lib/Loop/functions.php", - "lib/Promise/functions.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Evert Pot", - "email": "me@evertpot.com", - "homepage": "http://evertpot.com/", - "role": "Developer" - } - ], - "description": "sabre/event is a library for lightweight event-based programming", - "homepage": "http://sabre.io/event/", - "keywords": [ - "EventEmitter", - "async", - "coroutine", - "eventloop", - "events", - "hooks", - "plugin", - "promise", - "reactor", - "signal" - ], - "time": "2018-03-05T13:55:47+00:00" - }, - { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -1964,38 +1793,64 @@ { "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": "Looks up which function or method a line of code belongs to", - "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" + "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", + "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:07:16+00:00" }, { - "name": "sebastian/comparator", - "version": "3.0.2", + "name": "sebastian/complexity", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/e67d240970c9dc7ea7b2123a6d520e334dd61dc6", + "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6", "shasum": "" }, "require": { - "php": "^7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "nikic/php-parser": "^4.10", + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -2008,57 +1863,51 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "https://github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2018-07-12T15:12:46+00:00" + "time": "2023-02-03T06:59:47+00:00" }, { "name": "sebastian/diff", - "version": "3.0.2", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/aae9a0a43bff37bd5d8d0311426c87bf36153f02", + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^10.0", + "symfony/process": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -2071,13 +1920,13 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" } ], "description": "Diff implementation", @@ -2088,27 +1937,38 @@ "unidiff", "unified diff" ], - "time": "2019-02-04T06:01:07+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "security": "https://github.com/sebastianbergmann/diff/security/policy", + "source": "https://github.com/sebastianbergmann/diff/tree/5.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-03-23T05:12:41+00:00" }, { "name": "sebastian/environment", - "version": "4.2.3", + "version": "6.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" + "reference": "b6f3694c6386c7959915a0037652e0c40f6f69cc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/b6f3694c6386c7959915a0037652e0c40f6f69cc", + "reference": "b6f3694c6386c7959915a0037652e0c40f6f69cc", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^10.0" }, "suggest": { "ext-posix": "*" @@ -2116,7 +1976,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -2135,40 +1995,50 @@ } ], "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", + "homepage": "https://github.com/sebastianbergmann/environment", "keywords": [ "Xdebug", "environment", "hhvm" ], - "time": "2019-11-20T08:46:58+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/6.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:03:04+00:00" }, { "name": "sebastian/exporter", - "version": "3.1.2", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" + "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", + "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/recursion-context": "^3.0" + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/recursion-context": "^5.0" }, "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -2203,32 +2073,52 @@ } ], "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", + "homepage": "https://www.github.com/sebastianbergmann/exporter", "keywords": [ "export", "exporter" ], - "time": "2019-09-14T09:02:43+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:06:49+00:00" }, { - "name": "sebastian/finder-facade", - "version": "1.2.2", + "name": "sebastian/global-state", + "version": "6.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/finder-facade.git", - "reference": "4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f" + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "aab257c712de87b90194febd52e4d184551c2d44" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/finder-facade/zipball/4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f", - "reference": "4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/aab257c712de87b90194febd52e4d184551c2d44", + "reference": "aab257c712de87b90194febd52e4d184551c2d44", "shasum": "" }, "require": { - "symfony/finder": "~2.3|~3.0|~4.0", - "theseer/fdomdocument": "~1.3" + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" + }, + "require-dev": { + "ext-dom": "*", + "phpunit/phpunit": "^10.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-main": "6.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -2241,41 +2131,51 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "email": "sebastian@phpunit.de" } ], - "description": "FinderFacade is a convenience wrapper for Symfony's Finder component.", - "homepage": "https://github.com/sebastianbergmann/finder-facade", - "time": "2017-11-18T17:31:49+00:00" + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", + "keywords": [ + "global state" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "source": "https://github.com/sebastianbergmann/global-state/tree/6.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:07:38+00:00" }, { - "name": "sebastian/global-state", + "name": "sebastian/lines-of-code", "version": "2.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/17c4d940ecafb3d15d2cf916f4108f664e28b130", + "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130", "shasum": "" }, "require": { - "php": "^7.0" + "nikic/php-parser": "^4.10", + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "suggest": { - "ext-uopz": "*" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "2.0-dev" } }, "autoload": { @@ -2290,42 +2190,50 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" + "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", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-04-27T15:39:26+00:00" + "time": "2023-02-03T07:08:02+00:00" }, { "name": "sebastian/object-enumerator", - "version": "3.0.3", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/202d0e344a580d7f7d04b3fafce6933e59dae906", + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -2345,32 +2253,42 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03T12:35:26+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:08:32+00:00" }, { "name": "sebastian/object-reflector", - "version": "1.1.1", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "773f97c67f28de00d397be301821b06708fca0be" + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/773f97c67f28de00d397be301821b06708fca0be", - "reference": "773f97c67f28de00d397be301821b06708fca0be", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/24ed13d98130f0e7122df55d06c5c4942a577957", + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957", "shasum": "" }, "require": { - "php": "^7.0" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -2390,32 +2308,42 @@ ], "description": "Allows reflection of object attributes, including inherited and non-public ones", "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29T09:07:27+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:06:18+00:00" }, { "name": "sebastian/recursion-context", - "version": "3.0.0", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8" + "reference": "05909fb5bc7df4c52992396d0116aed689f93712" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/05909fb5bc7df4c52992396d0116aed689f93712", + "reference": "05909fb5bc7df4c52992396d0116aed689f93712", "shasum": "" }, "require": { - "php": "^7.0" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -2428,44 +2356,57 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, { "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": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03T06:23:57+00:00" + "homepage": "https://github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:05:40+00:00" }, { - "name": "sebastian/resource-operations", - "version": "2.0.1", + "name": "sebastian/type", + "version": "4.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9" + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/462699a16464c3944eefc02ebdd77882bd3925bf", + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -2480,34 +2421,45 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "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", + "source": "https://github.com/sebastianbergmann/type/tree/4.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" } ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2018-10-04T04:07:39+00:00" + "time": "2023-02-03T07:10:45+00:00" }, { "name": "sebastian/version", - "version": "2.0.1", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c51fa83a5d8f43f1402e3f32a005e6262244ef17", + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -2528,93 +2480,57 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" - }, - { - "name": "slim/php-view", - "version": "2.2.1", - "source": { - "type": "git", - "url": "https://github.com/slimphp/PHP-View.git", - "reference": "a13ada9d7962ca1b48799c0d9ffbca4c33245aed" + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/4.0.1" }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/slimphp/PHP-View/zipball/a13ada9d7962ca1b48799c0d9ffbca4c33245aed", - "reference": "a13ada9d7962ca1b48799c0d9ffbca4c33245aed", - "shasum": "" - }, - "require": { - "psr/http-message": "^1.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8", - "slim/slim": "^3.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Slim\\Views\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ + "funding": [ { - "name": "Glenn Eggleton", - "email": "geggleto@gmail.com" + "url": "https://github.com/sebastianbergmann", + "type": "github" } ], - "description": "Render PHP view scripts into a PSR-7 Response object.", - "keywords": [ - "framework", - "php", - "phtml", - "renderer", - "slim", - "template", - "view" - ], - "time": "2019-04-15T20:43:28+00:00" + "time": "2023-02-07T11:34:05+00:00" }, { "name": "symfony/console", - "version": "v4.3.6", + "version": "v6.2.8", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "136c4bd62ea871d00843d1bc0316de4c4a84bb78" + "reference": "3582d68a64a86ec25240aaa521ec8bc2342b369b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/136c4bd62ea871d00843d1bc0316de4c4a84bb78", - "reference": "136c4bd62ea871d00843d1bc0316de4c4a84bb78", + "url": "https://api.github.com/repos/symfony/console/zipball/3582d68a64a86ec25240aaa521ec8bc2342b369b", + "reference": "3582d68a64a86ec25240aaa521ec8bc2342b369b", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.1|^3", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php73": "^1.8", - "symfony/service-contracts": "^1.1" + "symfony/service-contracts": "^1.1|^2|^3", + "symfony/string": "^5.4|^6.0" }, "conflict": { - "symfony/dependency-injection": "<3.4", - "symfony/event-dispatcher": "<4.3", - "symfony/process": "<3.3" + "symfony/dependency-injection": "<5.4", + "symfony/dotenv": "<5.4", + "symfony/event-dispatcher": "<5.4", + "symfony/lock": "<5.4", + "symfony/process": "<5.4" }, "provide": { - "psr/log-implementation": "1.0" + "psr/log-implementation": "1.0|2.0|3.0" }, "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~3.4|~4.0", - "symfony/dependency-injection": "~3.4|~4.0", - "symfony/event-dispatcher": "^4.3", - "symfony/lock": "~3.4|~4.0", - "symfony/process": "~3.4|~4.0", - "symfony/var-dumper": "^4.3" + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/event-dispatcher": "^5.4|^6.0", + "symfony/lock": "^5.4|^6.0", + "symfony/process": "^5.4|^6.0", + "symfony/var-dumper": "^5.4|^6.0" }, "suggest": { "psr/log": "For using the console logger", @@ -2623,11 +2539,6 @@ "symfony/process": "" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.3-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Console\\": "" @@ -2650,39 +2561,63 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Console Component", + "description": "Eases the creation of beautiful and testable command line interfaces", "homepage": "https://symfony.com", - "time": "2019-10-30T12:58:49+00:00" + "keywords": [ + "cli", + "command-line", + "console", + "terminal" + ], + "support": { + "source": "https://github.com/symfony/console/tree/v6.2.8" + }, + "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": "2023-03-29T21:42:15+00:00" }, { - "name": "symfony/finder", - "version": "v4.3.6", + "name": "symfony/deprecation-contracts", + "version": "v3.2.1", "source": { "type": "git", - "url": "https://github.com/symfony/finder.git", - "reference": "72a068f77e317ae77c0a0495236ad292cfb5ce6f" + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/72a068f77e317ae77c0a0495236ad292cfb5ce6f", - "reference": "72a068f77e317ae77c0a0495236ad292cfb5ce6f", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e", + "reference": "e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e", "shasum": "" }, "require": { - "php": "^7.1.3" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.3-dev" + "dev-main": "3.3-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { - "psr-4": { - "Symfony\\Component\\Finder\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" + "files": [ + "function.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2691,34 +2626,54 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Finder Component", + "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", - "time": "2019-10-30T12:53:54+00:00" + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.2.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": "2023-03-01T10:25:55+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.13.1", + "version": "v1.27.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3" + "reference": "5bbc823adecdae860bb64756d639ecfec17b050a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/5bbc823adecdae860bb64756d639ecfec17b050a", + "reference": "5bbc823adecdae860bb64756d639ecfec17b050a", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.1" + }, + "provide": { + "ext-ctype": "*" }, "suggest": { "ext-ctype": "For best performance" @@ -2726,16 +2681,20 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.13-dev" + "dev-main": "1.27-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2759,41 +2718,62 @@ "polyfill", "portable" ], - "time": "2019-11-27T13:56:44+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.27.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": "2022-11-03T14:55:06+00:00" }, { - "name": "symfony/polyfill-mbstring", - "version": "v1.12.0", + "name": "symfony/polyfill-intl-grapheme", + "version": "v1.27.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "b42a2f66e8f1b15ccf25652c3424265923eb4f17" + "url": "https://github.com/symfony/polyfill-intl-grapheme.git", + "reference": "511a08c03c1960e08a883f4cffcacd219b758354" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/b42a2f66e8f1b15ccf25652c3424265923eb4f17", - "reference": "b42a2f66e8f1b15ccf25652c3424265923eb4f17", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/511a08c03c1960e08a883f4cffcacd219b758354", + "reference": "511a08c03c1960e08a883f4cffcacd219b758354", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.1" }, "suggest": { - "ext-mbstring": "For best performance" + "ext-intl": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.12-dev" + "dev-main": "1.27-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2809,47 +2789,72 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill for the Mbstring extension", + "description": "Symfony polyfill for intl's grapheme_* functions", "homepage": "https://symfony.com", "keywords": [ "compatibility", - "mbstring", + "grapheme", + "intl", "polyfill", "portable", "shim" ], - "time": "2019-08-06T08:03:45+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.27.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": "2022-11-03T14:55:06+00:00" }, { - "name": "symfony/polyfill-php73", - "version": "v1.12.0", + "name": "symfony/polyfill-intl-normalizer", + "version": "v1.27.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "2ceb49eaccb9352bff54d22570276bb75ba4a188" + "url": "https://github.com/symfony/polyfill-intl-normalizer.git", + "reference": "19bd1e4fcd5b91116f14d8533c57831ed00571b6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/2ceb49eaccb9352bff54d22570276bb75ba4a188", - "reference": "2ceb49eaccb9352bff54d22570276bb75ba4a188", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/19bd1e4fcd5b91116f14d8533c57831ed00571b6", + "reference": "19bd1e4fcd5b91116f14d8533c57831ed00571b6", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.12-dev" + "dev-main": "1.27-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php73\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -2868,46 +2873,74 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions", + "description": "Symfony polyfill for intl's Normalizer class and related functions", "homepage": "https://symfony.com", "keywords": [ "compatibility", + "intl", + "normalizer", "polyfill", "portable", "shim" ], - "time": "2019-08-06T08:03:45+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.27.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": "2022-11-03T14:55:06+00:00" }, { - "name": "symfony/service-contracts", - "version": "v1.1.7", + "name": "symfony/polyfill-mbstring", + "version": "v1.27.0", "source": { "type": "git", - "url": "https://github.com/symfony/service-contracts.git", - "reference": "ffcde9615dc5bb4825b9f6aed07716f1f57faae0" + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "8ad114f6b39e2c98a8b0e3bd907732c207c2b534" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/ffcde9615dc5bb4825b9f6aed07716f1f57faae0", - "reference": "ffcde9615dc5bb4825b9f6aed07716f1f57faae0", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/8ad114f6b39e2c98a8b0e3bd907732c207c2b534", + "reference": "8ad114f6b39e2c98a8b0e3bd907732c207c2b534", "shasum": "" }, "require": { - "php": "^7.1.3", - "psr/container": "^1.0" + "php": ">=7.1" + }, + "provide": { + "ext-mbstring": "*" }, "suggest": { - "symfony/service-implementation": "" + "ext-mbstring": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-main": "1.27-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { + "files": [ + "bootstrap.php" + ], "psr-4": { - "Symfony\\Contracts\\Service\\": "" + "Symfony\\Polyfill\\Mbstring\\": "" } }, "notification-url": "https://packagist.org/downloads/", @@ -2924,48 +2957,70 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Generic abstractions related to writing services", + "description": "Symfony polyfill for the Mbstring extension", "homepage": "https://symfony.com", "keywords": [ - "abstractions", - "contracts", - "decoupling", - "interfaces", - "interoperability", - "standards" + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" ], - "time": "2019-09-17T11:12:18+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.27.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": "2022-11-03T14:55:06+00:00" }, { - "name": "symfony/stopwatch", - "version": "v4.3.6", + "name": "symfony/polyfill-php80", + "version": "v1.27.0", "source": { "type": "git", - "url": "https://github.com/symfony/stopwatch.git", - "reference": "1e4ff456bd625be5032fac9be4294e60442e9b71" + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "7a6ff3f1959bb01aefccb463a0f2cd3d3d2fd936" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/1e4ff456bd625be5032fac9be4294e60442e9b71", - "reference": "1e4ff456bd625be5032fac9be4294e60442e9b71", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/7a6ff3f1959bb01aefccb463a0f2cd3d3d2fd936", + "reference": "7a6ff3f1959bb01aefccb463a0f2cd3d3d2fd936", "shasum": "" }, "require": { - "php": "^7.1.3", - "symfony/service-contracts": "^1.0" + "php": ">=7.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.3-dev" + "dev-main": "1.27-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { + "files": [ + "bootstrap.php" + ], "psr-4": { - "Symfony\\Component\\Stopwatch\\": "" + "Symfony\\Polyfill\\Php80\\": "" }, - "exclude-from-classmap": [ - "/Tests/" + "classmap": [ + "Resources/stubs" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2974,57 +3029,85 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Stopwatch Component", + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", "homepage": "https://symfony.com", - "time": "2019-08-07T11:52:19+00:00" + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.27.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": "2022-11-03T14:55:06+00:00" }, { - "name": "symfony/yaml", - "version": "v4.4.1", + "name": "symfony/service-contracts", + "version": "v3.2.1", "source": { "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "76de473358fe802578a415d5bb43c296cf09d211" + "url": "https://github.com/symfony/service-contracts.git", + "reference": "a8c9cedf55f314f3a186041d19537303766df09a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/76de473358fe802578a415d5bb43c296cf09d211", - "reference": "76de473358fe802578a415d5bb43c296cf09d211", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/a8c9cedf55f314f3a186041d19537303766df09a", + "reference": "a8c9cedf55f314f3a186041d19537303766df09a", "shasum": "" }, "require": { - "php": "^7.1.3", - "symfony/polyfill-ctype": "~1.8" + "php": ">=8.1", + "psr/container": "^2.0" }, "conflict": { - "symfony/console": "<3.4" - }, - "require-dev": { - "symfony/console": "^3.4|^4.0|^5.0" + "ext-psr": "<1.1|>=2" }, "suggest": { - "symfony/console": "For validating YAML files using the lint command" + "symfony/service-implementation": "" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.4-dev" + "dev-main": "3.3-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { "psr-4": { - "Symfony\\Component\\Yaml\\": "" + "Symfony\\Contracts\\Service\\": "" }, "exclude-from-classmap": [ - "/Tests/" + "/Test/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -3033,77 +3116,148 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Yaml Component", + "description": "Generic abstractions related to writing services", "homepage": "https://symfony.com", - "time": "2019-11-12T14:51:11+00:00" + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v3.2.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": "2023-03-01T10:32:47+00:00" }, { - "name": "theseer/fdomdocument", - "version": "1.6.6", + "name": "symfony/string", + "version": "v6.2.8", "source": { "type": "git", - "url": "https://github.com/theseer/fDOMDocument.git", - "reference": "6e8203e40a32a9c770bcb62fe37e68b948da6dca" + "url": "https://github.com/symfony/string.git", + "reference": "193e83bbd6617d6b2151c37fff10fa7168ebddef" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/fDOMDocument/zipball/6e8203e40a32a9c770bcb62fe37e68b948da6dca", - "reference": "6e8203e40a32a9c770bcb62fe37e68b948da6dca", + "url": "https://api.github.com/repos/symfony/string/zipball/193e83bbd6617d6b2151c37fff10fa7168ebddef", + "reference": "193e83bbd6617d6b2151c37fff10fa7168ebddef", "shasum": "" }, "require": { - "ext-dom": "*", - "lib-libxml": "*", - "php": ">=5.3.3" + "php": ">=8.1", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-intl-grapheme": "~1.0", + "symfony/polyfill-intl-normalizer": "~1.0", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/translation-contracts": "<2.0" + }, + "require-dev": { + "symfony/error-handler": "^5.4|^6.0", + "symfony/http-client": "^5.4|^6.0", + "symfony/intl": "^6.2", + "symfony/translation-contracts": "^2.0|^3.0", + "symfony/var-exporter": "^5.4|^6.0" }, "type": "library", "autoload": { - "classmap": [ - "src/" + "files": [ + "Resources/functions.php" + ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Arne Blankerts", - "email": "arne@blankerts.de", - "role": "lead" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way", + "homepage": "https://symfony.com", + "keywords": [ + "grapheme", + "i18n", + "string", + "unicode", + "utf-8", + "utf8" + ], + "support": { + "source": "https://github.com/symfony/string/tree/v6.2.8" + }, + "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" } ], - "description": "The classes contained within this repository extend the standard DOM to use exceptions at all occasions of errors instead of PHP warnings or notices. They also add various custom methods and shortcuts for convenience and to simplify the usage of DOM.", - "homepage": "https://github.com/theseer/fDOMDocument", - "time": "2017-06-30T11:53:12+00:00" + "time": "2023-03-20T16:06:02+00:00" }, { "name": "theseer/tokenizer", - "version": "1.1.3", + "version": "1.2.1", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9" + "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/11336f6f84e16a720dae9d8e6ed5019efa85a0f9", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/34a41e998c2183e22995f158c581e7b5e755ab9e", + "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e", "shasum": "" }, "require": { "ext-dom": "*", "ext-tokenizer": "*", "ext-xmlwriter": "*", - "php": "^7.0" + "php": "^7.2 || ^8.0" }, "type": "library", "autoload": { @@ -3123,33 +3277,111 @@ } ], "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", - "time": "2019-06-13T22:48:21+00:00" + "support": { + "issues": "https://github.com/theseer/tokenizer/issues", + "source": "https://github.com/theseer/tokenizer/tree/1.2.1" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2021-07-28T10:34:58+00:00" + }, + { + "name": "tysonandre/var_representation_polyfill", + "version": "0.1.3", + "source": { + "type": "git", + "url": "https://github.com/TysonAndre/var_representation_polyfill.git", + "reference": "e9116c2c352bb0835ca428b442dde7767c11ad32" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/TysonAndre/var_representation_polyfill/zipball/e9116c2c352bb0835ca428b442dde7767c11ad32", + "reference": "e9116c2c352bb0835ca428b442dde7767c11ad32", + "shasum": "" + }, + "require": { + "ext-tokenizer": "*", + "php": "^7.2.0|^8.0.0" + }, + "provide": { + "ext-var_representation": "*" + }, + "require-dev": { + "phan/phan": "^5.4.1", + "phpunit/phpunit": "^8.5.0" + }, + "suggest": { + "ext-var_representation": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "0.1.3-dev" + } + }, + "autoload": { + "files": [ + "src/var_representation.php" + ], + "psr-4": { + "VarRepresentation\\": "src/VarRepresentation" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Tyson Andre" + } + ], + "description": "Polyfill for var_representation: convert a variable to a string in a way that fixes the shortcomings of var_export", + "keywords": [ + "var_export", + "var_representation" + ], + "support": { + "issues": "https://github.com/TysonAndre/var_representation_polyfill/issues", + "source": "https://github.com/TysonAndre/var_representation_polyfill/tree/0.1.3" + }, + "time": "2022-08-31T12:59:22+00:00" }, { "name": "webmozart/assert", - "version": "1.6.0", + "version": "1.11.0", "source": { "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "573381c0a64f155a0d9a23f4b0c797194805b925" + "url": "https://github.com/webmozarts/assert.git", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/573381c0a64f155a0d9a23f4b0c797194805b925", - "reference": "573381c0a64f155a0d9a23f4b0c797194805b925", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0", - "symfony/polyfill-ctype": "^1.8" + "ext-ctype": "*", + "php": "^7.2 || ^8.0" }, "conflict": { - "vimeo/psalm": "<3.6.0" + "phpstan/phpstan": "<0.12.20", + "vimeo/psalm": "<4.6.1 || 4.6.2" }, "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" + "phpunit/phpunit": "^8.5.13" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, "autoload": { "psr-4": { "Webmozart\\Assert\\": "src/" @@ -3171,18 +3403,20 @@ "check", "validate" ], - "time": "2019-11-24T13:36:37+00:00" + "support": { + "issues": "https://github.com/webmozarts/assert/issues", + "source": "https://github.com/webmozarts/assert/tree/1.11.0" + }, + "time": "2022-06-03T18:03:27+00:00" } ], "aliases": [], "minimum-stability": "stable", - "stability-flags": { - "roave/better-reflection": 20 - }, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": ">=7.1.10", + "php": ">=8.0.0", "ext-json": "*", "ext-pcre": "*", "ext-spl": "*", @@ -3190,5 +3424,6 @@ }, "platform-dev": { "ext-reflection": "*" - } + }, + "plugin-api-version": "2.3.0" } diff --git a/classes/vendor/dallgoot/yaml/configuration/placeholder.txt b/classes/vendor/dallgoot/yaml/configuration/placeholder.txt deleted file mode 100644 index e69de29..0000000 diff --git a/classes/vendor/dallgoot/yaml/examples/batch_read.php b/classes/vendor/dallgoot/yaml/examples/batch_read.php index 25fb3f4..2ea9165 100644 --- a/classes/vendor/dallgoot/yaml/examples/batch_read.php +++ b/classes/vendor/dallgoot/yaml/examples/batch_read.php @@ -16,4 +16,4 @@ $yamlObjList[] = $yloader->load($fileName)->parse(); } -var_dump($yamlObjList); +print_r($yamlObjList); diff --git a/classes/vendor/dallgoot/yaml/examples/compact_notation.php b/classes/vendor/dallgoot/yaml/examples/compact_notation.php index 7296b2d..039849e 100644 --- a/classes/vendor/dallgoot/yaml/examples/compact_notation.php +++ b/classes/vendor/dallgoot/yaml/examples/compact_notation.php @@ -12,12 +12,12 @@ $obj = Yaml::parse($yamlContent); //printing specifically some values -var_dump($obj->compact_object->c); -var_dump($obj->compact_array[3]); +print_r($obj->compact_object->c); +print_r($obj->compact_array[3]); //modifying those same values $obj->compact_object->c = 3; $obj->compact_array[3] = 3; //printing the corresponding YAML -var_dump(Yaml::dump($obj)); \ No newline at end of file +print_r(Yaml::dump($obj)); \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/examples/load_modify_save.php b/classes/vendor/dallgoot/yaml/examples/load_modify_save.php index edc2d69..b999d07 100644 --- a/classes/vendor/dallgoot/yaml/examples/load_modify_save.php +++ b/classes/vendor/dallgoot/yaml/examples/load_modify_save.php @@ -1,11 +1,11 @@ object->array[3]->integer = '123456789'; //dumping the corresponding YAML -var_dump(Yaml::dump($yamlObject, 0)); \ No newline at end of file +print_r(Yaml::dump($yamlObject, 0)); \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/examples/read.php b/classes/vendor/dallgoot/yaml/examples/read.php index 049a769..13dacae 100644 --- a/classes/vendor/dallgoot/yaml/examples/read.php +++ b/classes/vendor/dallgoot/yaml/examples/read.php @@ -10,7 +10,7 @@ */ $yaml = Yaml::parseFile('./examples/dummy.yml', 0, $debug); -var_dump($yaml->object->array[0]); +print_r($yaml->object->array[0]); $yamlContent = <<mapping->somekey->array[0]); \ No newline at end of file +print_r($second_document[1]->mapping->somekey->array[0]); \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/examples/references.php b/classes/vendor/dallgoot/yaml/examples/references.php index 59bc2f6..caa56d9 100644 --- a/classes/vendor/dallgoot/yaml/examples/references.php +++ b/classes/vendor/dallgoot/yaml/examples/references.php @@ -1,7 +1,7 @@ anchor_definition); -var_dump($obj->anchor_call); +print_r($obj->anchor_definition); +print_r($obj->anchor_call); echo "\nchange anchor/reference value to 123\n"; $obj->addReference('anchor_name', 123); -var_dump($obj->anchor_definition); -var_dump($obj->anchor_call); +print_r($obj->anchor_definition); +print_r($obj->anchor_call); echo "\nchange one anchor to new value 'abc'\n"; $obj->anchor_definition = 'abc'; -var_dump($obj->anchor_definition); -var_dump($obj->anchor_call); +print_r($obj->anchor_definition); +print_r($obj->anchor_call); echo "\nunset anchor_call and re-set value\n"; unset($obj->anchor_call); $obj->anchor_call = 'xyz'; -var_dump($obj->anchor_definition); -var_dump($obj->anchor_call); +print_r($obj->anchor_definition); +print_r($obj->anchor_call); echo "\nchange anchor/reference value to 789\n"; $obj->addReference('anchor_name', 789); -var_dump($obj->anchor_definition); -var_dump($obj->anchor_call); +print_r($obj->anchor_definition); +print_r($obj->anchor_call); -var_dump($obj); \ No newline at end of file +print_r($obj); \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/examples/testing.php b/classes/vendor/dallgoot/yaml/examples/testing.php index a941767..5ea9c7d 100644 --- a/classes/vendor/dallgoot/yaml/examples/testing.php +++ b/classes/vendor/dallgoot/yaml/examples/testing.php @@ -16,9 +16,9 @@ /* USE CASE 1 * load and parse if file exists */ -$content = file_get_contents($file);//var_dump($content); +$content = file_get_contents($file); $yaml = Yaml::parse($content, 0, $debug); echo memory_get_usage() . "\n"; -// var_dump($yaml); -var_dump(json_encode($yaml, JSON_OPTIONS)); \ No newline at end of file + +print_r(json_encode($yaml, JSON_OPTIONS)); \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/examples/write.php b/classes/vendor/dallgoot/yaml/examples/write.php index ea524cf..d56315f 100644 --- a/classes/vendor/dallgoot/yaml/examples/write.php +++ b/classes/vendor/dallgoot/yaml/examples/write.php @@ -1,7 +1,7 @@ - * @license Apache 2.0 - * @link https://github.com/dallgoot/yaml - */ -class Dumper -{ - private const LINEFEED = "\n"; - public const INDENT = 2; - // private const WIDTH = 120; //TODO forget this feature for the moment - private const OPTIONS = 0b00000; - public const DATE_FORMAT = 'Y-m-d'; - - public $options; - //options - public const EXPAND_SHORT = 0b00001; - public const SERIALIZE_CUSTOM_OBJECTS = 0b00010; - /** @var int */ - public $floatPrecision = 4; - /** @var bool */ - private $multipleDocs = false; - /** @var bool */ - public $_compactMode = false; - /** @var null|DumperHandlers */ - private $handler; - - - public function __construct($options=null) - { - $this->options = is_int($options) ? $options : self::OPTIONS; - $this->handler = new DumperHandlers($this); - } - /** - * Returns (as a string) the YAML representation of the $dataType provided - * - * @param mixed $dataType The data type - * @param int|null $options The options - * - * @throws \Exception datatype cannot be null - * - * @return string The Yaml string content - */ - public function toString($dataType, int $options = null):string - { - if (empty($dataType)) throw new \Exception(self::class.": No content to convert to Yaml"); - if (is_scalar($dataType)) { - return "--- ".$this->handler->dumpScalar($dataType). self::LINEFEED ; - } - return $this->dump($dataType, 0); - } - - /** - * Calls and saves the result of Dumper::toString to the file $filePath provided - * - * @param string $filePath The file path - * @param mixed $dataType The data type - * @param int|null $options The options - * - * @throws \Exception datatype cannot be null - * - * @return bool true = if the file has been correctly saved ( return value from 'file_put_contents') - */ - public function toFile(string $filePath, $dataType, int $options = null):bool - { - return !is_bool(file_put_contents($filePath, $this->toString($dataType, $options))); - } - - - - public function dump($dataType, int $indent):string - { - if (is_null($dataType)) { - return ''; - } elseif (is_resource($dataType)) { - return get_resource_type($dataType); - } elseif (is_scalar($dataType)) { - return $this->handler->dumpScalar($dataType); - } else { - return $this->handler->dumpCompound($dataType, $indent); - } - } - - - public function dumpMultiDoc($arrayOfYamlObject) - { - $output = ''; - foreach ($arrayOfYamlObject as $key => $yamlObject) { - $output .= "---\n".$this->dumpYamlObject($yamlObject)."\n"; - } - return $output; - } - - /** - * Dumps an yaml object to a YAML string - * - * @param YamlObject $obj The object - * - * @return string YAML formatted string - * @todo export comment from YamlObject - */ - public function dumpYamlObject(YamlObject $obj):string - { - if ($this->multipleDocs || $obj->hasDocStart() || $obj->isTagged()) { - $this->multipleDocs = true; - // && $this->$result instanceof DLL) $this->$result->push("---"); - } - // $this->insertComments($obj->getComment()); - if (count($obj) > 0) { - return $this->iteratorToString($obj, '-', "\n", 0); - } else { - return $this->iteratorToString(new \ArrayIterator(get_object_vars($obj)), '%s:', "\n", 0); - } - } - - - public function iteratorToString(\Iterator $iterable, - string $keyMask, string $itemSeparator, int $indent):string - { - $pairs = []; - $valueIndent = $indent + self::INDENT; - foreach ($iterable as $key => $value) { - $separator = "\n"; - if (is_scalar($value) || $value instanceof Compact || $value instanceof \DateTime) { - $separator = ' '; - $valueIndent = 0; - } - if ($this->_compactMode) { - $pairs[] = sprintf($keyMask, $key).$this->dump($value, $valueIndent); - } else { - $pairs[] = str_repeat(' ', $indent).sprintf($keyMask, $key).$separator.$this->dump($value, $valueIndent); - } - - } - // $processItem = function () - return implode($itemSeparator, $pairs); - // return implode($itemSeparator, array_map(callback, arr1)); - } -} diff --git a/classes/vendor/dallgoot/yaml/sources/DumperHandlers.php b/classes/vendor/dallgoot/yaml/sources/DumperHandlers.php deleted file mode 100644 index f2816c3..0000000 --- a/classes/vendor/dallgoot/yaml/sources/DumperHandlers.php +++ /dev/null @@ -1,142 +0,0 @@ - - * @license Apache 2.0 - * @link https://github.com/dallgoot/yaml - */ -class DumperHandlers -{ - private $dumper; - - public function __construct(Dumper $dumper) - { - $this->dumper = $dumper; - } - - - public function dumpScalar($dataType):string - { - if ($dataType === \INF) return '.inf'; - if ($dataType === -\INF) return '-.inf'; - $precision = "%.".$this->dumper->floatPrecision."F"; - switch (gettype($dataType)) { - case 'boolean': return $dataType ? 'true' : 'false'; - case 'float': //fall through - case 'double': return is_nan((double) $dataType) ? '.nan' : sprintf($precision, $dataType); - } - return $this->dumpString($dataType); - } - - - public function dumpCompound($compound, int $indent):string - { - if ($this->dumper->_compactMode) { - return $this->dumpCompact($compound, $indent); - } else { - if (is_array($compound)) { - if ($compound[0] instanceof YamlObject) { - return $this->dumper->dumpMultiDoc($compound); - } - $iterator = new \ArrayIterator($compound); - $keyMask = '-'; - $refKeys = range(0, count($compound) - 1); - if (array_keys($compound) !== $refKeys) { - $keyMask = '%s:'; - } - return $this->dumper->iteratorToString($iterator, $keyMask, "\n", $indent); - } elseif (is_object($compound) && !is_callable($compound)) { - return $this->dumpObject($compound, $indent); - } - } - throw new \Exception("Dumping Callable|Resource is not currently supported", 1); - } - - private function dumpObject($object, int $indent):string - { - if ($object instanceof YamlObject) { - return $this->dumper->dumpYamlObject($object); - } elseif ($object instanceof Compact) { - return $this->dumpCompact($object, $indent); - } elseif ($object instanceof Tagged) { - return $this->dumpTagged($object, $indent); - } elseif ($object instanceof \DateTime) { - return $object->format($this->dumper::DATE_FORMAT); - } elseif (is_iterable($object)) { - $iterator = $object; - } else { - $iterator = new \ArrayIterator(get_object_vars($object)); - } - return $this->dumper->iteratorToString($iterator, '%s:', "\n", $indent); - } - - - - /** - * Dumps a Compact|mixed (representing an array or object) as the single-line format representation. - * All values inside are assumed single-line as well. - * Note: can NOT use JSON_encode because of possible reference calls or definitions as : '&abc 123', '*fre' - * which would be quoted by json_encode - * - * @param mixed $subject The subject - * @param integer $indent The indent - * - * @return string the string representation (JSON like) of the value - */ - public function dumpCompact($subject, int $indent):string - { - $structureFormat = '{%s}'; - $keyMask = "%s: "; - if (!is_array($subject) && !($subject instanceof \ArrayIterator)) { - $source = get_object_vars($subject); - } else { - $max = count($subject); - $objectAsArray = is_array($subject) ? $subject : $subject->getArrayCopy(); - $source = $objectAsArray; - if (array_keys($objectAsArray) === range(0, $max - 1)) { - $structureFormat = '[%s]'; - $keyMask = ''; - } - } - $previousCompactMode = $this->dumper->_compactMode; - $this->dumper->_compactMode = true; - $result = $this->dumper->iteratorToString(new \ArrayIterator($source), $keyMask, ', ', $indent); - $this->dumper->_compactMode = $previousCompactMode; - return sprintf($structureFormat, $result); - } - - /** - * Dumps a string. Protects it if needed - * - * @param string $str The string - * - * @return string ( description_of_the_return_value ) - * @todo implements checking and protection function - */ - public function dumpString(string $str):string - { - //those characters must be escaped : - : ? { } [ ] # , & * ! > | ' " % - // The “@” (#x40, at) and “`” (#x60, grave accent) are reserved for future use. - // 5.4. Line Break Characters - // Example 5.13. Escaped Characters - - $str = json_encode(ltrim($str)); - return strspn(substr($str,1,-1), "-:?{}[]#,&*!>|'\"%") > 0 ? $str : trim($str, '"'); - } - - public function dumpTagged(Tagged $obj, int $indent):string - { - $separator = ' '; - $valueIndent = 0; - if (!is_scalar($obj->value) && !$this->dumper->_compactMode) { - $separator = "\n"; - $valueIndent = $indent + $this->dumper::INDENT; - } - return $obj->tagName.$separator.$this->dumper->dump($obj->value, $valueIndent); - } -} diff --git a/classes/vendor/dallgoot/yaml/sources/NodeFactory.php b/classes/vendor/dallgoot/yaml/sources/NodeFactory.php deleted file mode 100644 index d3adde2..0000000 --- a/classes/vendor/dallgoot/yaml/sources/NodeFactory.php +++ /dev/null @@ -1,178 +0,0 @@ - - * @license Apache 2.0 - * @link https://github.com/dallgoot/yaml - */ -final class NodeFactory -{ - private const JSON_OPTIONS = \JSON_PARTIAL_OUTPUT_ON_ERROR|\JSON_UNESCAPED_SLASHES; - - final public static function get($nodeString = null, $line = 0):NodeGeneric - { - $trimmed = ltrim($nodeString); - if ($trimmed === '') return new Nodes\Blank($nodeString, $line); - elseif (substr($trimmed, 0, 3) === '...') return new Nodes\DocEnd($nodeString, $line); - elseif ((bool) preg_match(Regex::KEY, $trimmed, $matches)) return new Nodes\Key($nodeString, $line, $matches); - else { - $first = $trimmed[0]; - $stringGroups = ['-', '>|' , '"\'', "#%" , "{[" , ":?" , '*&!']; - $methodGroups = ['Hyphen','Literal','Quoted','Special','Compact','SetElement','NodeAction']; - foreach ($stringGroups as $groupIndex => $stringRef) { - if (is_int(strpos($stringRef, $first))) { - $methodName = 'on'.$methodGroups[$groupIndex]; - try { - return self::$methodName($first, $nodeString, $line); - } catch (\Throwable $e) { - throw new \Exception(" could not create a Node ($methodName) for '$nodeString'", 1, $e); - } - } - } - } - return new Nodes\Scalar($nodeString, $line); - } - - /** - * Return the correct Node Object between NodeComment OR NodeDirective - * - * @param string $nodeString The node string - * @param integer $line The line - * - * @return NodeGeneric - */ - private static function onSpecial(string $first, string $nodeString, int $line):NodeGeneric - { - if ($first === "#") { - return new Nodes\Comment(ltrim($nodeString), $line); - } else { - if (preg_match(Regex::DIRECTIVE_TAG, $nodeString) - || preg_match(Regex::DIRECTIVE_VERSION, $nodeString)) { - return new Nodes\Directive(ltrim($nodeString), $line); - } else { - throw new \ParseError("Invalid/Unknown Directive", 1); - } - } - } - - /** - * Set $node type and value when $nodevalue starts with a quote (simple or double) - * - * @param string $nodeString The node value - * @param int $line The line - * - * @return NodeGeneric - */ - private static function onQuoted(string $first, string $nodeString, int $line):NodeGeneric - { - return Regex::isProperlyQuoted(trim($nodeString)) ? new Nodes\Quoted($nodeString, $line) - : new Nodes\Partial($nodeString, $line); - } - - /** - * Set $node type and value when NodeValue starts with a Set characters "?:" - * - * @param string $nodeString The node value - * @param int $line The line - * - * @return NodeGeneric - */ - private static function onSetElement(string $first, string $nodeString, int $line):NodeGeneric - { - return $first === '?' ? new Nodes\SetKey($nodeString, $line) - : new Nodes\SetValue($nodeString, $line); - } - - /** - * Determines the Node type and value when a compact object/array syntax is found - * - * @param string $nodeString The value assumed to start with { or [ or characters - * @param int $line The line - * - * @return NodeGeneric - */ - private static function onCompact(string $first, string $nodeString, int $line):NodeGeneric - { - json_decode($nodeString, false, 512, self::JSON_OPTIONS); - if (json_last_error() === \JSON_ERROR_NONE) { - return new Nodes\JSON($nodeString, $line); - } else { - $backtrack_setting = "pcre.backtrack_limit"; - ini_set($backtrack_setting, "-1"); - $isMapping = preg_match(Regex::MAPPING, trim($nodeString)); - $isSequence = preg_match(Regex::SEQUENCE, trim($nodeString)); - ini_restore($backtrack_setting); - - if (is_bool($isMapping) || is_bool($isSequence)) { - throw new \Exception("Regex Error for ".(is_bool($isMapping) ? 'mapping:' :'sequence:').preg_last_error()); - } - if ($isMapping) { - // var_dump(Regex::MAPPING, trim($nodeString)); - return new Nodes\CompactMapping($nodeString, $line); - } elseif ($isSequence) { - return new Nodes\CompactSequence($nodeString, $line); - } - } - return new Nodes\Partial($nodeString, $line); - } - - /** - * Determines Node type and value when an hyphen "-" is found - * - * @param string $nodeString The node string value - * @param int $line The line - * - * @return NodeGeneric - */ - private static function onHyphen(string $first, string $nodeString, int $line):NodeGeneric - { - if (substr($nodeString, 0, 3) === '---') return new Nodes\DocStart($nodeString, $line); - elseif ((bool) preg_match(Regex::ITEM, ltrim($nodeString))) return new Nodes\Item($nodeString, $line); - else { - return new Nodes\Scalar($nodeString, $line); - } - } - - /** - * Sets Node type and value according to $nodeString when one of these characters is found : !,&,* - * - * @param string $nodeString The node value - * @param int $line The line - * - *@todo replace $action[0] with $first if applicable - */ - private static function onNodeAction(string $first, string $nodeString, int $line):NodeGeneric - { - if (!((bool) preg_match(Regex::NODE_ACTIONS, trim($nodeString), $matches))) { - // var_dump("ACTION is scalar: '$nodeString'"); - return new Nodes\Scalar($nodeString, $line); - } - if ($first === "!") { - return new Nodes\Tag($nodeString, $line); - } else { - return new Nodes\Anchor($nodeString, $line); - } - } - - private static function onLiteral(string $first, string $nodeString, int $line):NodeGeneric - { - switch ($first) { - case '>': return new Nodes\LiteralFolded($nodeString, $line); - case '|': return new Nodes\Literal($nodeString, $line); - default: - throw new \ParseError("Not a literal node !! '$first' on line:$line"); - } - } - -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/sources/YamlProperties.php b/classes/vendor/dallgoot/yaml/sources/YamlProperties.php deleted file mode 100644 index 6a3e973..0000000 --- a/classes/vendor/dallgoot/yaml/sources/YamlProperties.php +++ /dev/null @@ -1,37 +0,0 @@ - - * @license Apache 2.0 - * @link https://github.com/dallgoot/yaml - */ -class YamlProperties -{ - /** @var null|boolean */ - public $_hasDocStart; // null = no docstart, true = docstart before document comments, false = docstart after document comments - /** @var array */ - public $_anchors = []; - /** @var array */ - public $_comments = []; - /** @var array */ - public $_tags = []; - /** @var int */ - public $_options; - /** @var null|string */ - public $value; - - /** - * Creates API object to be used for the document provided as argument - * - * @param YamlObject $obj the YamlObject as the target for all methods call that needs it - */ - public function __construct(int $buildingOptions) - { - $this->_options = $buildingOptions; - } - -} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Comment.php b/classes/vendor/dallgoot/yaml/sources/nodes/Comment.php deleted file mode 100644 index 1cbdd1d..0000000 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Comment.php +++ /dev/null @@ -1,26 +0,0 @@ - - * @license Apache 2.0 - * @link https://github.com/dallgoot/yaml - */ -class Comment extends NodeGeneric -{ - public function specialProcess(NodeGeneric &$previous, array &$emptyLines):bool - { - $previous->getRoot()->add($this); - return true; - } - - public function build(&$parent = null) - { - $root = $this->getRoot(); - $yamlObject = $root->getYamlObject(); - $yamlObject->addComment($this->line, $this->raw); - return null; - } -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/sources/Builder.php b/classes/vendor/dallgoot/yaml/src/Builder.php similarity index 90% rename from classes/vendor/dallgoot/yaml/sources/Builder.php rename to classes/vendor/dallgoot/yaml/src/Builder.php index c9bd1da..055e49e 100644 --- a/classes/vendor/dallgoot/yaml/sources/Builder.php +++ b/classes/vendor/dallgoot/yaml/src/Builder.php @@ -2,11 +2,10 @@ namespace Dallgoot\Yaml; -use Dallgoot\Yaml\Nodes\NodeGeneric; -use Dallgoot\Yaml\NodeList; use Dallgoot\Yaml\Nodes\Root; use Dallgoot\Yaml\Nodes\DocEnd; use Dallgoot\Yaml\Nodes\DocStart; +use Dallgoot\Yaml\Types\YamlObject; /** * Constructs the result (YamlObject or array) according to every Nodes and their values @@ -15,13 +14,12 @@ * @license Apache 2.0 * @link https://github.com/dallgoot/yaml */ -final class Builder +class Builder { - /** @var boolean */ - public $dateAsObject = false; + public bool $dateAsObject = false; - private $_options; - private $_debug = 0; + private int $_options; + private int $_debug = 0; const INVALID_DOCUMENT = "DOCUMENT %d is invalid,"; @@ -39,9 +37,9 @@ public function __construct($options, $debug) */ public function buildContent(Root $root) { - if ($this->_debug === 2) { - print_r($root); - return null; + switch ($this->_debug) { + case 2 : print_r($root); + case 1 : return null; } $documents = []; $buffer = new NodeList(); @@ -70,7 +68,7 @@ public function buildContent(Root $root) * * @return YamlObject the YAML document as an object */ - public function buildDocument(NodeList &$list, int $docNum):YamlObject + public function buildDocument(NodeList &$list, int $docNum): YamlObject { $yamlObject = new YamlObject($this->_options); $rootNode = new Root(); @@ -85,7 +83,7 @@ public function buildDocument(NodeList &$list, int $docNum):YamlObject } return $rootNode->build($yamlObject); } catch (\Throwable $e) { - throw new \ParseError(sprintf(self::INVALID_DOCUMENT, $docNum).':'.$e->getMessage(), 2, $e); + throw new \ParseError(sprintf(self::INVALID_DOCUMENT, $docNum) . ':' . $e->getMessage(), 2, $e); } } @@ -105,6 +103,4 @@ public function saveAndPush(DocStart $child, NodeList &$buffer, array &$document $buffer->push($child); } } - - } diff --git a/classes/vendor/dallgoot/yaml/src/Dumper.php b/classes/vendor/dallgoot/yaml/src/Dumper.php new file mode 100644 index 0000000..bc2b9ea --- /dev/null +++ b/classes/vendor/dallgoot/yaml/src/Dumper.php @@ -0,0 +1,149 @@ + + * @license Apache 2.0 + * @link https://github.com/dallgoot/yaml + */ +class Dumper +{ + public const INDENT = 2; + // private const WIDTH = 120; //TODO forget this feature for the moment + private const OPTIONS = 0b00000; + public const DATE_FORMAT = 'Y-m-d'; + + public $options; + //options + public const EXPAND_SHORT = 0b00001; + public const SERIALIZE_CUSTOM_OBJECTS = 0b00010; + public const USE_TILDE_AS_NULL = 0b00100; + + public int $floatPrecision = 4; + + private bool $multipleDocs = false; + + public bool $_compactMode = false; + + private ?DumperHandlers $handler; + + public const KEY_MASK_SEQ = '- %s'; + public const KEY_MASK_MAP = '%s: %s'; + + public function __construct($options = null) + { + $this->options = is_int($options) ? $options : self::OPTIONS; + $this->handler = new DumperHandlers($this); + } + /** + * Returns (as a string) the YAML representation of the $dataType provided + * + * @param mixed $dataType The data type + * + * @throws \Exception datatype cannot be null + * + * @return string The Yaml string content + */ + public function toString($dataType, ?int $options = null): string + { + if (empty($dataType)) throw new \Exception(self::class . ": No content to convert to Yaml"); + if (is_scalar($dataType)) { + return "--- " . $this->handler->dumpScalar($dataType) . PHP_EOL; + } + return $this->dump($dataType, 0, false, true); + } + + /** + * Calls and saves the result of Dumper::toString to the file $filePath provided + * + * @param mixed $dataType The data type + * + * @throws \Exception datatype cannot be null + * + * @return bool true = if the file has been correctly saved ( return value from 'file_put_contents') + */ + public function toFile(string $filePath, $dataType, ?int $options = null): bool + { + return !is_bool(file_put_contents($filePath, $this->toString($dataType, $options))); + } + + + + public function dump(mixed $dataType, int $indent, bool $isCompact = false, $isRoot = false): string + { + return match(true) { + $dataType instanceof YamlObject => $this->dumpYamlObject($dataType), + is_null($dataType) => $this->options & self::USE_TILDE_AS_NULL ? '~' : '', + is_scalar($dataType) => $this->handler->dumpScalar($dataType), + is_array($dataType) => $this->handler->dumpArray($dataType, $indent, $isCompact, $isRoot), + is_object($dataType) => $this->handler->dumpObject($dataType, $indent, $isCompact, $isRoot), + is_resource($dataType) => get_resource_type($dataType), + is_callable($dataType, false, $callable_name) => $callable_name, + default => '[Unknown Type]', + }; + } + + + public function dumpMultiDoc(array $arrayOfYamlObject): string + { + $docs = []; + foreach ($arrayOfYamlObject as $yamlObject) { + $docs[] = $this->dumpYamlObject($yamlObject); + } + return "---\n" . implode("\n---\n", $docs); + } + + /** + * Dumps an yaml object to a YAML string + * + * @todo export comment from YamlObject + */ + public function dumpYamlObject(YamlObject $obj): string + { + if ($this->multipleDocs || $obj->hasDocStart() || $obj->isTagged()) { + $this->multipleDocs = true; + // && $this->$result instanceof DLL) $this->$result->push("---"); + } + // $this->insertComments($obj->getComment()); + $properties = get_object_vars($obj); + $pairs = []; + if (count($properties) === 0) { + return $this->handler->dumpArray($obj->getArrayCopy(), 0, false, true); + }else { + return $this->handler->dumpObject($obj, 0, false, true); + } + } + + + // public function iteratorToString( + // $compound, + // string $keyMask, + // string $itemSeparator, + // int $indent, + // bool $compact = false + // ): string { + // $pairs = []; + // $valueIndent = $indent + self::INDENT; + // if(is_object($compound)) { + // $compound = get_object_vars($compound); + // } + // foreach ($compound as $key => $value) { + // $separator = "\n"; + // if (is_scalar($value) || $value instanceof \DateTime) { + // $separator = ' '; + // $valueIndent = 0; + // } + // if ($compact) { + // $pairs[] = sprintf($keyMask, $key) . $this->dump($value, $valueIndent); + // } else { + // $pairs[] = str_repeat(' ', $indent) . sprintf($keyMask, $key) . $separator . $this->dump($value, $valueIndent); + // } + // } + // return implode($itemSeparator, $pairs); + // } +} diff --git a/classes/vendor/dallgoot/yaml/src/DumperHandlers.php b/classes/vendor/dallgoot/yaml/src/DumperHandlers.php new file mode 100644 index 0000000..428278e --- /dev/null +++ b/classes/vendor/dallgoot/yaml/src/DumperHandlers.php @@ -0,0 +1,195 @@ + + * @license Apache 2.0 + * @link https://github.com/dallgoot/yaml + */ +class DumperHandlers +{ + private $dumper; + + public function __construct(Dumper $dumper) + { + $this->dumper = $dumper; + } + + + public function dumpScalar($dataType): string + { + if ($dataType === \INF) return '.inf'; + if ($dataType === -\INF) return '-.inf'; + $precision = "%." . $this->dumper->floatPrecision . "F"; + switch (gettype($dataType)) { + case 'boolean': + return $dataType ? 'true' : 'false'; + case 'float': //fall through + case 'double': + return is_nan((float) $dataType) ? '.nan' : sprintf($precision, $dataType); + } + return $this->dumpString($dataType); + } + + + // public function dumpCompound($compound, int $indent, bool $compact=false): string + // { + // if ($compact) { + // return $this->dumpCompact($compound, $indent); + // } else { + // if (is_array($compound)) { + // if (isset($compound[0]) && $compound[0] instanceof YamlObject) { + // return $this->dumper->dumpMultiDoc($compound); + // } + // $keyMask = '-'; + // $refKeys = range(0, count($compound) - 1); + // if (array_keys($compound) !== $refKeys) { + // $keyMask = '%s:'; + // } + // return $this->dumper->iteratorToString($compound, $keyMask, "\n", $indent); + // } elseif (is_object($compound) && !is_callable($compound)) { + // return $this->dumpObject($compound, $indent); + // } + // } + // throw new \Exception("Dumping Callable|Resource is not currently supported", 1); + // } + + public function dumpObject(object $object, int $indent, bool $isCompact = false, bool $isRoot = false): string + { + return match ($object::class) { + Compact::class => $this->dumpCompact($object, $indent), + Tagged::class => $this->dumpTagged($object, $indent), + \DateTime::class => $this->dumpDateTime($object), + default => $this->_object($object, $indent, $isCompact, $isRoot), + }; + } + + + public function dumpCompact(Compact $compact, int $indent, bool $isRoot = false) + { + $arr = $compact->getArrayCopy(); + if (count(get_object_vars($compact)) === 0) { + return $this->dumpArray($arr, $indent, true); + } + return $this->_objectCompact($compact, $indent, $isRoot); + } + + + public function _object(object $o, int $indent, bool $isCompact = false, $isRoot = false): string + { + return $isCompact ? $this->_objectCompact($o, $indent, $isRoot) + : $this->_objectStd($o, $indent, false, $isRoot); + } + + + public function _objectStd(object $o, int $indent, bool $isCompact = false, bool $isRoot = false) + { + $pairs = ['']; + $realIndent = $indent + Dumper::INDENT; + if($isRoot) { + $pairs = []; + $realIndent = 0; + } + foreach (get_object_vars($o) as $key => $value) { + $dumpedValue = $this->dumper->dump($value, $realIndent, $value instanceof Compact, false); + $pairs[] = sprintf("%s%s: %s", str_repeat(' ', $realIndent), $key, $dumpedValue); + } + return implode(PHP_EOL, $pairs); + } + + + public function _objectCompact(object $o, int $indent, bool $isRoot = false) + { + $pairs = []; + foreach ($o as $key => $value) { + $pairs[] = "$key: " . $this->dumper->dump($value, 0, true, false); + } + return '{'. implode(', ', $pairs) . '}'; + } + + + public function dumpArray(array $a, int $indent, bool $isCompact = false, $isRoot = false): string + { + if(isset($a[0]) && $a[0] instanceof YamlObject) { + return $this->dumper->dumpMultiDoc($a); + } + if (array_keys($a) !== range(0, count($a) - 1)) { + return $this->_object((object) $a, $indent, $isCompact, $isRoot); + } + return $isCompact ? $this->_dumpCompactArray($a, $indent) + : $this->_dumpNativeArray($a, $indent, $isRoot); + } + + + public function _dumpNativeArray(array $a, int $indent, $isRoot = false): string + { + $pairs = ['']; + $realIndent = $indent + Dumper::INDENT; + if($isRoot) { + $pairs = []; + $realIndent = 0; + } + foreach ($a as $value) { + $dumpedValue = $this->dumper->dump($value, 0, $value instanceof Compact, false); + $pairs[] = sprintf("%s- %s", str_repeat(' ', $realIndent), $dumpedValue); + } + return implode(PHP_EOL, $pairs); + } + + + public function _dumpCompactArray(array $a, int $indent): string + { + $pairs = []; + foreach ($a as $value) { + $pairs[] = $this->dumper->dump($value, $indent, true); + } + return '[' . implode(', ', $pairs) . ']'; + } + + + public function dumpDateTime(\DateTime $datetime): string + { + return $datetime->format($this->dumper::DATE_FORMAT); + } + + + /** + * Dumps a string. Protects it if needed + * + * @param string $str The string + * + * @return string ( description_of_the_return_value ) + * @todo implements checking and protection function + */ + public function dumpString(string $str): string + { + //those characters must be escaped : - : ? { } [ ] # , & * ! > | ' " % + // The “@” (#x40, at) and “`” (#x60, grave accent) are reserved for future use. + // 5.4. Line Break Characters + // Example 5.13. Escaped Characters + + $str = json_encode(ltrim($str)); + return strspn(substr($str, 1, -1), "-:?{}[]#,&*!>|'\"%") > 0 ? $str : trim($str, '"'); + } + + //TODO : handle 'php/object' + public function dumpTagged(Tagged $obj, int $indent): string + { + $separator = "\n"; + $isCompact = $obj->value instanceof Compact; + if (is_scalar($obj->value) || $isCompact) { + $separator = ' '; + } + return ($obj->tagName) . $separator . $this->dumper->dump($obj->value, $indent, $isCompact); + } + + +} diff --git a/classes/vendor/dallgoot/yaml/sources/Loader.php b/classes/vendor/dallgoot/yaml/src/Loader.php similarity index 53% rename from classes/vendor/dallgoot/yaml/sources/Loader.php rename to classes/vendor/dallgoot/yaml/src/Loader.php index 8193da4..f9d6aee 100644 --- a/classes/vendor/dallgoot/yaml/sources/Loader.php +++ b/classes/vendor/dallgoot/yaml/src/Loader.php @@ -1,9 +1,12 @@ _debug = is_null($debug) ? 0 : min($debug, 3); $this->_options = is_int($options) ? $options : $this->_options; @@ -68,31 +61,19 @@ public function __construct($absolutePath = null, $options = null, $debug = 0) * * @return self ( returns the same Loader ) */ - public function load(string $absolutePath):Loader + public function load(string $absolutePath): Loader { if (!file_exists($absolutePath)) { throw new \Exception(sprintf(self::EXCEPTION_NO_FILE, $absolutePath)); } $this->filePath = $absolutePath; - $is_php81 = (version_compare(PHP_VERSION, '8.1.0') >= 0); - - // auto_detect_line_endings - $adle_setting = "auto_detect_line_endings"; - if (!$is_php81) { - ini_set($adle_setting, "true"); - } - $content = @file($absolutePath, FILE_IGNORE_NEW_LINES); - if (!$is_php81) { - ini_restore($adle_setting); - } - if (is_bool($content)) { throw new \Exception(sprintf(self::EXCEPTION_READ_ERROR, $absolutePath)); } - $this->content = $content; + $this->content = \SplFixedArray::fromArray($content, false); return $this; } @@ -104,19 +85,21 @@ public function load(string $absolutePath):Loader * @throws \Exception if self::content is empty or splitting on linefeed has failed * @return \Generator The source iterator. */ - private function getSourceGenerator($strContent = null):\Generator + private function getSourceGenerator(?string $strContent = null): \Generator { - if (is_null($strContent) && is_null($this->content)) { - throw new \Exception(self::EXCEPTION_LINE_SPLIT); - } - if (!is_null($this->content)) { - $source = $this->content; + if (is_null($strContent)) { + if(is_null($this->content)) { + throw new \Exception(self::EXCEPTION_LINE_SPLIT); + }else { + $source = $this->content; + } } else { $simplerLineFeeds = preg_replace('/(\r\n|\r)$/', "\n", (string) $strContent); $source = preg_split("/\n/m", $simplerLineFeeds, 0, \PREG_SPLIT_DELIM_CAPTURE); - } - if (!is_array($source) || !count($source)) { - throw new \Exception(self::EXCEPTION_LINE_SPLIT); + if (!is_array($source) || !count($source)) { + throw new \Exception(self::EXCEPTION_LINE_SPLIT); + } + $source = \SplFixedArray::fromArray($source, false); } foreach ($source as $key => $value) { yield ++$key => $value; @@ -126,36 +109,37 @@ private function getSourceGenerator($strContent = null):\Generator /** * Parse Yaml lines into a hierarchy of Node * - * @param string $strContent The Yaml string or null to parse loaded content + * @param ?string $strContent The Yaml string or null to parse loaded content * * @throws \Exception if content is not available as $strContent or as $this->content (from file) * @throws \ParseError if any error during parsing or building * * @return array|YamlObject|null null on errors if NO_PARSING_EXCEPTIONS is set, otherwise an array of YamlObject or just YamlObject */ - public function parse($strContent = null) + public function parse(?string $strContent = null) { + if(!is_null($strContent)) { + $this->content = null; + } $generator = $this->getSourceGenerator($strContent); $previous = $root = new Nodes\Root(); + $debugNodeFactory = $this->_debug === 1; try { foreach ($generator as $lineNB => $lineString) { - $node = NodeFactory::get($lineString, $lineNB); - if ($this->_debug === 1) echo $lineNB.":".get_class($node)."\n"; + $node = NodeFactory::get($lineString, $lineNB, $debugNodeFactory); if ($this->needsSpecialProcess($node, $previous)) continue; $this->_attachBlankLines($previous); - switch ($node->indent <=> $previous->indent) { - case -1: $target = $previous->getTargetOnLessIndent($node); - break; - case 0: $target = $previous->getTargetOnEqualIndent($node); - break; - default: $target = $previous->getTargetOnMoreIndent($node); - } + $target = match ($node->indent <=> $previous->indent) { + -1 => $previous->getTargetOnLessIndent($node), + 0 => $previous->getTargetOnEqualIndent($node), + 1 => $previous->getTargetOnMoreIndent($node) + }; $previous = $target->add($node); } $this->_attachBlankLines($previous); - return $this->_debug === 1 ? null : (new Builder($this->_options, $this->_debug))->buildContent($root); + return (new Builder($this->_options, $this->_debug))->buildContent($root); } catch (\Throwable $e) { - $this->onError($e, $lineNB); + $this->onError($e); } } @@ -163,11 +147,11 @@ public function parse($strContent = null) /** * Attach blank (empty) Nodes saved in $_blankBuffer to their parent (it means they are meaningful content) * - * @param nodes\NodeGeneric $previous The previous Node + * @param NodeGeneric $previous The previous Node * * @return null */ - private function _attachBlankLines(Nodes\NodeGeneric $previous) + private function _attachBlankLines(NodeGeneric $previous) { foreach ($this->_blankBuffer as $blankNode) { if ($blankNode !== $previous) { @@ -180,31 +164,30 @@ private function _attachBlankLines(Nodes\NodeGeneric $previous) /** * For certain (special) Nodes types some actions are required BEFORE parent assignment * - * @param Nodes\NodeGeneric $previous The previous Node + * @param NodeGeneric $previous The previous Node * * @return boolean if True self::parse skips changing previous and adding to parent * @see self::parse */ - private function needsSpecialProcess(Nodes\NodeGeneric $current, Nodes\NodeGeneric $previous):bool + private function needsSpecialProcess(NodeGeneric $current, NodeGeneric $previous): bool { $deepest = $previous->getDeepestNode(); if ($deepest instanceof Nodes\Partial) { return $deepest->specialProcess($current, $this->_blankBuffer); - } elseif(!($current instanceof Nodes\Partial)) { + } elseif (!($current instanceof Nodes\Partial)) { return $current->specialProcess($previous, $this->_blankBuffer); } return false; } - // private function onError(\Throwable $e, \Generator $generator) - private function onError(\Throwable $e, int $lineNB) + private function onError(\Throwable $e) { $file = $this->filePath ? realpath($this->filePath) : '#YAML STRING#'; - $message = $e->getMessage()."\n ".$e->getFile().":".$e->getLine(); + $message = $e->getMessage() . "\n " . $e->getFile() . ":" . $e->getLine(); if ($this->_options & self::NO_PARSING_EXCEPTIONS) { self::$error = $message; return null; } - throw new \Exception($message." for $file:".$lineNB, 1, $e); + throw new \Exception($message . " for $file:" . $e->getLine(), 1, $e); } } diff --git a/classes/vendor/dallgoot/yaml/src/NodeFactory.php b/classes/vendor/dallgoot/yaml/src/NodeFactory.php new file mode 100644 index 0000000..9644a85 --- /dev/null +++ b/classes/vendor/dallgoot/yaml/src/NodeFactory.php @@ -0,0 +1,154 @@ + + * @license Apache 2.0 + * @link https://github.com/dallgoot/yaml + */ +class NodeFactory +{ + private const JSON_OPTIONS = \JSON_PARTIAL_OUTPUT_ON_ERROR | \JSON_UNESCAPED_SLASHES; + + final public static function get(string $nodeString, int $line = 0, bool $debug = false): NodeGeneric + { + $node = null; + $trimmed = ltrim($nodeString); + $match = (bool) preg_match(Regex::KEY, $trimmed, $matches); + $node = match(true) { + $trimmed === '' => new Blank($nodeString, $line), + str_starts_with($trimmed, '...') => new Nodes\DocEnd($nodeString, $line), + $match => new Nodes\Key($nodeString, $line, $matches), + default => self::onCharacter($trimmed[0], $nodeString, $line) + }; + if ($debug) echo $line . ":" . get_class($node) . "\n"; + return $node; + } + + + private static function onCharacter(string $first, string $nodeString, int $line): NodeGeneric + { + return match ($first) { + '-' => self::onHyphen($nodeString, $line), + '>' => new Nodes\LiteralFolded($nodeString, $line), + '|' => new Nodes\Literal($nodeString, $line), + '"', "'" => self::onQuoted($first, $nodeString, $line), + '#' => new Nodes\Comment(ltrim($nodeString), $line), + '%' => self::onDirective($nodeString, $line), + '{', '[' => self::onCompact($nodeString, $line), + ':' => new Nodes\SetValue($nodeString, $line), + '?' => new Nodes\SetKey($nodeString, $line), + '*', '&' => self::onNodeAction($nodeString, $line), + '!' => new Nodes\Tag($nodeString, $line), + default => new Nodes\Scalar($nodeString, $line), + }; + } + + + /** + * Return the correct Node Object between NodeComment OR NodeDirective + * + * @param string $nodeString The node string + * @param integer $line The line + * + * @return NodeGeneric + */ + private static function onDirective(string $nodeString, int $line): NodeGeneric + { + if ( + (bool) preg_match(Regex::DIRECTIVE_TAG, $nodeString) + || (bool) preg_match(Regex::DIRECTIVE_VERSION, $nodeString) + ) { + return new Nodes\Directive(ltrim($nodeString), $line); + } else { + throw new \ParseError("Invalid/Unknown Directive", 1); + } + } + + /** + * Set $node type and value when $nodevalue starts with a quote (simple or double) + * + * @param string $nodeString The node value + * @param int $line The line + * + * @return NodeGeneric + */ + private static function onQuoted(string $first, string $nodeString, int $line): NodeGeneric + { + return Regex::isProperlyQuoted(trim($nodeString)) ? new Nodes\Quoted($nodeString, $line) + : new Nodes\Partial($nodeString, $line); + } + + /** + * Determines the Node type and value when a compact object/array syntax is found + * + * @param string $nodeString The value assumed to start with { or [ or characters + * @param int $line The line + * + * @return NodeGeneric + */ + private static function onCompact(string $nodeString, int $line): NodeGeneric + { + json_decode($nodeString, false, 512, self::JSON_OPTIONS); + if (json_last_error() === \JSON_ERROR_NONE) { + return new Nodes\JSON($nodeString, $line); + } else { + $backtrack_setting = "pcre.backtrack_limit"; + ini_set($backtrack_setting, "-1"); + $isMapping = (bool) preg_match(Regex::MAPPING, trim($nodeString)); + $isSequence = (bool) preg_match(Regex::SEQUENCE, trim($nodeString)); + ini_restore($backtrack_setting); + + return match(true) { + $isMapping => new Nodes\CompactMapping($nodeString, $line), + $isSequence => new Nodes\CompactSequence($nodeString, $line), + default => new Nodes\Partial($nodeString, $line), + }; + } + } + + /** + * Determines Node type and value when an hyphen "-" is found + * + * @param string $nodeString The node string value + * @param int $line The line + * + * @return NodeGeneric + */ + private static function onHyphen(string $nodeString, int $line): NodeGeneric + { + return match(true) { + str_starts_with($nodeString, '---') => new Nodes\DocStart($nodeString, $line), + (bool) preg_match(Regex::ITEM, ltrim($nodeString)) => new Nodes\Item($nodeString, $line), + default => new Nodes\Scalar($nodeString, $line), + }; + } + + /** + * Sets Node type and value according to $nodeString when one of these characters is found : !,&,* + * + * @param string $nodeString The node value + * @param int $line The line + * + *@todo replace $action[0] with $first if applicable + */ + private static function onNodeAction(string $nodeString, int $line): NodeGeneric + { + if (!((bool) preg_match(Regex::NODE_ACTIONS, trim($nodeString), $matches))) { + return new Nodes\Scalar($nodeString, $line); + } + return new Nodes\Anchor($nodeString, $line); + } + +} diff --git a/classes/vendor/dallgoot/yaml/sources/NodeList.php b/classes/vendor/dallgoot/yaml/src/NodeList.php similarity index 79% rename from classes/vendor/dallgoot/yaml/sources/NodeList.php rename to classes/vendor/dallgoot/yaml/src/NodeList.php index 6f02fff..64f14d1 100644 --- a/classes/vendor/dallgoot/yaml/sources/NodeList.php +++ b/classes/vendor/dallgoot/yaml/src/NodeList.php @@ -2,15 +2,13 @@ namespace Dallgoot\Yaml; -use Dallgoot\Yaml\Nodes\NodeGeneric; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; use Dallgoot\Yaml\Nodes\Blank; use Dallgoot\Yaml\Nodes\Comment; use Dallgoot\Yaml\Nodes\Directive; use Dallgoot\Yaml\Nodes\Docstart; use Dallgoot\Yaml\Nodes\Item; use Dallgoot\Yaml\Nodes\Key; -use Dallgoot\Yaml\Nodes\SetKey; -use Dallgoot\Yaml\Nodes\SetValue; use Dallgoot\Yaml\Nodes\Scalar; @@ -44,27 +42,29 @@ public function __construct(NodeGeneric $node = null) } } - public function has(string $nodeType):bool + public function has(string $nodeType): bool { $tmp = clone $this; $tmp->rewind(); - $fqn = __NAMESPACE__."\\Nodes\\$nodeType"; + $fqn = __NAMESPACE__ . "\\Nodes\\$nodeType"; foreach ($tmp as $child) { if ($child instanceof $fqn) return true; } return false; } - public function hasContent():bool + public function hasContent(): bool { $tmp = clone $this; $tmp->rewind(); foreach ($tmp as $child) { - if (!($child instanceof Comment) + if ( + !($child instanceof Comment) && !($child instanceof Directive) && !($child instanceof Blank) && !($child instanceof Docstart - && is_null($child->value)) ) return true; + && is_null($child->value)) + ) return true; } return false; } @@ -72,13 +72,13 @@ public function hasContent():bool public function push($node): void { $type = null; - if ($node instanceof Item ) { + if ($node instanceof Item) { $type = self::SEQUENCE; } elseif ($node instanceof Key) { $type = self::MAPPING; - } elseif ($node->isOneOf('SetKey','SetValue')) { + } elseif ($node->isOneOf('SetKey', 'SetValue')) { $type = self::SET; - } elseif ($node instanceof Scalar){ + } elseif ($node instanceof Scalar) { $type = self::MULTILINE; } if (!is_null($type) && $this->checkTypeCoherence($type)) { @@ -95,14 +95,14 @@ public function push($node): void * @return boolean True if coherent, False otherwise * @todo implement invalid cases */ - public function checkTypeCoherence($estimatedType):bool + public function checkTypeCoherence($estimatedType): bool { - // if ($this->type === self::MAPPING) { - // if ($estimatedType === self::SEQUENCE) { - // throw new \ParseError("Error : no coherence in types", 1); - // } - // } - return (bool) $estimatedType; + // if ($this->type === self::MAPPING) { + // if ($estimatedType === self::SEQUENCE) { + // throw new \ParseError("Error : no coherence in types", 1); + // } + // } + return (bool) $estimatedType; } public function build(&$parent = null) @@ -110,7 +110,7 @@ public function build(&$parent = null) switch ($this->type) { case self::MAPPING: //fall through case self::SET: - $collect = $parent ?? new \StdClass; + $collect = $parent ?? new \stdClass; return $this->buildList($collect); case self::SEQUENCE: $collect = $parent ?? []; @@ -131,7 +131,7 @@ public function buildList(&$collector) return $collector; } - public function buildMultiline():string + public function buildMultiline(): string { $output = ''; $list = clone $this; @@ -142,7 +142,7 @@ public function buildMultiline():string foreach ($list as $child) { if ($child instanceof Scalar) { $separator = isset($output[-1]) && $output[-1] === "\n" ? '' : ' '; - $output .= $separator.trim($child->raw); + $output .= $separator . trim($child->raw); } elseif ($child instanceof Blank) { $output .= "\n"; } else { @@ -159,7 +159,7 @@ public function buildMultiline():string * @return NodeList a new NodeList without NodeComment in it * @todo double check that NodeComment are built */ - public function filterComment():NodeList + public function filterComment(): NodeList { $this->rewind(); $out = new NodeList; @@ -167,16 +167,15 @@ public function filterComment():NodeList if ($child instanceof Comment) { // $child->build(); } else { - if($child->value instanceof Comment) { + if ($child->value instanceof Comment) { // $child->value->build(); // $child->value = null; - } elseif($child->value instanceof NodeList) { + } elseif ($child->value instanceof NodeList) { $child->value = $child->value->filterComment(); } $out->push($child); } } - // $this->rewind(); $out->rewind(); return $out; } diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Anchor.php b/classes/vendor/dallgoot/yaml/src/Nodes/Anchor.php similarity index 71% rename from classes/vendor/dallgoot/yaml/sources/nodes/Anchor.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Anchor.php index 7f0a302..171e179 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Anchor.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Anchor.php @@ -2,6 +2,9 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\Actions; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; + /** * * @author Stéphane Rebai @@ -12,13 +15,13 @@ class Anchor extends Actions { public function &build(&$parent = null) { - $name = substr($this->anchor, 1); + $name = substr((string) $this->anchor, 1); $yamlObject = $this->getRoot()->getYamlObject(); - if ($this->anchor[0] === "*") { + if (str_starts_with((string) $this->anchor, "*")) { try { return $yamlObject->getReference($name); } catch (\Throwable $e) { - throw new \ParseError("Unknown anchor : '$name' this:".$this->anchor,1,$e); + throw new \ParseError("Unknown anchor : '$name' this:" . $this->anchor, 1, $e); } } else { $built = is_null($this->value) ? null : $this->value->build($parent); @@ -26,8 +29,8 @@ public function &build(&$parent = null) } } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { return is_null($this->value); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Blank.php b/classes/vendor/dallgoot/yaml/src/Nodes/Blank.php similarity index 65% rename from classes/vendor/dallgoot/yaml/sources/nodes/Blank.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Blank.php index 08ffb7d..941751a 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Blank.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Blank.php @@ -2,6 +2,9 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; +use Dallgoot\Yaml\Nodes\Generic\Literals; + /** * * @author Stéphane Rebai @@ -10,16 +13,16 @@ */ class Blank extends NodeGeneric { - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { - if($this->_parent instanceof NodeGeneric) { + if ($this->_parent instanceof NodeGeneric) { return $this->_parent->add($child); } else { - throw new \ParseError(__METHOD__." no parent to add to", 1); + throw new \ParseError(__METHOD__ . " no parent to add to", 1); } } - public function specialProcess(NodeGeneric &$previous, array &$emptyLines):bool + public function specialProcess(NodeGeneric &$previous, array &$emptyLines): bool { $deepest = $previous->getDeepestNode(); if ($previous instanceof Scalar) { @@ -35,13 +38,13 @@ public function build(&$parent = null) return "\n"; } - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): ?NodeGeneric { return $this->getParent($node->indent); } - public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnMoreIndent(NodeGeneric &$node): ?NodeGeneric { return $this->getParent($node->indent); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/src/Nodes/Comment.php b/classes/vendor/dallgoot/yaml/src/Nodes/Comment.php new file mode 100644 index 0000000..c21c303 --- /dev/null +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Comment.php @@ -0,0 +1,28 @@ + + * @license Apache 2.0 + * @link https://github.com/dallgoot/yaml + */ +class Comment extends NodeGeneric +{ + public function specialProcess(NodeGeneric &$previous, array &$emptyLines): bool + { + $previous->getRoot()->add($this); + return true; + } + + public function build(&$parent = null) + { + $root = $this->getRoot(); + $yamlObject = $root->getYamlObject(); + $yamlObject->addComment($this->line, $this->raw); + return null; + } +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/CompactMapping.php b/classes/vendor/dallgoot/yaml/src/Nodes/CompactMapping.php similarity index 71% rename from classes/vendor/dallgoot/yaml/sources/nodes/CompactMapping.php rename to classes/vendor/dallgoot/yaml/src/Nodes/CompactMapping.php index 8036323..8c74e1f 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/CompactMapping.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/CompactMapping.php @@ -4,8 +4,9 @@ use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\NodeList; -use Dallgoot\Yaml\Compact; +use Dallgoot\Yaml\Types\Compact; use Dallgoot\Yaml\Regex; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -15,19 +16,19 @@ */ class CompactMapping extends NodeGeneric { - public function __construct(string $nodeString, int $line) + public function __construct(string $nodeString, ?int $line) { parent::__construct($nodeString, $line); - preg_match_all(Regex::MAPPING_VALUES, trim(substr(trim($nodeString), 1,-1)), $matches); + preg_match_all(Regex::MAPPING_VALUES, trim(substr(trim($nodeString), 1, -1)), $matches); foreach ($matches['k'] as $index => $property) { - $pair = $property.': '.trim($matches['v'][$index]); - $child = NodeFactory::get($pair, $line); + $pair = $property . ': ' . trim($matches['v'][$index]); + $child = NodeFactory::get($pair, (int) $line); $child->indent = null; $this->add($child); } } - public function build(&$parent = null) + public function build(&$parent = null): ?Compact { if (is_null($this->value)) { return null; @@ -39,4 +40,4 @@ public function build(&$parent = null) $obj = (object) $this->value->build(); return new Compact($obj); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/CompactSequence.php b/classes/vendor/dallgoot/yaml/src/Nodes/CompactSequence.php similarity index 78% rename from classes/vendor/dallgoot/yaml/sources/nodes/CompactSequence.php rename to classes/vendor/dallgoot/yaml/src/Nodes/CompactSequence.php index c55e506..76b127e 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/CompactSequence.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/CompactSequence.php @@ -4,8 +4,9 @@ use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\NodeList; -use Dallgoot\Yaml\Compact; +use Dallgoot\Yaml\Types\Compact; use Dallgoot\Yaml\Regex; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -15,12 +16,12 @@ */ class CompactSequence extends NodeGeneric { - public function __construct(string $nodeString, int $line) + public function __construct(string $nodeString, ?int $line) { parent::__construct($nodeString, $line); - preg_match_all(Regex::SEQUENCE_VALUES, trim(substr(trim($nodeString), 1,-1)), $matches); + preg_match_all(Regex::SEQUENCE_VALUES, trim(substr(trim($nodeString), 1, -1)), $matches); foreach ($matches['item'] as $key => $item) { - $i = new Item('', $line); + $i = new Item('', (int) $line); $i->indent = null; $itemValue = NodeFactory::get(trim($item)); $itemValue->indent = null; @@ -29,7 +30,7 @@ public function __construct(string $nodeString, int $line) } } - public function build(&$parent = null) + public function build(&$parent = null): ?Compact { if (is_null($this->value)) { return null; @@ -41,4 +42,4 @@ public function build(&$parent = null) $arr = (array) $this->value->build(); return new Compact($arr); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Directive.php b/classes/vendor/dallgoot/yaml/src/Nodes/Directive.php similarity index 83% rename from classes/vendor/dallgoot/yaml/sources/nodes/Directive.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Directive.php index 53e61ca..01915cb 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Directive.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Directive.php @@ -2,9 +2,10 @@ namespace Dallgoot\Yaml\Nodes; -use Dallgoot\Yaml; +use Dallgoot\Yaml\Yaml; use Dallgoot\Yaml\Regex; -use Dallgoot\Yaml\TagFactory; +use Dallgoot\Yaml\Tag\TagFactory; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -15,8 +16,8 @@ class Directive extends NodeGeneric { private const ERROR_BUILDING = "Error : can not build Directive"; - private const WARNING_LOWER_VERSION = "The declared version '%s' is obsolete, there may be features that are deprecated and therefore not handled, minimum supported is: ".Yaml::VERSION_SUPPORT; - private const WARNING_HIGHER_VERSION = "The declared version '%s' is not yet supported, minimum supported is: ".Yaml::VERSION_SUPPORT; + private const WARNING_LOWER_VERSION = "The declared version '%s' is obsolete, there may be features that are deprecated and therefore not handled, minimum supported is: " . Yaml::VERSION_SUPPORT; + private const WARNING_HIGHER_VERSION = "The declared version '%s' is not yet supported, minimum supported is: " . Yaml::VERSION_SUPPORT; /** * Builds a Directive : update YamlObject if applicable. @@ -24,10 +25,8 @@ class Directive extends NodeGeneric * @param object|array $parent The parent * * @throws \ParseError If Tag handle has been already set before. - * - * @return null */ - public function build(&$parent = null) + public function build(&$parent = null): void { if (preg_match(Regex::DIRECTIVE_TAG, $this->raw, $matches)) { try { @@ -49,11 +48,11 @@ public function build(&$parent = null) // trigger_error(sprintf(self::WARNING_LOWER_VERSION, $matches['version']), \E_USER_NOTICE ); // } // } - return null; + return; } - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { return $child; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/DocEnd.php b/classes/vendor/dallgoot/yaml/src/Nodes/DocEnd.php similarity index 86% rename from classes/vendor/dallgoot/yaml/sources/nodes/DocEnd.php rename to classes/vendor/dallgoot/yaml/src/Nodes/DocEnd.php index 965d029..2a28662 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/DocEnd.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/DocEnd.php @@ -2,6 +2,8 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; + /** * * @author Stéphane Rebai @@ -15,4 +17,4 @@ public function build(&$parent = null) // Does nothing return null; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/DocStart.php b/classes/vendor/dallgoot/yaml/src/Nodes/DocStart.php similarity index 67% rename from classes/vendor/dallgoot/yaml/sources/nodes/DocStart.php rename to classes/vendor/dallgoot/yaml/src/Nodes/DocStart.php index 5552ff4..a2a2e42 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/DocStart.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/DocStart.php @@ -4,6 +4,7 @@ use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\Regex; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -13,18 +14,18 @@ */ class DocStart extends NodeGeneric { - public function __construct(string $nodeString, int $line) + public function __construct(string $nodeString, ?int $line) { parent::__construct($nodeString, $line); $rest = substr(ltrim($nodeString), 3); if (!empty($rest)) { - $n = NodeFactory::get($rest, $line); + $n = NodeFactory::get($rest, (int) $line); $n->indent = null; $this->add($n); } } - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { if ($this->value instanceof NodeGeneric) { return $this->value->add($child); @@ -36,17 +37,14 @@ public function add(NodeGeneric $child):NodeGeneric public function build(&$parent = null) { if (is_null($parent)) { - throw new \Exception(__METHOD__." expects a YamlObject as parent", 1); + throw new \Exception(__METHOD__ . " expects a YamlObject as parent", 1); } if (!is_null($this->value)) { - if ($this->value instanceof Tag){ + if ($this->value instanceof Tag) { preg_match(Regex::TAG_PARTS, $this->value->raw, $tagparts); - if (preg_match("/(?(DEFINE)".Regex::TAG_URI.')(?&url)/', $tagparts['tagname'], $matches)) { - // throw new \UnexpectedValueException("Tag '".$this->value->raw."' is invalid", 1); + if (preg_match("/(?(DEFINE)" . Regex::TAG_URI . ')(?&url)/', $tagparts['tagname'], $matches)) { $parent->addTag($tagparts['handle'], $tagparts['tagname']); - // var_dump('HERE'); } else { - // var_dump('THERE'); $this->value->build($parent); } } else { @@ -57,16 +55,16 @@ public function build(&$parent = null) return null; } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { return $this->value instanceof NodeGeneric && $this->value->isOneOf('Anchor', 'Literal', 'LiteralFolded'); } - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): NodeGeneric { if ($this->value instanceof NodeGeneric) { if ($this->value instanceof Tag) { - if (!preg_match("/".Regex::TAG_URI."/", $this->value->raw)) { + if (!preg_match("/" . Regex::TAG_URI . "/", $this->value->raw)) { return $this->value; } } elseif ($this->value->isAwaitingChild($node)) { @@ -75,4 +73,4 @@ public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric } return $this->getParent(); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/Actions.php b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/Actions.php similarity index 83% rename from classes/vendor/dallgoot/yaml/sources/nodes/abstract/Actions.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Generic/Actions.php index 8060571..62a3322 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/Actions.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/Actions.php @@ -1,8 +1,10 @@ anchor = $name; } } - - // public function build(&$parent = null) - // { - // // Nothing to do here : on purpose this method is overriden by children - // return null; - // } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/Literals.php b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/Literals.php similarity index 80% rename from classes/vendor/dallgoot/yaml/sources/nodes/abstract/Literals.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Generic/Literals.php index f660602..2b9abcf 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/Literals.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/Literals.php @@ -1,10 +1,15 @@ value)) $this->value = new NodeList(); $candidate = $child; @@ -41,19 +44,19 @@ public function add(NodeGeneric $child):NodeGeneric return parent::add($candidate); } - protected static function litteralStripLeading(NodeList &$list) + protected static function litteralStripLeading(NodeList &$list): void { $list->rewind(); - while (!$list->isEmpty() && $list->bottom() instanceof Blank) {//remove leading blank + while (!$list->isEmpty() && $list->bottom() instanceof Blank) { //remove leading blank $list->shift(); } $list->rewind(); } - protected static function litteralStripTrailing(NodeList &$list) + protected static function litteralStripTrailing(NodeList &$list): void { $list->rewind(); - while (!$list->isEmpty() && $list->top() instanceof Blank) {//remove trailing blank + while (!$list->isEmpty() && $list->top() instanceof Blank) { //remove trailing blank $list->pop(); } $list->rewind(); @@ -77,7 +80,7 @@ public function build(&$parent = null) } if (!is_null($this->value)) { $tmp = $this->getFinalString($this->value->filterComment()); - $result = $this->identifier === '-' ? $tmp : $tmp."\n"; + $result = $this->identifier === '-' ? $tmp : $tmp . "\n"; } if ($this->_parent instanceof Root) { $this->_parent->getYamlObject()->setText($result); @@ -90,13 +93,9 @@ public function build(&$parent = null) /** * Gets the correct string for child value. * - * @param object $child The child - * @param int|null $refIndent The reference indent - * - * @return string The child value. * @todo double check behaviour for KEY and ITEM */ - protected function getChildValue($child, $refIndent=0):string + protected function getChildValue(NodeGeneric $child, ?int $refIndent = 0): string { $value = $child->value; $start = ''; @@ -110,15 +109,14 @@ protected function getChildValue($child, $refIndent=0):string } } elseif ($value instanceof Scalar) { $value = new NodeList($value); - } elseif ($value instanceof NodeList && !($child instanceof Scalar)) { - $start = ltrim($child->raw)."\n"; + $start = ltrim($child->raw) . "\n"; } - return $start.$this->getFinalString($value, $refIndent); + return $start . $this->getFinalString($value, $refIndent); } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { return true; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/NodeGeneric.php b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/NodeGeneric.php similarity index 68% rename from classes/vendor/dallgoot/yaml/sources/nodes/abstract/NodeGeneric.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Generic/NodeGeneric.php index 36b7d60..ed02334 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/abstract/NodeGeneric.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Generic/NodeGeneric.php @@ -1,8 +1,11 @@ raw = $nodeString; $this->line = (int) $line; @@ -52,11 +62,8 @@ public function __construct(string $nodeString, $line = 0) /** * Sets the parent of the current Node * - * @param NodeGeneric $node The node - * - * @return NodeGeneric The currentNode */ - protected function setParent($node):NodeGeneric + protected function setParent(NodeGeneric $node): NodeGeneric { $this->_parent = $node; return $this; @@ -65,23 +72,22 @@ protected function setParent($node):NodeGeneric /** * Gets the ancestor with specified $indent or the direct $_parent * - * @param int|null $indent The indent - * - * @return NodeGeneric The parent. */ - public function getParent(int $indent = null):NodeGeneric + public function getParent(?int $indent = null): ?NodeGeneric { - if (!is_int($indent)){ + if (!is_int($indent)) { if ($this->_parent instanceof NodeGeneric) { return $this->_parent; } else { - throw new \Exception("Cannnot find a parent for ".get_class($this), 1); + throw new \Exception("Cannnot find a parent for " . get_class($this), 1); } } $cursor = $this->getParent(); - while (!($cursor instanceof Root) - && (is_null($cursor->indent) - || $cursor->indent >= $indent)) { + while ( + !($cursor instanceof Root) + && (is_null($cursor->indent) + || $cursor->indent >= $indent) + ) { if ($cursor->_parent) { $cursor = $cursor->_parent; } else { @@ -95,20 +101,18 @@ public function getParent(int $indent = null):NodeGeneric * Gets the root of the structure map (or current Yaml document) * * @throws \Exception (description) - * - * @return Root The root node. */ - protected function getRoot():Root + protected function getRoot(): Root { if (is_null($this->_parent)) { - throw new \Exception(__METHOD__.": can only be used when Node has a parent set", 1); + throw new \Exception(__METHOD__ . ": can only be used when Node has a parent set", 1); } $pointer = $this; do { if ($pointer->_parent instanceof NodeGeneric) { $pointer = $pointer->_parent; } else { - throw new \Exception("Node has no _parent set : ".get_class($pointer), 1); + throw new \Exception("Node has no _parent set : " . get_class($pointer), 1); } } while (!($pointer instanceof Root)); return $pointer; @@ -120,11 +124,8 @@ protected function getRoot():Root * - if value is Node, then value is a NodeList with (previous value AND $child) * - if value is a NodeList, push $child into * - * @param NodeGeneric $child The child - * - * @return NodeGeneric */ - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { $child->setParent($this); if (is_null($this->value)) { @@ -140,10 +141,8 @@ public function add(NodeGeneric $child):NodeGeneric /** * Gets the deepest node. - * - * @return NodeGeneric The deepest node. */ - public function getDeepestNode():NodeGeneric + public function getDeepestNode(): NodeGeneric { $cursor = $this; while ($cursor->value instanceof NodeGeneric) { @@ -152,19 +151,20 @@ public function getDeepestNode():NodeGeneric return $cursor; } - public function specialProcess(/** @scrutinizer ignore-unused */ NodeGeneric &$previous, /** @scrutinizer ignore-unused */ array &$emptyLines):bool - { + public function specialProcess( + /** @scrutinizer ignore-unused */ + NodeGeneric &$previous, + /** @scrutinizer ignore-unused */ + array &$emptyLines + ): bool { return false; } - /** + /** * Find parent target when current Node indentation is lesser than previous node indentation * - * @param NodeGeneric $node - * - * @return NodeGeneric|Key */ - public function getTargetOnLessIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnLessIndent(NodeGeneric &$node): ?NodeGeneric { $supposedParent = $this->getParent($node->indent); if ($node instanceof Item && $supposedParent instanceof Root) { @@ -185,52 +185,38 @@ public function getTargetOnLessIndent(NodeGeneric &$node):NodeGeneric /** * Find parent target when current Node indentation is equal to previous node indentation * - * @param NodeGeneric $node - * - * @return NodeGeneric */ - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): ?NodeGeneric { return $this->getParent(); } - /** + /** * Find parent target when current Node indentation is superior than previous node indentation * - * @param NodeGeneric $node - * - * @return NodeGeneric */ - public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnMoreIndent(NodeGeneric &$node): ?NodeGeneric { return $this->isAwaitingChild($node) ? $this : $this->getParent(); } - protected function isAwaitingChild(NodeGeneric $node):bool + protected function isAwaitingChild(NodeGeneric $node): bool { return false; } - /** - * - * @param Array|Object|null $parent The parent collector or NULL otherwise - * - * @return mixed whatever the build process returns - */ - public abstract function build(&$parent = null); - /** * Determines if $subject is one of the Node types provided (as strings) in $comparison array * A node type is one of the class found in "nodes" folder. * - * @param string ...$classNameList A list of string whre each is a Node type e.g. 'Key', 'Blank', etc. + * @param string ...$classNameList A list of string where each is a Node type e.g. 'Key', 'Blank', etc. * * @return boolean True if $subject is one of $comparison, False otherwise. */ - public function isOneOf(...$classNameList):bool + public function isOneOf(...$classNameList): bool { foreach ($classNameList as $className) { - $fqn = __NAMESPACE__."\\$className"; + $fqn = "Dallgoot\\Yaml\\Nodes\\$className"; if ($this instanceof $fqn) return true; } return false; @@ -241,7 +227,7 @@ public function isOneOf(...$classNameList):bool * * @return array the Node properties and respective values displayed by 'var_dump' */ - public function __debugInfo():array + public function __debugInfo(): array { $props = []; $props['line->indent'] = "$this->line -> $this->indent"; diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Item.php b/classes/vendor/dallgoot/yaml/src/Nodes/Item.php similarity index 82% rename from classes/vendor/dallgoot/yaml/sources/nodes/Item.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Item.php index f0d2643..59c1384 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Item.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Item.php @@ -2,9 +2,10 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\Regex; -use Dallgoot\Yaml\YamlObject; +use Dallgoot\Yaml\Types\YamlObject; /** * @@ -26,23 +27,23 @@ public function __construct(string $nodeString, int $line) } } - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { $value = $this->value; if ($value instanceof Key && $child instanceof Key) { if ($value->indent === $child->indent) { return parent::add($child); - } elseif ($value->isAwaitingChild($child)){ + } elseif ($value->isAwaitingChild($child)) { return $value->add($child); } else { // throw new \ParseError('key ('.$value->identifier.')@'.$value->line.' has already a value', 1); - throw new \ParseError('key @'.$value->line.' has already a value', 1); + throw new \ParseError('key @' . $value->line . ' has already a value', 1); } } return parent::add($child); } - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): NodeGeneric { $supposedParent = $this->getParent(); if ($node->indent === $supposedParent->indent) { @@ -51,7 +52,7 @@ public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric return $supposedParent; } - public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnMoreIndent(NodeGeneric &$node): NodeGeneric { return $this->value instanceof NodeGeneric && $this->value->isAwaitingChild($node) ? $this->value : $this; } @@ -62,12 +63,11 @@ public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric * @param array|YamlObject|null $parent The parent * * @throws \Exception if parent is another type than array or object Iterator - * @return null|array */ - public function build(&$parent = null) + public function build(&$parent = null): ?array { if (!is_null($parent) && !is_array($parent) && !($parent instanceof YamlObject)) { - throw new \Exception("parent must be an array or YamlObject not ". + throw new \Exception("parent must be an array or YamlObject not " . (is_object($parent) ? get_class($parent) : gettype($parent))); } $value = $this->value ? $this->value->build() : null; @@ -79,10 +79,11 @@ public function build(&$parent = null) // $key = count($numKeys) > 0 ? max($numKeys) + 1 : 0; // $parent[$key] = $value; $parent[] = $value; + return null; } } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { if (is_null($this->value)) { return true; @@ -92,4 +93,4 @@ public function isAwaitingChild(NodeGeneric $node):bool return $this->getDeepestNode()->isAwaitingChild($node); } } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/JSON.php b/classes/vendor/dallgoot/yaml/src/Nodes/JSON.php similarity index 70% rename from classes/vendor/dallgoot/yaml/sources/nodes/JSON.php rename to classes/vendor/dallgoot/yaml/src/Nodes/JSON.php index 9b14d0e..dd94bd9 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/JSON.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/JSON.php @@ -2,6 +2,8 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; + /** * * @author Stéphane Rebai @@ -10,10 +12,10 @@ */ class JSON extends NodeGeneric { - private const JSON_OPTIONS = \JSON_PARTIAL_OUTPUT_ON_ERROR|\JSON_UNESCAPED_SLASHES; + private const JSON_OPTIONS = \JSON_PARTIAL_OUTPUT_ON_ERROR | \JSON_UNESCAPED_SLASHES; public function build(&$parent = null) { return json_decode($this->raw, false, 512, self::JSON_OPTIONS); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Key.php b/classes/vendor/dallgoot/yaml/src/Nodes/Key.php similarity index 81% rename from classes/vendor/dallgoot/yaml/sources/nodes/Key.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Key.php index 4be08e8..c3706b5 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Key.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Key.php @@ -2,6 +2,8 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; +use Dallgoot\Yaml\Nodes\Generic\Literals; use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\Regex; @@ -13,7 +15,7 @@ */ class Key extends NodeGeneric { - const ERROR_NO_KEYNAME = self::class.": key has NO IDENTIFIER on line %d"; + const ERROR_NO_KEYNAME = self::class . ": key has NO IDENTIFIER on line %d"; public function __construct(string $nodeString, int $line, array $matches = null) { @@ -33,10 +35,10 @@ public function __construct(string $nodeString, int $line, array $matches = null } } - public function setIdentifier(string $keyString) + public function setIdentifier(string $keyString): void { if ($keyString === '') { - throw new \ParseError(sprintf(self::ERROR_NO_KEYNAME, $this->line)); + throw new \ParseError(sprintf(self::ERROR_NO_KEYNAME, $this->line)); } else { $node = NodeFactory::get($keyString); if ($node->isOneOf('Tag', 'Quoted')) { @@ -52,16 +54,16 @@ public function setIdentifier(string $keyString) } } - public function add(NodeGeneric $child):NodeGeneric + public function add(NodeGeneric $child): NodeGeneric { - if ($this->value instanceof NodeGeneric && $this->value->isOneOf('Literal','LiteralFolded', 'Anchor')) { + if ($this->value instanceof NodeGeneric && $this->value->isOneOf('Literal', 'LiteralFolded', 'Anchor')) { return $this->value->add($child); } else { return parent::add($child); } } - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): NodeGeneric { if ($node instanceof Item) { return $this; @@ -69,7 +71,7 @@ public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric return $this->getParent(); } - public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnMoreIndent(NodeGeneric &$node): NodeGeneric { if (!is_null($this->value)) { if ($this->getDeepestNode()->isAwaitingChild($node)) { @@ -80,11 +82,11 @@ public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { if (is_null($this->value) || $node instanceof Comment) { return true; - } elseif($this->value instanceof NodeGeneric) { + } elseif ($this->value instanceof NodeGeneric) { $current = $this->value; } else { $current = $this->value->current(); @@ -114,22 +116,21 @@ public function isAwaitingChild(NodeGeneric $node):bool * @param object|array $parent The parent * * @throws \ParseError if Key has no name(identifier) Note: empty string is allowed - * @return null|\StdClass */ - public function build(&$parent = null) + public function build(&$parent = null): ?object { - // var_dump("DEBUG KEY:".$this->identifier); if ($this->value instanceof Anchor) { $result = &$this->value->build(); } else { $result = is_null($this->value) ? null : $this->value->build(); } if (is_null($parent)) { - $parent = new \StdClass; + $parent = new \stdClass; $parent->{$this->identifier} = &$result; return $parent; } else { $parent->{$this->identifier} = &$result; + return null; } } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Literal.php b/classes/vendor/dallgoot/yaml/src/Nodes/Literal.php similarity index 76% rename from classes/vendor/dallgoot/yaml/sources/nodes/Literal.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Literal.php index 15cb95e..1d625dd 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Literal.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Literal.php @@ -3,6 +3,7 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeList; +use Dallgoot\Yaml\Nodes\Generic\Literals; /** * @@ -12,12 +13,12 @@ */ class Literal extends Literals { - public function getFinalString(NodeList $list, int $refIndent = null):string + public function getFinalString(NodeList $list, ?int $refIndent = null): string { $result = ''; $list = $list->filterComment(); if ($this->identifier !== '+') { - self::litteralStripTrailing($list); + self::litteralStripTrailing($list); } if ($list->count()) { $list->setIteratorMode(NodeList::IT_MODE_DELETE); @@ -28,11 +29,11 @@ public function getFinalString(NodeList $list, int $refIndent = null):string $value = "\n"; if (!($child instanceof Blank)) { $newIndent = $indent > 0 ? $child->indent - $indent : 0; - $value .= str_repeat(' ', $newIndent).$this->getChildValue($child, $indent); + $value .= str_repeat(' ', $newIndent) . $this->getChildValue($child, $indent); } $result .= $value; } } return $result; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/LiteralFolded.php b/classes/vendor/dallgoot/yaml/src/Nodes/LiteralFolded.php similarity index 72% rename from classes/vendor/dallgoot/yaml/sources/nodes/LiteralFolded.php rename to classes/vendor/dallgoot/yaml/src/Nodes/LiteralFolded.php index e5a26e4..ee56860 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/LiteralFolded.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/LiteralFolded.php @@ -3,6 +3,7 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeList; +use Dallgoot\Yaml\Nodes\Generic\Literals; /** * @@ -16,13 +17,13 @@ class LiteralFolded extends Literals * @todo Example 6.1. Indentation Spaces spaces must be considered as content, * Whend indent is reduced : do we insert a line break too ? */ - public function getFinalString(NodeList $value, int $refIndent = null):string + public function getFinalString(NodeList $value, ?int $refIndent = null): string { $result = ''; $list = $value->filterComment(); if ($this->identifier !== '+') { - self::litteralStripLeading($list); - self::litteralStripTrailing($list); + self::litteralStripLeading($list); + self::litteralStripTrailing($list); } if ($list->count()) { $refSeparator = ' '; @@ -31,12 +32,12 @@ public function getFinalString(NodeList $value, int $refIndent = null):string $result = $this->getChildValue($first, $indent); foreach ($list as $child) { $separator = ($result && $result[-1] === "\n") ? '' : $refSeparator; - if($child->indent > $indent || $child instanceof Blank) { + if ($child->indent > $indent || $child instanceof Blank) { $separator = "\n"; } - $result .= $separator .$this->getChildValue($child, $indent); + $result .= $separator . $this->getChildValue($child, $indent); } } return $result; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Partial.php b/classes/vendor/dallgoot/yaml/src/Nodes/Partial.php similarity index 88% rename from classes/vendor/dallgoot/yaml/sources/nodes/Partial.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Partial.php index e425279..9342d10 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Partial.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Partial.php @@ -3,6 +3,7 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeFactory; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -20,7 +21,7 @@ class Partial extends NodeGeneric * * @return boolean true to skip normal Loader process, false to continue */ - public function specialProcess(NodeGeneric &$current, array &$emptyLines):bool + public function specialProcess(NodeGeneric &$current, array &$emptyLines): bool { $parent = $this->getParent(); $addValue = ltrim($current->raw); @@ -32,7 +33,7 @@ public function specialProcess(NodeGeneric &$current, array &$emptyLines):bool $addValue = "\n"; $separator = ''; } - $node = NodeFactory::get($this->raw.$separator.$addValue, $this->line); + $node = NodeFactory::get($this->raw . $separator . $addValue, $this->line); $node->indent = null; $parent->value = null; $parent->add($node); @@ -43,4 +44,4 @@ public function build(&$parent = null) { throw new \ParseError("Partial value found at line $this->line", 1); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Quoted.php b/classes/vendor/dallgoot/yaml/src/Nodes/Quoted.php similarity index 85% rename from classes/vendor/dallgoot/yaml/sources/nodes/Quoted.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Quoted.php index aa8874c..b6ecaa9 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Quoted.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Quoted.php @@ -2,6 +2,8 @@ namespace Dallgoot\Yaml\Nodes; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; + /** * * @author Stéphane Rebai @@ -13,6 +15,6 @@ class Quoted extends NodeGeneric public function build(&$parent = null) { // return substr(Scalar::replaceSequences(trim($this->raw)), 1,-1); - return (new Scalar('', 0))->replaceSequences(substr(trim($this->raw), 1,-1)); + return (new Scalar('', 0))->replaceSequences(substr(trim($this->raw), 1, -1)); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Root.php b/classes/vendor/dallgoot/yaml/src/Nodes/Root.php similarity index 64% rename from classes/vendor/dallgoot/yaml/sources/nodes/Root.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Root.php index c54f263..7c5e478 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Root.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Root.php @@ -3,7 +3,8 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeList; -use Dallgoot\Yaml\YamlObject; +use Dallgoot\Yaml\Types\YamlObject; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -13,9 +14,8 @@ */ class Root extends NodeGeneric { - /** @var null|YamlObject */ - private $_yamlObject; - /** @var NodeList */ + private ?YamlObject $_yamlObject = null; + public $value; public function __construct() @@ -23,20 +23,20 @@ public function __construct() $this->value = new NodeList(); } - public function getParent(int $indent = null, $type = 0):NodeGeneric + public function getParent(?int $indent = null, $type = 0): NodeGeneric { if ($this->_parent !== null) { - throw new \ParseError(__CLASS__." can NOT have a parent, something's wrong", 1); + throw new \ParseError(__CLASS__ . " can NOT have a parent, something's wrong", 1); } return $this; } - public function getRoot():Root + public function getRoot(): Root { return $this; } - public function getYamlObject():YamlObject + public function getYamlObject(): YamlObject { if ($this->_yamlObject) { return $this->_yamlObject; @@ -44,19 +44,18 @@ public function getYamlObject():YamlObject throw new \Exception("YamlObject has not been set yet", 1); } - public function build(&$parent = null) + public function build(&$parent = null): YamlObject { return $this->buildFinal($parent); } - private function buildFinal(YamlObject $yamlObject):YamlObject + private function buildFinal(YamlObject $yamlObject): YamlObject { $this->_yamlObject = $yamlObject; $this->value->setIteratorMode(NodeList::IT_MODE_DELETE); - // $this->value->rewind(); foreach ($this->value as $key => $child) { $child->build($yamlObject); } return $yamlObject; } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Scalar.php b/classes/vendor/dallgoot/yaml/src/Nodes/Scalar.php similarity index 70% rename from classes/vendor/dallgoot/yaml/sources/nodes/Scalar.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Scalar.php index 6aa1749..d405a3b 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Scalar.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Scalar.php @@ -3,10 +3,11 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeFactory; -use Dallgoot\Yaml\TagFactory; +use Dallgoot\Yaml\Tag\TagFactory; use Dallgoot\Yaml\NodeList; use Dallgoot\Yaml\Regex; use Dallgoot\Yaml\Loader; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -23,14 +24,14 @@ public function __construct(string $nodeString, int $line) if ($value !== '') { $hasComment = strpos($value, ' #'); if (!is_bool($hasComment)) { - $realValue = trim(substr($value, 0, $hasComment)); - $commentValue = trim(substr($value, $hasComment)); - $realNode = NodeFactory::get($realValue, $line); - $realNode->indent = null; - $commentNode = NodeFactory::get($commentValue, $line); - $commentNode->indent = null; - $this->add($realNode); - $this->add($commentNode); + $realValue = trim(substr($value, 0, $hasComment)); + $commentValue = trim(substr($value, $hasComment)); + $realNode = NodeFactory::get($realValue, $line); + $realNode->indent = null; + $commentNode = NodeFactory::get($commentValue, $line); + $commentNode->indent = null; + $this->add($realNode); + $this->add($commentNode); } } } @@ -47,16 +48,16 @@ public function build(&$parent = null) return is_null($this->value) ? $this->getScalar(trim($this->raw)) : $this->value->build(); } - public function getTargetOnLessIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnLessIndent(NodeGeneric &$node): NodeGeneric { - if ($node instanceof Scalar || $node instanceof Blank ) { + if ($node instanceof Scalar || $node instanceof Blank) { return $this->getParent(); } else { return $this->getParent($node->indent); } } - public function getTargetOnMoreIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnMoreIndent(NodeGeneric &$node): NodeGeneric { return $this->getParent(); } @@ -98,44 +99,41 @@ public function getScalar(string $v, bool $onlyScalar = false) */ if (Regex::isDate($v)) return ($this->getRoot()->getYamlObject()->getOptions() & Loader::NO_OBJECT_FOR_DATE) && !$onlyScalar ? date_create($v) : $v; if (Regex::isNumber($v)) return $this->getNumber($v); - $types = ['yes' => true, - 'no' => false, - 'true' => true, - 'false' => false, - 'null' => null, - '.inf' => \INF, - '-.inf' => -\INF, - '.nan' => \NAN + $types = [ + 'yes' => true, + 'no' => false, + 'true' => true, + 'false' => false, + 'null' => null, + '.inf' => \INF, + '-.inf' => -\INF, + '.nan' => \NAN ]; return array_key_exists(strtolower($v), $types) ? $types[strtolower($v)] : $this->replaceSequences($v); } - public function replaceSequences($value='') + public function replaceSequences(string $value = ''): string { - $replaceUnicodeSeq = function ($matches) { - return json_decode('"'.$matches[1].'"'); - }; - $replaceNonPrintable = function ($matches) { - // var_dump($matches[1]); - return $matches[1].""; - }; -// preg_match( "/[^\x{06F0}-\x{06F9}\x]+/u" , '۱۲۳۴۵۶۷۸۹۰' ); - return preg_replace_callback_array( - [ - '/((? $replaceUnicodeSeq, - '/((? $replaceUnicodeSeq, - '/(\\\\b|\\\\n|\\\\t|\\\\r)/' => $replaceNonPrintable - ], - $value - ); + $replaceUnicodeSeq = function ($matches) { + return json_decode('"' . $matches[1] . '"'); + }; + $replaceNonPrintable = function ($matches) { + return $matches[1] . ""; + }; + return preg_replace_callback_array( + [ + '/((? $replaceUnicodeSeq, + '/((? $replaceUnicodeSeq, + '/(\\\\b|\\\\n|\\\\t|\\\\r)/' => $replaceNonPrintable + ], + $value + ); } /** * Returns the correct PHP type according to the string value * - * @param string $v a string value - * * @return int|float The scalar value with appropriate PHP type * @todo or scientific notation matching the regular expression -? [1-9] ( \. [0-9]* [1-9] )? ( e [-+] [1-9] [0-9]* )? */ @@ -145,5 +143,4 @@ private function getNumber(string $v) if ((bool) preg_match(Regex::HEX_NUM, $v)) return intval(base_convert($v, 16, 10)); return is_bool(strpos($v, '.')) || substr_count($v, '.') > 1 ? intval($v) : floatval($v); } - -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/SetKey.php b/classes/vendor/dallgoot/yaml/src/Nodes/SetKey.php similarity index 83% rename from classes/vendor/dallgoot/yaml/sources/nodes/SetKey.php rename to classes/vendor/dallgoot/yaml/src/Nodes/SetKey.php index d206936..e689f4b 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/SetKey.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/SetKey.php @@ -4,6 +4,7 @@ use Dallgoot\Yaml\NodeFactory; use Dallgoot\Yaml\Regex; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -32,15 +33,15 @@ public function __construct(string $nodeString, int $line) public function build(&$parent = null) { $built = is_null($this->value) ? null : $this->value->build(); - $stringKey = is_string($built) && Regex::isProperlyQuoted($built) ? trim($built, '\'" '): $built; - $key = json_encode($stringKey, JSON_PARTIAL_OUTPUT_ON_ERROR|JSON_UNESCAPED_SLASHES); - if (empty($key)) throw new \Exception("Cant serialize complex key: ".var_export($this->value, true)); + $stringKey = is_string($built) && Regex::isProperlyQuoted($built) ? trim($built, '\'" ') : $built; + $key = json_encode($stringKey, JSON_PARTIAL_OUTPUT_ON_ERROR | JSON_UNESCAPED_SLASHES); + if (empty($key)) throw new \Exception("Cant serialize complex key: " . var_export($this->value, true)); $parent->{trim($key, '\'" ')} = null; return null; } - public function isAwaitingChild(NodeGeneric $child):bool + public function isAwaitingChild(NodeGeneric $child): bool { return is_null($this->value); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/SetValue.php b/classes/vendor/dallgoot/yaml/src/Nodes/SetValue.php similarity index 84% rename from classes/vendor/dallgoot/yaml/sources/nodes/SetValue.php rename to classes/vendor/dallgoot/yaml/src/Nodes/SetValue.php index 0cc242e..7b8250a 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/SetValue.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/SetValue.php @@ -3,6 +3,7 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeFactory; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; /** * @@ -32,12 +33,12 @@ public function build(&$parent = null) { $prop = array_keys(get_object_vars($parent)); $key = end($prop); - $parent->{$key} = is_null($this->value) ? null: $this->value->build(); + $parent->{$key} = is_null($this->value) ? null : $this->value->build(); return null; } - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { return is_null($this->value) || $this->getDeepestNode()->isAwaitingChild($node); } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/nodes/Tag.php b/classes/vendor/dallgoot/yaml/src/Nodes/Tag.php similarity index 72% rename from classes/vendor/dallgoot/yaml/sources/nodes/Tag.php rename to classes/vendor/dallgoot/yaml/src/Nodes/Tag.php index b60f2f1..eeeb8ae 100644 --- a/classes/vendor/dallgoot/yaml/sources/nodes/Tag.php +++ b/classes/vendor/dallgoot/yaml/src/Nodes/Tag.php @@ -3,9 +3,11 @@ namespace Dallgoot\Yaml\Nodes; use Dallgoot\Yaml\NodeList; -use Dallgoot\Yaml\TagFactory; -use Dallgoot\Yaml\Tagged; +use Dallgoot\Yaml\Tag\TagFactory; +use Dallgoot\Yaml\Types\Tagged; use Dallgoot\Yaml\Regex; +use Dallgoot\Yaml\Nodes\Generic\NodeGeneric; +use Dallgoot\Yaml\Nodes\Generic\Actions; /** * @@ -17,12 +19,12 @@ class Tag extends Actions { - public function isAwaitingChild(NodeGeneric $node):bool + public function isAwaitingChild(NodeGeneric $node): bool { return is_null($this->value); } - public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric + public function getTargetOnEqualIndent(NodeGeneric &$node): NodeGeneric { if (is_null($this->value) && $this->indent > 0) { return $this; @@ -36,12 +38,12 @@ public function getTargetOnEqualIndent(NodeGeneric &$node):NodeGeneric * * @param array|object|null $parent The parent * - * @return Tagged|mixed The tag object of class Dallgoot\Yaml\Tagged. + * @return Tagged|mixed The tag object of class Dallgoot\Yaml\Types\Tagged. */ public function build(&$parent = null) { if (is_null($this->value) && $this->getParent() instanceof Root) { - if (!preg_match(Regex::TAG_PARTS, $this->tag, $matches)) { + if (!preg_match(Regex::TAG_PARTS, (string) $this->tag, $matches)) { throw new \UnexpectedValueException("Tag '$this->tag' is invalid", 1); } $handle = $matches['handle']; @@ -51,15 +53,18 @@ public function build(&$parent = null) } $value = $this->value; if (is_null($parent) && $value instanceof NodeGeneric && $value->isOneOf('Item', 'Key')) { - $value = new NodeList(/** @scrutinizer ignore-type */ $value); + $value = new NodeList( + /** @scrutinizer ignore-type */ + $value + ); } try { $transformed = TagFactory::transform((string) $this->tag, $value, $parent); return $transformed; } catch (\UnexpectedValueException $e) { - return new Tagged($this->tag, is_null($value) ? null : $this->value->build($parent)); + return new Tagged((string) $this->tag, is_null($value) ? null : $this->value->build($parent)); } catch (\Throwable $e) { throw new \Exception("Tagged value could not be transformed for tag '$this->tag'", 1, $e);; } } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/sources/Regex.php b/classes/vendor/dallgoot/yaml/src/Regex.php similarity index 100% rename from classes/vendor/dallgoot/yaml/sources/Regex.php rename to classes/vendor/dallgoot/yaml/src/Regex.php diff --git a/classes/vendor/dallgoot/yaml/sources/tag/CoreSchema.php b/classes/vendor/dallgoot/yaml/src/Tag/CoreSchema.php similarity index 85% rename from classes/vendor/dallgoot/yaml/sources/tag/CoreSchema.php rename to classes/vendor/dallgoot/yaml/src/Tag/CoreSchema.php index fc9edc1..b0b8c05 100644 --- a/classes/vendor/dallgoot/yaml/sources/tag/CoreSchema.php +++ b/classes/vendor/dallgoot/yaml/src/Tag/CoreSchema.php @@ -1,9 +1,11 @@ value; } - if ($node instanceof Nodes\NodeGeneric) { + if ($node instanceof NodeGeneric) { $value = trim($node->raw); if ($node instanceof Nodes\Quoted) { $value = $node->build(); @@ -72,7 +74,7 @@ public function str($node, &$parent = null) $list[] = $this->str($child); } // return new Nodes\Scalar(implode('',$list), 0); - return implode('',$list); + return implode('', $list); } } @@ -80,11 +82,10 @@ public function str($node, &$parent = null) * Specific Handler for 'binary' tag * * @param object $node The node or NodeList - * @param object|array|null $parent The parent * * @return string The value considered as 'binary' Note: the difference with strHandler is that multiline have not separation */ - public function binary($node, Nodes\NodeGeneric &$parent = null) + public function binary($node, NodeGeneric &$parent = null) { return $this->str($node, $parent); } @@ -103,7 +104,7 @@ public function set($node, &$parent = null) if (!($node instanceof NodeList)) { throw new \LogicException(self::ERROR_SET); } else { - $list = $parent ?? new \StdClass; + $list = $parent ?? new \stdClass; $node->rewind(); foreach ($node as $key => $item) { $this->omap($item, $list); @@ -126,14 +127,14 @@ public function set($node, &$parent = null) */ public function omap($node, &$parent = null) { - if ($node instanceof Nodes\NodeGeneric) { + if ($node instanceof NodeGeneric) { if ($node instanceof Nodes\Item && $node->value instanceof Nodes\Key) { $key = $node->value; $keyName = $key->identifier; $keyValue = $key->value->build(); if (is_null($parent)) { return [$keyName => $keyValue]; - } else{ + } else { $parent[$keyName] = $keyValue; } } else { @@ -151,5 +152,4 @@ public function omap($node, &$parent = null) } } } - } diff --git a/classes/vendor/dallgoot/yaml/sources/tag/SchemaInterface.php b/classes/vendor/dallgoot/yaml/src/Tag/SchemaInterface.php similarity index 100% rename from classes/vendor/dallgoot/yaml/sources/tag/SchemaInterface.php rename to classes/vendor/dallgoot/yaml/src/Tag/SchemaInterface.php diff --git a/classes/vendor/dallgoot/yaml/sources/tag/SymfonySchema.php b/classes/vendor/dallgoot/yaml/src/Tag/SymfonySchema.php similarity index 62% rename from classes/vendor/dallgoot/yaml/sources/tag/SymfonySchema.php rename to classes/vendor/dallgoot/yaml/src/Tag/SymfonySchema.php index ac8cd9a..e701388 100644 --- a/classes/vendor/dallgoot/yaml/sources/tag/SymfonySchema.php +++ b/classes/vendor/dallgoot/yaml/src/Tag/SymfonySchema.php @@ -1,9 +1,9 @@ raw); // NOTE : we assume this is only used for Object types (if a boolean false is serialized this will FAIL) if (is_bool($phpObject)) { @@ -40,8 +37,15 @@ public final static function PHPobjectHandler(object $node) } } - public function __call($name, $arguments) { + public function __call($name, $arguments) + { //TODO : handle 'php/object' - throw new \Exception("no handler for tag '$name' in ".self::class, 1); + if(in_array($name, ['php/object'])) { + return match($name) { + 'php/object' => self::PHPobjectHandler($arguments), + default => null, + }; + } + throw new \Exception("no handler for tag '$name' in " . self::class, 1); } } diff --git a/classes/vendor/dallgoot/yaml/sources/tag/TagFactory.php b/classes/vendor/dallgoot/yaml/src/Tag/TagFactory.php similarity index 87% rename from classes/vendor/dallgoot/yaml/sources/tag/TagFactory.php rename to classes/vendor/dallgoot/yaml/src/Tag/TagFactory.php index 1e79af9..267d75b 100644 --- a/classes/vendor/dallgoot/yaml/sources/tag/TagFactory.php +++ b/classes/vendor/dallgoot/yaml/src/Tag/TagFactory.php @@ -1,7 +1,10 @@ build($parent)); // } catch (\Throwable $e) { @@ -138,5 +143,4 @@ public static function runHandler($handle, $tagname, $value, &$parent = null) } throw new \UnexpectedValueException("Error Processing tag '$tagname' : in $handle", 1); } - } diff --git a/classes/vendor/dallgoot/yaml/sources/tag/notes.yml b/classes/vendor/dallgoot/yaml/src/Tag/notes.yml similarity index 100% rename from classes/vendor/dallgoot/yaml/sources/tag/notes.yml rename to classes/vendor/dallgoot/yaml/src/Tag/notes.yml diff --git a/classes/vendor/dallgoot/yaml/sources/types/Compact.php b/classes/vendor/dallgoot/yaml/src/Types/Compact.php similarity index 77% rename from classes/vendor/dallgoot/yaml/sources/types/Compact.php rename to classes/vendor/dallgoot/yaml/src/Types/Compact.php index 7c506f6..901777b 100644 --- a/classes/vendor/dallgoot/yaml/sources/types/Compact.php +++ b/classes/vendor/dallgoot/yaml/src/Types/Compact.php @@ -1,6 +1,6 @@ Array indices can be accessed as properties in read/write. - parent::__construct(/** @scrutinizer ignore-type */ $candidate, \ArrayIterator::STD_PROP_LIST|\ArrayIterator::ARRAY_AS_PROPS); + parent::__construct( + /** @scrutinizer ignore-type */ + $candidate, \ArrayIterator::STD_PROP_LIST | \ArrayIterator::ARRAY_AS_PROPS); } /** @@ -28,7 +31,7 @@ public function __construct($candidate = null) * * @return array */ - public function jsonSerialize():array + public function jsonSerialize(): array { $prop = get_object_vars($this); return count($prop) > 0 ? $prop : iterator_to_array($this); diff --git a/classes/vendor/dallgoot/yaml/sources/types/Tagged.php b/classes/vendor/dallgoot/yaml/src/Types/Tagged.php similarity index 86% rename from classes/vendor/dallgoot/yaml/sources/types/Tagged.php rename to classes/vendor/dallgoot/yaml/src/Types/Tagged.php index 2a583d6..979dd15 100644 --- a/classes/vendor/dallgoot/yaml/sources/types/Tagged.php +++ b/classes/vendor/dallgoot/yaml/src/Types/Tagged.php @@ -1,5 +1,6 @@ __yaml__object__api->value ?? serialize($this); } @@ -47,7 +50,6 @@ public function getOptions() /** * Adds a reference. * - * @param string $name The reference name * @param mixed $value The reference value * * @throws \UnexpectedValueException (description) @@ -58,7 +60,6 @@ public function &addReference(string $name, $value) if (empty($name)) { throw new \UnexpectedValueException(self::UNAMED_REFERENCE); } - // var_dump("DEBUG: '$name' added as reference"); $this->__yaml__object__api->_anchors[$name] = $value; return $this->__yaml__object__api->_anchors[$name]; } @@ -66,19 +67,21 @@ public function &addReference(string $name, $value) /** * Return the reference saved by $name * - * @param string $name Name of the reference - * * @return mixed Value of the reference * @throws \UnexpectedValueException if there's no reference by that $name */ - public function &getReference($name) + public function &getReference(string $name) { if (array_key_exists($name, $this->__yaml__object__api->_anchors)) { return $this->__yaml__object__api->_anchors[$name]; } - throw new \UnexpectedValueException(sprintf(self::UNKNOWN_REFERENCE, - $name, implode(',',array_keys($this->__yaml__object__api->_anchors))) - ); + throw new \UnexpectedValueException( + sprintf( + self::UNKNOWN_REFERENCE, + $name, + implode(',', array_keys($this->__yaml__object__api->_anchors)) + ) + ); } /** @@ -86,7 +89,7 @@ public function &getReference($name) * * @return array */ - public function getAllReferences():array + public function getAllReferences(): array { return $this->__yaml__object__api->_anchors; } @@ -99,7 +102,7 @@ public function getAllReferences():array * * @return null */ - public function addComment(int $lineNumber, string $value) + public function addComment(int $lineNumber, string $value): void { $this->__yaml__object__api->_comments[$lineNumber] = $value; } @@ -107,13 +110,11 @@ public function addComment(int $lineNumber, string $value) /** * Gets the comment at $lineNumber * - * @param int|null $lineNumber The line number - * - * @return string|array The comment at $lineNumber OR all comments. + * @return string|array The comment at $lineNumber OR all comments. */ - public function getComment(int $lineNumber = null) + public function getComment(?int $lineNumber = 0) { - if (array_key_exists((int) $lineNumber, $this->__yaml__object__api->_comments)) { + if (array_key_exists((string) $lineNumber, $this->__yaml__object__api->_comments)) { return $this->__yaml__object__api->_comments[$lineNumber]; } return $this->__yaml__object__api->_comments; @@ -121,12 +122,8 @@ public function getComment(int $lineNumber = null) /** * Sets the text when the content is *only* a literal - * - * @param string $value The value - * - * @return YamlObject */ - public function setText(string $value):YamlObject + public function setText(string $value): YamlObject { $this->__yaml__object__api->value .= ltrim($value); return $this; @@ -155,7 +152,7 @@ public function addTag(string $handle, string $prefix) * * @return boolean True if document has start, False otherwise. */ - public function hasDocStart():bool + public function hasDocStart(): bool { return is_bool($this->__yaml__object__api->_hasDocStart); } @@ -187,7 +184,8 @@ public function isTagged() * * @return mixed Array (of object properties or keys) OR string if YAML object only contains LITTERAL (in self::value) */ - public function jsonSerialize(): mixed + #[\ReturnTypeWillChange] + public function jsonSerialize() { $prop = get_object_vars($this); unset($prop["__yaml__object__api"]); diff --git a/classes/vendor/dallgoot/yaml/sources/Yaml.php b/classes/vendor/dallgoot/yaml/src/Yaml.php similarity index 63% rename from classes/vendor/dallgoot/yaml/sources/Yaml.php rename to classes/vendor/dallgoot/yaml/src/Yaml.php index f569530..d267f72 100644 --- a/classes/vendor/dallgoot/yaml/sources/Yaml.php +++ b/classes/vendor/dallgoot/yaml/src/Yaml.php @@ -1,6 +1,10 @@ parse($someYaml); + return (new Loader(null, $options, $debug))->parse($someYaml); } catch (\Throwable $e) { - throw new \Exception(__CLASS__." Error while parsing YAML string", 1, $e); + throw new \Exception(__CLASS__ . " Error while parsing YAML string", 1, $e); } } @@ -53,44 +57,43 @@ public static function parse(string $someYaml, $options = null, $debug = null) * - an array of YamlObject * * @param string $fileName Some file path name - * @param int|null $options from Loader class, bitwise combination of + * @param ?int $options from Loader class, bitwise combination of * Loader::IGNORE_DIRECTIVES * Loader::IGNORE_COMMENTS * Loader::NO_PARSING_EXCEPTIONS * Loader::NO_OBJECT_FOR_DATE - * @param int|null $debug define the level of debugging (true = default) + * @param ?int $debug define the level of debugging (true = default) * - * @return Yaml\YamlObject|array|null a Yaml document as YamlObject OR multiple documents as an array of YamlObject, + * @return YamlObject|array|null a Yaml document as YamlObject OR multiple documents as an array of YamlObject, * NULL if Error * @throws \Exception coming from Dallgoot\Yaml\Loader * @see Dallgoot\Yaml\Loader */ - public static function parseFile(string $fileName, $options = null, $debug = null) + public static function parseFile(string $fileName, ?int $options = null, ?int $debug = null) { try { - return (new Yaml\Loader($fileName, $options, (int) $debug))->parse(); + return (new Loader($fileName, $options, (int) $debug))->parse(); } catch (\Throwable $e) { - throw new \Exception(__CLASS__." Error during parsing '$fileName'", 1, $e); + throw new \Exception(__CLASS__ . " Error during parsing '$fileName'", 1, $e); } - } /** * Returns the YAML representation corresponding to given PHP variable * * @param mixed $somePhpVar Some php variable - * @param int|null $options enable/disable some options see Dumper + * @param ?int $options enable/disable some options see Dumper * * @return string ( the representation of $somePhpVar as a YAML content (single or multiple document accordingly) ) * @throws \Exception on errors during building YAML string coming from Dumper class * @see Dumper */ - public static function dump($somePhpVar, $options = null):string + public static function dump($somePhpVar, ?int $options = null): string { try { - return (new Yaml\Dumper($options))->toString($somePhpVar); + return (new Dumper($options))->toString($somePhpVar); } catch (\Throwable $e) { - throw new \Exception(__CLASS__." Error dumping", 1, $e); + throw new \Exception(__CLASS__ . " Error dumping", 1, $e); } } @@ -101,18 +104,18 @@ public static function dump($somePhpVar, $options = null):string * * @param string $fileName The file name * @param mixed $somePhpVar Some php variable - * @param int|null $options Dumper::constants as options + * @param ?int $options Dumper::constants as options * * @return boolean true if YAML built and saved , false if error during writing file * @throws \Exception on errors (from Dumper::toString) during building YAML string * @see Dumper */ - public static function dumpFile(string $fileName, $somePhpVar, $options = null):bool + public static function dumpFile(string $fileName, $somePhpVar, ?int $options = null): bool { try { - return (new Yaml\Dumper($options))->toFile($fileName, $somePhpVar); + return (new Dumper($options))->toFile($fileName, $somePhpVar); } catch (\Throwable $e) { - throw new \Exception(__CLASS__." Error during dumping '$fileName'", 1, $e); + throw new \Exception(__CLASS__ . " Error during dumping '$fileName'", 1, $e); } } -} \ No newline at end of file +} diff --git a/classes/vendor/dallgoot/yaml/src/YamlProperties.php b/classes/vendor/dallgoot/yaml/src/YamlProperties.php new file mode 100644 index 0000000..32e2e0a --- /dev/null +++ b/classes/vendor/dallgoot/yaml/src/YamlProperties.php @@ -0,0 +1,35 @@ + + * @license Apache 2.0 + * @link https://github.com/dallgoot/yaml + */ +class YamlProperties +{ + public ?bool $_hasDocStart = null; // null = no docstart, true = docstart before document comments, false = docstart after document comments + + public array $_anchors = []; + + public array $_comments = []; + + public array $_tags = []; + + public int $_options; + + public ?string $value = null; + + /** + * Creates API object to be used for the document provided as argument + * + * @param int $buildingOptions the YamlObject as the target for all methods call that needs it + */ + public function __construct(int $buildingOptions) + { + $this->_options = $buildingOptions; + } +} diff --git a/classes/vendor/dallgoot/yaml/test_all_versions.sh b/classes/vendor/dallgoot/yaml/test_all_versions.sh index 109158b..9577057 100644 --- a/classes/vendor/dallgoot/yaml/test_all_versions.sh +++ b/classes/vendor/dallgoot/yaml/test_all_versions.sh @@ -32,22 +32,21 @@ COMPOSER_CURRENT=$(composer show 'phpunit/phpunit' | grep -Eow "[0-9\.]+" -m 1 ) # fi declare -A versions # 7.key.value -# versions[0]=33 -versions[1]=33 -versions[2]=25 -versions[3]=12 -versions[4]=0 +versions[0]=27 +versions[1]=14 +versions[2]=1 + onlyMinor=1 command="vendor/bin/phpunit \ - --configuration ./configuration/phpunit.xml \ + -c ./configuration/phpunit.xml \ --testsuite All --no-coverage --columns 160 --disallow-test-output" # --testsuite units --no-coverage --columns 160 --disallow-test-output --no-logging" for minor in "${!versions[@]}" do - echo "********************* testing PHP 7.$minor ***************************" + echo "********************* testing PHP 8.$minor ***************************" tag="cli-alpine" if test $minor -eq 0 then @@ -57,13 +56,13 @@ do then for patch in `seq 0 ${versions[$minor]}` do - displayTitle "7.$minor.$patch" - docker run --rm -v $(pwd):/app -w /app php:7.$minor.$patch-$tag $command + displayTitle "8.$minor.$patch" + docker run --rm -v $(pwd):/app -w /app php:8.$minor.$patch-$tag $command done else patch=${versions[$minor]} - displayTitle "7.$minor.$patch" - docker run --rm -v $(pwd):/app -w /app php:7.$minor.$patch-$tag $command + displayTitle "8.$minor.$patch" + docker run --rm -v $(pwd):/app -w /app php:8.$minor.$patch-$tag $command fi done diff --git a/classes/vendor/dallgoot/yaml/tests/CasesTest.php b/classes/vendor/dallgoot/yaml/tests/CasesTest.php deleted file mode 100644 index 96e9124..0000000 --- a/classes/vendor/dallgoot/yaml/tests/CasesTest.php +++ /dev/null @@ -1,88 +0,0 @@ - $value) { - yield [$key, $value]; - } - }; - return $generator(); - } - - public function examplesProvider() - { - $nameResultPair = get_object_vars(Yaml::parseFile(__DIR__.'/definitions/examples_tests.yml')); - $this->assertArrayHasKey('Example_2_01', $nameResultPair, 'ERROR during Yaml::parseFile for ../definitions/examples_tests.yml'); - $this->assertEquals(28, count($nameResultPair)); - return $this->getGenerator($nameResultPair); - } - - public function parsingProvider() - { - $nameResultPair = get_object_vars(Yaml::parseFile(__DIR__.'/definitions/parsing_tests.yml'));//var_dump($nameResultPair);die(); - $this->assertEquals(58, count($nameResultPair)); - return $this->getGenerator($nameResultPair); - } - - // public function failingProvider() - // { - // $nameResultPair = get_object_vars(Yaml::parseFile(__DIR__.'/definitions/failing_tests.yml')); - // $this->assertEquals(20, count($nameResultPair)); - // return $this->getGenerator($nameResultPair); - // } - - /** - * @dataProvider examplesProvider - */ - public function testBatchExamples($fileName, $expected) - { - Yaml\TagFactory::$schemas = []; - Yaml\TagFactory::$schemaHandles = []; - $output = Yaml::parseFile(__DIR__."/cases/examples/$fileName.yml"); - $result = json_encode($output, self::JSON_OPTIONS); - $this->assertContains(json_last_error(), [JSON_ERROR_NONE, JSON_ERROR_INF_OR_NAN], json_last_error_msg()); - // $this->assertEquals($expected, $result, is_array($output) ? $output[0]->getComment(1) : $output->getComment(1)); - $this->assertEquals($expected, $result, $fileName.(is_null($output) ? "\t".Yaml\Loader::$error : '')); - } - - /** - * @dataProvider failingProvider - */ - // public function testBatchFailing($fileName) - // { - // $content = file_get_contents($this->testFolder."/failing/$fileName.yml"); - // // $this->assertInstanceOf(Yaml::parse($content), new \ParseError); - // $this->expectException(\Exception::class); - // // Yaml::parse($content); - // } - - /** - * @dataProvider parsingProvider - * @todo verify that every test file has a result in tests/definitions/parsing.yml - */ - public function testBatchParsing($fileName, $expected) - { - Yaml\TagFactory::$schemas = []; - Yaml\TagFactory::$schemaHandles = []; - $yaml = file_get_contents(__DIR__."/cases/parsing/$fileName.yml"); - $output = Yaml::parse($yaml, Yaml\Loader::NO_PARSING_EXCEPTIONS); - $result = json_encode($output, self::JSON_OPTIONS); - $this->assertContains(json_last_error(), [JSON_ERROR_NONE, JSON_ERROR_INF_OR_NAN], json_last_error_msg()); - $this->assertEquals($expected, $result, $fileName.(is_null($output) ? "\t".Yaml\Loader::$error : '')); - } -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/DumpingTest.php b/classes/vendor/dallgoot/yaml/tests/DumpingTest.php deleted file mode 100644 index c718c4e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/DumpingTest.php +++ /dev/null @@ -1,32 +0,0 @@ - $testResult) { - yield [$testName, $testResult]; - } - }; - return $generator(); - } - - /** - * @dataProvider dumpingCasesProvider - * @param string $fileName - * @param string $expected - */ - public function test_DumpingCases(string $fileName, string $expected) - { - $php = (include __DIR__."/cases/dumping/$fileName.php"); - $output = Yaml::dump($php); - $this->assertEquals($expected, $output, "$fileName.php"); - } -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/SymfonyYamlTest.php b/classes/vendor/dallgoot/yaml/tests/SymfonyYamlTest.php deleted file mode 100644 index 8d91baf..0000000 --- a/classes/vendor/dallgoot/yaml/tests/SymfonyYamlTest.php +++ /dev/null @@ -1,80 +0,0 @@ - $value) { - yield [$key, rtrim($value)]; - } - }; - return $generator(); - } - - public function examplestestSymfonyProvider() - { - $nameResultPair = Yaml::parseFile(__DIR__.'/definitions/examples_tests.yml'); - $this->assertArrayHasKey('Example_2_01', $nameResultPair, 'ERROR during Yaml::parseFile for ../definitions/examples_tests.yml'); - return $this->getGenerator($nameResultPair); - } - - public function parsingtestSymfonyProvider() - { - $nameResultPair = Yaml::parseFile(__DIR__.'/definitions/parsing_tests.yml'); - return $this->getGenerator($nameResultPair); - } - - public function failingtestSymfonyProvider() - { - $nameResultPair = Yaml::parseFile(__DIR__.'/definitions/failing_tests.yml'); - return $this->getGenerator($nameResultPair); - } - - /** - * @dataProvider examplesProvider - * @group cases - */ - public function testSymfonyBatchExamples($fileName, $expected) - { - $output = Yaml::parseFile($this->testFolder.'examples/'.$fileName.'.yml'); - $result = json_encode($output, self::JSON_OPTIONS); - $this->assertContains(json_last_error(), [JSON_ERROR_NONE, JSON_ERROR_INF_OR_NAN], json_last_error_msg()); - $this->assertEquals($expected, $result); - } - - /** - * @dataProvider failingtestSymfonyProvider - * @group cases - */ - // public function testBatchFailing($fileName) - // { - // $content = file_get_contents($this->testFolder."/failing/$fileName.yml"); - // // $this->assertInstanceOf(Y::parse($content), new \ParseError); - // $this->expectException(\Exception::class); - // // Y::parse($content); - // } - - /** - * @dataProvider parsingtestSymfonyProvider - * @group cases - * @todo verify that every test file has a result in tests/definitions/parsing.yml - */ - public function testSymfonyBatchParsing($fileName, $expected) - { - $yaml = file_get_contents($this->testFolder."parsing/$fileName.yml"); - $output = Yaml::parse($yaml, Yaml::PARSE_CUSTOM_TAGS); - $result = json_encode($output, self::JSON_OPTIONS); - $this->assertContains(json_last_error(), [JSON_ERROR_NONE, JSON_ERROR_INF_OR_NAN], json_last_error_msg()); - $this->assertEquals($expected, $result); - } -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/array.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/array.php deleted file mode 100644 index a70877e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/array.php +++ /dev/null @@ -1,3 +0,0 @@ - 'alphakey_value', 'a', 'b', 'c']; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array.php deleted file mode 100644 index 81b2913..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array.php +++ /dev/null @@ -1,11 +0,0 @@ -key1 = new Compact([1,2,3]); - - -return $o; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array_in_object.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array_in_object.php deleted file mode 100644 index 3634139..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_array_in_object.php +++ /dev/null @@ -1,14 +0,0 @@ -array = [1,2,3]; - -$yaml->key1 = new Compact($o); - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object.php deleted file mode 100644 index 17eda33..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object.php +++ /dev/null @@ -1,15 +0,0 @@ -key1 = 'a'; -$o->key2 = 'b'; - -$yaml->key1 = new Compact($o); - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object_in_array.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object_in_array.php deleted file mode 100644 index f3853a4..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/compact_object_in_array.php +++ /dev/null @@ -1,13 +0,0 @@ -key = 'a'; - -$yaml->key1 = new Compact([1,2,$o]); - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/dateTime.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/dateTime.php deleted file mode 100644 index 4beffd3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/dateTime.php +++ /dev/null @@ -1,9 +0,0 @@ -key = new \DateTime('2000-01-01'); - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/floats_double.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/floats_double.php deleted file mode 100644 index ac5798d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/floats_double.php +++ /dev/null @@ -1,22 +0,0 @@ -positiveFloat = 0.5353; -$yaml->negativeFloat = -2.65; - -$yaml->castedPositiveFloat = (float) 2.0; -$yaml->castedNegativeFloat = (float) -2; - -$yaml->positiveExponentFloat = 2.3e4; -$yaml->negativeExponentFloat = 2.3e-3; - -$yaml->positiveInfinity = INF; -$yaml->negativeInfinity = -INF; - -$yaml->notANumber = NAN;//this has the PHP type 'double' - - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/multidoc_yamlObject.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/multidoc_yamlObject.php deleted file mode 100644 index 81a8cd2..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/multidoc_yamlObject.php +++ /dev/null @@ -1,15 +0,0 @@ -a = 1; - -$yaml2->b = 2; - -return [$yaml, $yaml1, $yaml2]; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/stdObject.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/stdObject.php deleted file mode 100644 index 2bb0f4d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/stdObject.php +++ /dev/null @@ -1,6 +0,0 @@ -prop = "my property"; - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/unicodeString.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/unicodeString.php deleted file mode 100644 index 3fdba82..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/unicodeString.php +++ /dev/null @@ -1,6 +0,0 @@ -str = "☺"; - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_indices.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_indices.php deleted file mode 100644 index 0e7d4f6..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_indices.php +++ /dev/null @@ -1,14 +0,0 @@ -memberOfO = 'some really really really really really really really really really very long text as a simple string'; - -$yaml[0] = [1,2,3]; - -$yaml[1] = $o; - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_properties.php b/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_properties.php deleted file mode 100644 index 51a88ec..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/dumping/yamlObject_properties.php +++ /dev/null @@ -1,16 +0,0 @@ -memberOfO = 'some really really really really really really really really really very long text as a simple string'; - -$yaml->propA = [1,2,3]; - -$yaml->propB = $o; - -return $yaml; \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_01.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_01.yml deleted file mode 100644 index bb35fad..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_01.yml +++ /dev/null @@ -1,6 +0,0 @@ -#Example 2.1. Sequence of Scalars -#(ball players) - -- Mark McGwire -- Sammy Sosa -- Ken Griffey diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_02.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_02.yml deleted file mode 100644 index 1947836..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_02.yml +++ /dev/null @@ -1,6 +0,0 @@ -#Example 2.2. Mapping Scalars to Scalars -#(player statistics) - -hr: 65 # Home runs -avg: 0.278 # Batting average -rbi: 147 # Runs Batted In diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_03.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_03.yml deleted file mode 100644 index 41798e1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_03.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.3. Mapping Scalars to Sequences -#(ball clubs in each league) - -american: - - Boston Red Sox - - Detroit Tigers - - New York Yankees -national: - - New York Mets - - Chicago Cubs - - Atlanta Braves diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_04.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_04.yml deleted file mode 100644 index f7e383e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_04.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.4. Sequence of Mappings -#(players’ statistics) - -- - name: Mark McGwire - hr: 65 - avg: 0.278 -- - name: Sammy Sosa - hr: 63 - avg: 0.288 diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_05.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_05.yml deleted file mode 100644 index 1b4ae88..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_05.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.5. Sequence of Sequences - -- [name , hr, avg ] -- [Mark McGwire, 65, 0.278] -- [Sammy Sosa , 63, 0.288] - - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_06.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_06.yml deleted file mode 100644 index 4e503b3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_06.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.6. Mapping of Mappings - -Mark McGwire: {hr: 65, avg: 0.278} -Sammy Sosa: { - hr: 63, - avg: 0.288 - } diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_07.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_07.yml deleted file mode 100644 index 467352b..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_07.yml +++ /dev/null @@ -1,13 +0,0 @@ -#Example 2.7. Two Documents in a Stream -#(each with a leading comment) - -# Ranking of 1998 home runs ---- -- Mark McGwire -- Sammy Sosa -- Ken Griffey - -# Team ranking ---- -- Chicago Cubs -- St Louis Cardinals diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_08.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_08.yml deleted file mode 100644 index c41f9e6..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_08.yml +++ /dev/null @@ -1,13 +0,0 @@ -#Example 2.8. Play by Play Feed -#from a Game - ---- -time: 20:03:20 -player: Sammy Sosa -action: strike (miss) -... ---- -time: 20:03:47 -player: Sammy Sosa -action: grand slam -... diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_09.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_09.yml deleted file mode 100644 index 80e4310..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_09.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.9. Single Document with -#Two Comments - ---- -hr: # 1998 hr ranking - - Mark McGwire - - Sammy Sosa -rbi: - # 1998 rbi ranking - - Sammy Sosa - - Ken Griffey diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_10.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_10.yml deleted file mode 100644 index 774f648..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_10.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.10. Node for “Sammy Sosa” -#appears twice in this document - ---- -hr: - - Mark McGwire - # Following node labeled SS - - &SS Sammy Sosa -rbi: - - *SS # Subsequent occurrence - - Ken Griffey diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_11.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_11.yml deleted file mode 100644 index 1521fd3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_11.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.11. Mapping between Sequences - -? - Detroit Tigers - - Chicago cubs -: - - 2001-07-23 - -? [ New York Yankees, - Atlanta Braves ] -: [ 2001-07-02, 2001-08-12, - 2001-08-14 ] diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_12.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_12.yml deleted file mode 100644 index 81dfb7b..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_12.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.12. Compact Nested Mapping - ---- -# Products purchased -- item : Super Hoop - quantity: 1 -- item : Basketball - quantity: 4 -- item : Big Shoes - quantity: 1 - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_13.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_13.yml deleted file mode 100644 index f8ea951..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_13.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.13. In literals, -#newlines are preserved - -# ASCII Art ---- | - \//||\/|| - // || ||__ diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_14.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_14.yml deleted file mode 100644 index 7667fa3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_14.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.14. In the folded scalars, -#newlines become spaces - ---- > - Mark McGwire's - year was crippled - by a knee injury. diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_15.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_15.yml deleted file mode 100644 index c983005..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_15.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.15. Folded newlines are preserved -#for "more indented" and blank lines - -> - Sammy Sosa completed another - fine season with great stats. - - 63 Home Runs - 0.288 Batting Average - - What a year! diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_16.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_16.yml deleted file mode 100644 index 432a4c2..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_16.yml +++ /dev/null @@ -1,11 +0,0 @@ -#Example 2.16. Indentation determines scope - - -name: Mark McGwire -accomplishment: > - Mark set a major league - home run record in 1998. -stats: | - 65 Home Runs - 0.278 Batting Average - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_17.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_17.yml deleted file mode 100644 index 25c213f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_17.yml +++ /dev/null @@ -1,9 +0,0 @@ -#Example 2.17. Quoted Scalars - -unicode: "Sosa did fine.\u263A" -control: "\b1998\t1999\t2000\n" -hex esc: "\x0d\x0a is \r\n" - -single: '"Howdy!" he cried.' -quoted: ' # Not a ''comment''.' -tie-fighter: '|\-*-/|' diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_18.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_18.yml deleted file mode 100644 index ad9d05d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_18.yml +++ /dev/null @@ -1,9 +0,0 @@ -#Example 2.18. Multi-line Flow Scalars - -plain: - This unquoted scalar - spans many lines. - -quoted: "So does this - quoted scalar.\n" - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_19.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_19.yml deleted file mode 100644 index 4860baa..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_19.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.19. Integers - -canonical: 12345 -decimal: +12345 -octal: 0o14 -hexadecimal: 0xC - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_20.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_20.yml deleted file mode 100644 index 1d6fe33..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_20.yml +++ /dev/null @@ -1,7 +0,0 @@ -#Example 2.20. Floating Point - -canonical: 1.23015e+3 -exponential: 12.3015e+02 -fixed: 1230.15 -negative infinity: -.inf -not a number: .NaN diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_21.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_21.yml deleted file mode 100644 index beec7e5..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_21.yml +++ /dev/null @@ -1,5 +0,0 @@ -#Example 2.21. Miscellaneous - -null: -booleans: [ true, false ] -string: '012345' diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_22.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_22.yml deleted file mode 100644 index c7472b0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_22.yml +++ /dev/null @@ -1,6 +0,0 @@ -#Example 2.22. Timestamps - -canonical: 2001-12-15T02:59:43.1Z -iso8601: 2001-12-14t21:59:43.10-05:00 -spaced: 2001-12-14 21:59:43.10 -5 -date: 2002-12-14 diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_23.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_23.yml deleted file mode 100644 index 746101f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_23.yml +++ /dev/null @@ -1,16 +0,0 @@ -#Example 2.23. Various Explicit Tags - ---- -not-date: !!str 2002-04-28 - -picture: !!binary | - R0lGODlhDAAMAIQAAP//9/X - 17unp5WZmZgAAAOfn515eXv - Pz7Y6OjuDg4J+fn5OTk6enp - 56enmleECcgggoBADs= - -application specific tag: !something | - The semantics of the tag - above may be different for - different documents. - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_24.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_24.yml deleted file mode 100644 index e403d55..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_24.yml +++ /dev/null @@ -1,16 +0,0 @@ -#Example 2.24. Global Tags - -%TAG ! tag:clarkevans.com,2002: ---- !shape - # Use the ! handle for presenting - # tag:clarkevans.com,2002:circle -- !circle - center: &ORIGIN {x: 73, y: 129} - radius: 7 -- !line - start: *ORIGIN - finish: { x: 89, y: 102 } -- !label - start: *ORIGIN - color: 0xFFEEBB - text: Pretty vector drawing. diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_25.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_25.yml deleted file mode 100644 index 83c4202..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_25.yml +++ /dev/null @@ -1,9 +0,0 @@ -#Example 2.25. Unordered Sets - -# Sets are represented as a -# Mapping where each key is -# associated with a null value ---- !!set -? Mark McGwire -? Sammy Sosa -? Ken Griffey diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_26.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_26.yml deleted file mode 100644 index 2c5a1d8..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_26.yml +++ /dev/null @@ -1,9 +0,0 @@ -#Example 2.26. Ordered Mappings - -# Ordered maps are represented as -# A sequence of mappings, with -# each mapping having one key ---- !!omap -- Mark McGwire: 65 -- Sammy Sosa: 63 -- Ken Griffy: 58 diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_27.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_27.yml deleted file mode 100644 index 4308998..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_27.yml +++ /dev/null @@ -1,31 +0,0 @@ -#Example 2.27. Invoice - ---- ! -invoice: 34843 -date : 2001-01-23 -bill-to: &id001 - given : Chris - family : Dumars - address: - lines: | - 458 Walkman Dr. - Suite #292 - city : Royal Oak - state : MI - postal : 48046 -ship-to: *id001 -product: - - sku : BL394D - quantity : 4 - description : Basketball - price : 450.00 - - sku : BL4438H - quantity : 1 - description : Super Hoop - price : 2392.00 -tax : 251.42 -total: 4443.52 -comments: - Late afternoon is best. - Backup contact is Nancy - Billsmer @ 338-4338. diff --git a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_28.yml b/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_28.yml deleted file mode 100644 index d953ce0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/examples/Example_2_28.yml +++ /dev/null @@ -1,31 +0,0 @@ -#Example 2.28. Log File - ---- -Time: 2001-11-23 15:01:42 -5 -User: ed -Warning: - This is an error message - for the log file ---- -Time: 2001-11-23 15:02:31 -5 -User: ed -Warning: - A slightly different error - message. ---- -Date: 2001-11-23 15:03:17 -5 -User: ed -Fatal: - Unknown variable "bar" -Stack: - - file: TopClass.py - line: 23 - code: | - x = MoreObject("345\n") - - file: MoreClass.py - line: 58 - code: |- - foo = bar - - - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_keyvalue_with_no_space.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_keyvalue_with_no_space.yml deleted file mode 100644 index 5ab2218..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_keyvalue_with_no_space.yml +++ /dev/null @@ -1 +0,0 @@ -key: {foo:""} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_emptystring_as_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_emptystring_as_key.yml deleted file mode 100644 index 5bf45db..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_emptystring_as_key.yml +++ /dev/null @@ -1 +0,0 @@ -key: { "": foo } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference.yml deleted file mode 100644 index 62976b1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference.yml +++ /dev/null @@ -1 +0,0 @@ -key: { foo: * } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference_and_comment.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference_and_comment.yml deleted file mode 100644 index efe2f3f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_invalid_reference_and_comment.yml +++ /dev/null @@ -1 +0,0 @@ -key: { foo: * #foo } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_closing_brace.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_closing_brace.yml deleted file mode 100644 index 698dd62..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_closing_brace.yml +++ /dev/null @@ -1 +0,0 @@ -key: {abc: 'def' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_keyvalue_pair.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_keyvalue_pair.yml deleted file mode 100644 index 2c39e4f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/compact_with_no_keyvalue_pair.yml +++ /dev/null @@ -1 +0,0 @@ -key: {this, is not, supported} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/invalid_quoting_in_compact.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/invalid_quoting_in_compact.yml deleted file mode 100644 index 7b6fe78..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/invalid_quoting_in_compact.yml +++ /dev/null @@ -1 +0,0 @@ -key: { "foo " bar": "bar" } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/key_in_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/key_in_key.yml deleted file mode 100644 index a268264..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/key_in_key.yml +++ /dev/null @@ -1 +0,0 @@ -foo: bar: baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_folded_with_immediate_value.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_folded_with_immediate_value.yml deleted file mode 100644 index f4f206a..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_folded_with_immediate_value.yml +++ /dev/null @@ -1 +0,0 @@ -foo: > foo \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_with_immediate_value.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_with_immediate_value.yml deleted file mode 100644 index 60ba9d0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/litteral_with_immediate_value.yml +++ /dev/null @@ -1 +0,0 @@ -foo: | foo \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_key_with_scalar_and_sequence.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/map_key_with_scalar_and_sequence.yml deleted file mode 100644 index 461eef3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_key_with_scalar_and_sequence.yml +++ /dev/null @@ -1,3 +0,0 @@ -yaml: - hash: me - - array stuff \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_compact_with_duplicates.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_compact_with_duplicates.yml deleted file mode 100644 index 929c1b0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_compact_with_duplicates.yml +++ /dev/null @@ -1,2 +0,0 @@ -parent: { child: first, child: duplicate } -parent: { child: duplicate, child: duplicate } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_embed_compact_and_comment.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_embed_compact_and_comment.yml deleted file mode 100644 index 4fe73d5..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/map_with_embed_compact_and_comment.yml +++ /dev/null @@ -1,7 +0,0 @@ -a: - b: - {} -# comment - d: - 1.1 -# another comment \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_multiline_scalar_and_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_multiline_scalar_and_key.yml deleted file mode 100644 index 94f7bd0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_multiline_scalar_and_key.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: - - bar -"missing colon" - foo: bar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_scalar_and_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_scalar_and_key.yml deleted file mode 100644 index 88f3766..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/seq_items_with_scalar_and_key.yml +++ /dev/null @@ -1,3 +0,0 @@ -yaml: - - array stuff - hash: me \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/sequence_items_with_no_space.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/sequence_items_with_no_space.yml deleted file mode 100644 index b3c9281..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/sequence_items_with_no_space.yml +++ /dev/null @@ -1,4 +0,0 @@ -collection: --item1 --item2 --item3 \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/special_chars_with_no_sense.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/special_chars_with_no_sense.yml deleted file mode 100644 index 560db8b..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/special_chars_with_no_sense.yml +++ /dev/null @@ -1 +0,0 @@ - & * ! | > ' " % @ ` #, { asd a;sdasd }-@^qw3 diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/string_alone_with_indented_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/string_alone_with_indented_key.yml deleted file mode 100644 index a4d53ac..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/string_alone_with_indented_key.yml +++ /dev/null @@ -1,2 +0,0 @@ -a - b: \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_double_quotes.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_double_quotes.yml deleted file mode 100644 index e1257e8..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_double_quotes.yml +++ /dev/null @@ -1 +0,0 @@ -key: "don"t do somthin" like that" \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_simple_quotes.yml b/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_simple_quotes.yml deleted file mode 100644 index 664b328..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/failing/unescaped_simple_quotes.yml +++ /dev/null @@ -1 +0,0 @@ -key: 'don't do somthin' like that' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChomping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChomping.yml deleted file mode 100644 index 422dbae..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChomping.yml +++ /dev/null @@ -1,7 +0,0 @@ -foo: |- - one - two -bar: |- - one - two - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithInsideBlank.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithInsideBlank.yml deleted file mode 100644 index 088f39f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithInsideBlank.yml +++ /dev/null @@ -1,4 +0,0 @@ -bar: | - one - - two \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeep.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeep.yml deleted file mode 100644 index 7ebace9..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeep.yml +++ /dev/null @@ -1,6 +0,0 @@ -foo: |+ - one - two -bar: |+ - one - two \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeepAndTrailing.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeepAndTrailing.yml deleted file mode 100644 index 9fb0c5d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithKeepAndTrailing.yml +++ /dev/null @@ -1,8 +0,0 @@ -foo: |+ - one - two - -bar: |+ - one - two - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithStripAndTrailing.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithStripAndTrailing.yml deleted file mode 100644 index f1d1e3f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/blockChompingWithStripAndTrailing.yml +++ /dev/null @@ -1,9 +0,0 @@ -foo: |- - one - two - -bar: |- - one - two - - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_at_first_and_inside_map.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_at_first_and_inside_map.yml deleted file mode 100644 index f26c9d7..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_at_first_and_inside_map.yml +++ /dev/null @@ -1,10 +0,0 @@ -# comment 1 -services: -# comment 2 - # comment 3 - app.foo_service: - class: Foo -# comment 4 - # comment 5 - app/bar_service: - class: Bar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_between_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_between_keys.yml deleted file mode 100644 index ccace20..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_between_keys.yml +++ /dev/null @@ -1,6 +0,0 @@ -a: - b: hello -# c: | -# first row -# second row - d: hello \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_inside_litteral_in_subkey.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_inside_litteral_in_subkey.yml deleted file mode 100644 index 84179de..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_inside_litteral_in_subkey.yml +++ /dev/null @@ -1,13 +0,0 @@ -test: | - foo - # bar - baz -collection: - - one: | - foo - # bar - baz - - two: | - foo - # bar - baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_with_a_colon.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_with_a_colon.yml deleted file mode 100644 index 4caa2bd..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comment_with_a_colon.yml +++ /dev/null @@ -1,2 +0,0 @@ -foo: - bar: foobar # Note: a comment after a colon \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comments_inside_litteral.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/comments_inside_litteral.yml deleted file mode 100644 index ff39561..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/comments_inside_litteral.yml +++ /dev/null @@ -1,13 +0,0 @@ -pages: - - - title: some title - content: | - # comment 1 - header - - # comment 2 - -

title

- - - footer # comment3 \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_array_inside_mapping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_array_inside_mapping.yml deleted file mode 100644 index a37b8b8..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_array_inside_mapping.yml +++ /dev/null @@ -1,2 +0,0 @@ -foo: - fiz: [cat] \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_in_a_key_separated_by_comment.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_in_a_key_separated_by_comment.yml deleted file mode 100644 index 0d2e9e2..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/compact_in_a_key_separated_by_comment.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: - - bar: - # comment - baz: [1, 2, 3] \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping.yml deleted file mode 100644 index ea6ced6..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping.yml +++ /dev/null @@ -1,3 +0,0 @@ -? "1" -: - name: végétalien \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_item.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_item.yml deleted file mode 100644 index 2575697..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_item.yml +++ /dev/null @@ -1,3 +0,0 @@ -- ? "1" - : - name: végétalien \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_key.yml deleted file mode 100644 index bd32209..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/complex_mapping_in_key.yml +++ /dev/null @@ -1,4 +0,0 @@ -diet: - ? "1" - : - name: végétalien \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/directive_at_start.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/directive_at_start.yml deleted file mode 100644 index 657d842..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/directive_at_start.yml +++ /dev/null @@ -1,4 +0,0 @@ -%YAML 1.2 ---- -foo: 1 -bar: 2 \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/encoding_non_utf8.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/encoding_non_utf8.yml deleted file mode 100644 index 326321d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/encoding_non_utf8.yml +++ /dev/null @@ -1,3 +0,0 @@ -foo: 'äöüß' -euro: '€' -cp1252: '©ÉÇáñ' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentMapping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentMapping.yml deleted file mode 100644 index c591fd3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentMapping.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- %YAML:1.0 -foo: bar -... \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentSequence.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentSequence.yml deleted file mode 100644 index 83fdfd4..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/endOfDocumentSequence.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- %YAML:1.0 -- 1 -- 2 -- 3 -... \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/folded_with_alpha_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/folded_with_alpha_keys.yml deleted file mode 100644 index 7c38c52..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/folded_with_alpha_keys.yml +++ /dev/null @@ -1,5 +0,0 @@ -folded_with_alpha_keys: | - - alphakey: alphakey_value - - 0: a - - 1: b - - 2: c \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/key_separated_by_blank_line.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/key_separated_by_blank_line.yml deleted file mode 100644 index c5dd712..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/key_separated_by_blank_line.yml +++ /dev/null @@ -1,3 +0,0 @@ -foo: - - bar: baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/keysWithTabs.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/keysWithTabs.yml deleted file mode 100644 index dfa0741..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/keysWithTabs.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: bar -baz: bar -bor: baz -boz: biz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_clip.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_clip.yml deleted file mode 100644 index b807472..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_clip.yml +++ /dev/null @@ -1,7 +0,0 @@ -foo: > - one - two -bar: > - one - two - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_strip_trailing.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_strip_trailing.yml deleted file mode 100644 index 6ad1808..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalFolded_strip_trailing.yml +++ /dev/null @@ -1,8 +0,0 @@ -foo: >- - one - two - -bar: >- - one - two - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_empty_with_blank.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_empty_with_blank.yml deleted file mode 100644 index 34fdd2a..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_empty_with_blank.yml +++ /dev/null @@ -1,37 +0,0 @@ -compact_keyvalue_with_no_space: | - -compact_with_invalid_reference_and_comment: | - -compact_with_invalid_reference: | - -compact_with_no_closing_brace: | - -compact_with_no_keyvalue_pair: | - -invalid_quoting_in_compact: | - -key_in_key: | - -litteral_folded_with_immediate_value: | - -litteral_with_immediate_value: | - -map_key_with_scalar_and_sequence: | - -map_with_compact_with_duplicates: | - -map_with_embed_compact_and_comment: | - -seq_items_with_multiline_scalar_and_key: | - -seq_items_with_scalar_and_key: | - -sequence_items_with_no_space: | - -special_chars_with_no_sense: | - -string_alone_with_indented_key: | - -unescaped_double_quotes: | - -unescaped_simple_quotes: | diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_keep_trailing_leading.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_keep_trailing_leading.yml deleted file mode 100644 index e7c74a3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_keep_trailing_leading.yml +++ /dev/null @@ -1,5 +0,0 @@ -foo: |- - - - bar - diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_with_comment_at_lastline.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_with_comment_at_lastline.yml deleted file mode 100644 index f047f13..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literal_with_comment_at_lastline.yml +++ /dev/null @@ -1,10 +0,0 @@ -content: | - # comment 1 - header - - # comment 2 - -

title

- - - footer # comment3 \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalfolded_keep_trailing.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalfolded_keep_trailing.yml deleted file mode 100644 index b6d819f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/literalfolded_keep_trailing.yml +++ /dev/null @@ -1,6 +0,0 @@ -foo: >+ - one - two -bar: >+ - one - two diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_and_items_mixing.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_and_items_mixing.yml deleted file mode 100644 index 6846f97..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_and_items_mixing.yml +++ /dev/null @@ -1,11 +0,0 @@ -sequence: -- key: foo -- - key1: foo -- key2: foo - key3: foo -sequence2: -- keyempty: - subkeyempty: -- keyempty2: - samelvlkey: foo \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_in_an_empty_item.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_in_an_empty_item.yml deleted file mode 100644 index 17b2e38..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_in_an_empty_item.yml +++ /dev/null @@ -1,3 +0,0 @@ -foo: - - - bar: foobar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_boolean_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_boolean_keys.yml deleted file mode 100644 index dd1ec83..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_boolean_keys.yml +++ /dev/null @@ -1,2 +0,0 @@ -true: foo -false: bar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_comment_inside_item.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_comment_inside_item.yml deleted file mode 100644 index f1e12c3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_comment_inside_item.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: - - bar: "foobar" - # A comment - baz: "foobaz" \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_duplicate_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_duplicate_keys.yml deleted file mode 100644 index eb5b5d7..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_duplicate_keys.yml +++ /dev/null @@ -1,6 +0,0 @@ -parent: - child: first - child: duplicate -parent: - child: duplicate - child: duplicate \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_float_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_float_keys.yml deleted file mode 100644 index 0fb53f6..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_float_keys.yml +++ /dev/null @@ -1,3 +0,0 @@ -foo: - 1.2: "bar" - 1.3: "baz" \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_number_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_number_keys.yml deleted file mode 100644 index 291ffbb..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_number_keys.yml +++ /dev/null @@ -1,3 +0,0 @@ -map: - 1: one - 2: two \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_quoted_number_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_quoted_number_keys.yml deleted file mode 100644 index e9e0f43..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_quoted_number_keys.yml +++ /dev/null @@ -1,3 +0,0 @@ -map: - '0': one - '1': two \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_seq_and_embed_comment.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_seq_and_embed_comment.yml deleted file mode 100644 index dcc0be0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/map_with_seq_and_embed_comment.yml +++ /dev/null @@ -1,5 +0,0 @@ -a: - b: - - c -# comment - d: e \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_empty_doc_in_between.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_empty_doc_in_between.yml deleted file mode 100644 index dba8eae..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_empty_doc_in_between.yml +++ /dev/null @@ -1,13 +0,0 @@ -# Ranking of 1998 home runs ---- -- Mark McGwire -- Sammy Sosa -- Ken Griffey -... ---- -# this document is empty -... -# Team ranking ---- -- Chicago Cubs -- St Louis Cardinals \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_mapping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_mapping.yml deleted file mode 100644 index 2160ffe..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_mapping.yml +++ /dev/null @@ -1,10 +0,0 @@ -# Ranking of 1998 home runs ---- -a: Mark McGwire -b: Sammy Sosa -c: Ken Griffey - ---- -# Team ranking -a: Chicago Cubs -b: St Louis Cardinals \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_sequence.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_sequence.yml deleted file mode 100644 index b93cbf3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multidoc_sequence.yml +++ /dev/null @@ -1,10 +0,0 @@ -# Ranking of 1998 home runs ---- -- Mark McGwire -- Sammy Sosa -- Ken Griffey - -# Team ranking ---- -- Chicago Cubs -- St Louis Cardinals \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_indented.keyslookalike.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_indented.keyslookalike.yml deleted file mode 100644 index bae9562..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_indented.keyslookalike.yml +++ /dev/null @@ -1,3 +0,0 @@ -a: - b - c \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted.yml deleted file mode 100644 index c790d56..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted.yml +++ /dev/null @@ -1,5 +0,0 @@ -foo: "bar - baz - foobar -foo" -bar: baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_in_subkey.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_in_subkey.yml deleted file mode 100644 index 4e67582..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_in_subkey.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: - foobar: 'foo - #bar' - bar: baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_blank.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_blank.yml deleted file mode 100644 index 673f70f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_blank.yml +++ /dev/null @@ -1,3 +0,0 @@ -foobar: 'foo - - bar' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_slash.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_slash.yml deleted file mode 100644 index 0d2ba32..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_quoted_with_slash.yml +++ /dev/null @@ -1,3 +0,0 @@ -foobar: - "foo\ - bar" \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted.yml deleted file mode 100644 index 7893ddf..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted.yml +++ /dev/null @@ -1,5 +0,0 @@ -foo: bar - baz - foobar - foo -bar: baz \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted_in_seqitem.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted_in_seqitem.yml deleted file mode 100644 index e95ed77..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_unquoted_in_seqitem.yml +++ /dev/null @@ -1,6 +0,0 @@ -foo: -- bar: - one - - two - three \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_with_boolean_strings.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_with_boolean_strings.yml deleted file mode 100644 index 34701e5..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/multiline_with_boolean_strings.yml +++ /dev/null @@ -1,4 +0,0 @@ -test: - You can have things that don't look like strings here - true - yes you can \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_compact.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_compact.yml deleted file mode 100644 index 30f66ff..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_compact.yml +++ /dev/null @@ -1,9 +0,0 @@ -var: &var var-value -scalar: *var -list: [ *var ] -list_in_list: [[ *var ]] -map_in_list: [ { key: *var } ] -embedded_mapping: { key: *var } -map: { key: *var } -list_in_map: { key: [*var] } -map_in_map: { foo: { bar: *var } } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_merged_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_merged_key.yml deleted file mode 100644 index 5d93d03..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_inside_merged_key.yml +++ /dev/null @@ -1,8 +0,0 @@ -mergekeyrefdef: - a: foo - <<: &quux - b: bar - c: baz -mergekeyderef: - d: quux - <<: *quux \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merge.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merge.yml deleted file mode 100644 index a72cf0e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merge.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: &foo - baz: foobar -bar: - <<: *foo \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merged_keys_inside_compact.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merged_keys_inside_compact.yml deleted file mode 100644 index 79e715f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_merged_keys_inside_compact.yml +++ /dev/null @@ -1,12 +0,0 @@ -foo: &FOO - bar: 1 -bar: &BAR - baz: 2 - <<: *FOO -baz: - baz_foo: 3 - <<: - baz_bar: 4 -foobar: - bar: ~ - <<: [*FOO, *BAR] \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_selfreference.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_selfreference.yml deleted file mode 100644 index 05566c1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/references_with_selfreference.yml +++ /dev/null @@ -1 +0,0 @@ -foo: { &foo { a: Steve, <<: *foo} } \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_item_with_multiple_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_item_with_multiple_keys.yml deleted file mode 100644 index 2f61625..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_item_with_multiple_keys.yml +++ /dev/null @@ -1,3 +0,0 @@ -collection: -- key: foo - foo: bar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_duplicate_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_duplicate_keys.yml deleted file mode 100644 index 0701e16..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_duplicate_keys.yml +++ /dev/null @@ -1,3 +0,0 @@ -array: - - key: one - - key: two \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_linefeed_and_key.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_linefeed_and_key.yml deleted file mode 100644 index cee00fd..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/sequence_with_linefeed_and_key.yml +++ /dev/null @@ -1,7 +0,0 @@ -a: -- - b: - - - bar: baz -- foo -d: e \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tag_symfony_phpobject.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tag_symfony_phpobject.yml deleted file mode 100644 index ecbaa28..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tag_symfony_phpobject.yml +++ /dev/null @@ -1,2 +0,0 @@ -foo: !php/object O:30:"Symfony\Component\Yaml\Tests\B":1:{s:1:"b";s:3:"foo";} -bar: 1 \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_casting.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_casting.yml deleted file mode 100644 index d83ee46..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_casting.yml +++ /dev/null @@ -1,8 +0,0 @@ -'1.2': "bar" -!!str 1.3: "baz" - -'true': foo -!!str false: bar - -!!str null: null -'~': 'null' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_keys.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_keys.yml deleted file mode 100644 index 1cf19e0..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_as_keys.yml +++ /dev/null @@ -1,5 +0,0 @@ -transitions: - !php/const 'Symfony\Component\Yaml\Tests\B::FOO': - from: - - !php/const 'Symfony\Component\Yaml\Tests\B::BAR' - to: !php/const 'Symfony\Component\Yaml\Tests\B::BAZ' \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_compact.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_compact.yml deleted file mode 100644 index c964730..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_compact.yml +++ /dev/null @@ -1,2 +0,0 @@ -- !foo [foo, bar] -- !quz {foo: bar, quz: !bar {one: bar}} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_item_with_sequence.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_item_with_sequence.yml deleted file mode 100644 index 585ffa2..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_item_with_sequence.yml +++ /dev/null @@ -1,3 +0,0 @@ -- !foo - - yaml -- !quz [bar] \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_litteral.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_litteral.yml deleted file mode 100644 index 8ead8cf..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_litteral.yml +++ /dev/null @@ -1,2 +0,0 @@ -data: !!binary | - SGVsbG8gd29ybGQ= \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_mapping.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_mapping.yml deleted file mode 100644 index 0c12426..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_in_mapping.yml +++ /dev/null @@ -1,4 +0,0 @@ -!foo -foo: !quz [bar] -quz: !foo - quz: bar \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_inline_long.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_inline_long.yml deleted file mode 100644 index ff149c7..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_inline_long.yml +++ /dev/null @@ -1,4 +0,0 @@ -foo: !inline bar -quz: !long > - this is a long - text \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_with_quotes.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_with_quotes.yml deleted file mode 100644 index c1d5a9c..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/tags_with_quotes.yml +++ /dev/null @@ -1,3 +0,0 @@ -data: !!binary "SGVsbG8gd29ybGQ=" -'enclosed with single quotes' : !!binary 'SGVsbG8gd29ybGQ=' -'containing spaces' : !!binary "SGVs bG8gd 29ybGQ=" \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/cases/parsing/yaml_in_literal_folded.yml b/classes/vendor/dallgoot/yaml/tests/cases/parsing/yaml_in_literal_folded.yml deleted file mode 100644 index ee04a3a..0000000 --- a/classes/vendor/dallgoot/yaml/tests/cases/parsing/yaml_in_literal_folded.yml +++ /dev/null @@ -1,7 +0,0 @@ -yamlObject_indices: | - - - - 1 - - 2 - - 3 - - - memberOfO: some really really really really really really really really really very long text as a simple string \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/definitions/dumping_tests.yml b/classes/vendor/dallgoot/yaml/tests/definitions/dumping_tests.yml deleted file mode 100644 index a60e4b6..0000000 --- a/classes/vendor/dallgoot/yaml/tests/definitions/dumping_tests.yml +++ /dev/null @@ -1,57 +0,0 @@ -array: |- - - a - - b - - c -array_with_alphakey: |- - alphakey: alphakey_value - 0: a - 1: b - 2: c -compact_array_in_object: |- - key1: {array: [1, 2, 3]} -compact_array: |- - key1: [1, 2, 3] -compact_object_in_array: |- - key1: [1, 2, {key: a}] -compact_object: |- - key1: {key1: a, key2: b} -dateTime: |- - key: 2000-01-01 -floats_double: |- - positiveFloat: 0.5353 - negativeFloat: -2.6500 - castedPositiveFloat: 2.0000 - castedNegativeFloat: -2.0000 - positiveExponentFloat: 23000.0000 - negativeExponentFloat: 0.0023 - positiveInfinity: .inf - negativeInfinity: -.inf - notANumber: .nan -stdObject: |- - prop: my property -yamlObject_indices: |- - - - - 1 - - 2 - - 3 - - - memberOfO: some really really really really really really really really really very long text as a simple string -yamlObject_properties: |- - propA: - - 1 - - 2 - - 3 - propB: - memberOfO: some really really really really really really really really really very long text as a simple string -unicodeString: |- - str: \u263a -multidoc_yamlObject: | - --- - - - - 1 - - 2 - - 3 - --- - a: 1 - --- - b: 2 diff --git a/classes/vendor/dallgoot/yaml/tests/definitions/examples_tests.yml b/classes/vendor/dallgoot/yaml/tests/definitions/examples_tests.yml deleted file mode 100644 index 0b19b62..0000000 --- a/classes/vendor/dallgoot/yaml/tests/definitions/examples_tests.yml +++ /dev/null @@ -1,56 +0,0 @@ -Example_2_01: |- - ["Mark McGwire","Sammy Sosa","Ken Griffey"] -Example_2_02: |- - {"hr":65,"avg":0.278,"rbi":147} -Example_2_03: |- - {"american":["Boston Red Sox","Detroit Tigers","New York Yankees"],"national":["New York Mets","Chicago Cubs","Atlanta Braves"]} -Example_2_04: |- - [{"name":"Mark McGwire","hr":65,"avg":0.278},{"name":"Sammy Sosa","hr":63,"avg":0.288}] -Example_2_05: |- - [["name","hr","avg"],["Mark McGwire",65,0.278],["Sammy Sosa",63,0.288]] -Example_2_06: |- - {"Mark McGwire":{"hr":65,"avg":0.278},"Sammy Sosa":{"hr":63,"avg":0.288}} -Example_2_07: |- - [["Mark McGwire","Sammy Sosa","Ken Griffey"],["Chicago Cubs","St Louis Cardinals"]] -Example_2_08: |- - [{"time":"20:03:20","player":"Sammy Sosa","action":"strike (miss)"},{"time":"20:03:47","player":"Sammy Sosa","action":"grand slam"}] -Example_2_09: |- - {"hr":["Mark McGwire","Sammy Sosa"],"rbi":["Sammy Sosa","Ken Griffey"]} -Example_2_10: |- - {"hr":["Mark McGwire","Sammy Sosa"],"rbi":["Sammy Sosa","Ken Griffey"]} -Example_2_11: |- - {"[\"Detroit Tigers\"]":["2001-07-23"],"[\"New York Yankees\",\"Atlanta Braves\"]":["2001-07-02","2001-08-12","2001-08-14"]} -Example_2_12: |- - [{"item":"Super Hoop","quantity":1},{"item":"Basketball","quantity":4},{"item":"Big Shoes","quantity":1}] -Example_2_13: |- - ""\\//||\\/||\n// || ||__\n"" -Example_2_14: |- - ""Mark McGwire's year was crippled by a knee injury.\n"" -Example_2_15: |- - ""Sammy Sosa completed another fine season with great stats.\n\n63 Home Runs\n0.288 Batting Average\nWhat a year!\n"" -Example_2_16: |- - {"name":"Mark McGwire","accomplishment":"Mark set a major league home run record in 1998.\n","stats":"65 Home Runs\n0.278 Batting Average\n"} -Example_2_17: |- - "{"unicode":"Sosa did fine.\u263A","control":"\\b1998\\t1999\\t2000\\n","hex esc":"\x0d\x0a is \\r\\n","single":"\"Howdy!\" he cried.","quoted":" # Not a ''comment''.","tie-fighter":"|\\-*-/|"}" -Example_2_18: |- - {"plain":"This unquoted scalar spans many lines.","quoted":"So does this quoted scalar.\\n"} -Example_2_19: |- - {"canonical":12345,"decimal":12345,"octal":12,"hexadecimal":12} -Example_2_20: |- - {"canonical":1230.15,"exponential":1230.15,"fixed":1230.15,"negative infinity":0,"not a number":0} -Example_2_21: |- - {"null":null,"booleans":[true,false],"string":"012345"} -Example_2_22: |- - {"canonical":"2001-12-15T02:59:43.1Z","iso8601":"2001-12-14t21:59:43.10-05:00","spaced":"2001-12-14 21:59:43.10 -5","date":"2002-12-14"} -Example_2_23: |- - {"not-date":"2002-04-28","picture":"R0lGODlhDAAMAIQAAP//9/X17unp5WZmZgAAAOfn515eXvPz7Y6OjuDg4J+fn5OTk6enp56enmleECcgggoBADs=","application specific tag":{"tagName":"!something","value":"The semantics of the tag\nabove may be different for\ndifferent documents.\n"}} -Example_2_24: |- - [{"tagName":"!circle","value":{"center":{"x":73,"y":129},"radius":7}},{"tagName":"!line","value":{"start":{"x":73,"y":129},"finish":{"x":89,"y":102}}},{"tagName":"!label","value":{"start":{"x":73,"y":129},"color":16772795,"text":"Pretty vector drawing."}}] -Example_2_25: |- - {"Mark McGwire":null,"Sammy Sosa":null,"Ken Griffey":null} -Example_2_26: |- - {"Mark McGwire":65,"Sammy Sosa":63,"Ken Griffy":58} -Example_2_27: |- - "{"invoice":34843,"date":"2001-01-23","bill-to":{"given":"Chris","family":"Dumars","address":{"lines":"458 Walkman Dr.\nSuite\n","city":"Royal Oak","state":"MI","postal":48046}},"ship-to":{"given":"Chris","family":"Dumars","address":{"lines":"458 Walkman Dr.\nSuite\n","city":"Royal Oak","state":"MI","postal":48046}},"product":[{"sku":"BL394D","quantity":4,"description":"Basketball","price":450.0},{"sku":"BL4438H","quantity":1,"description":"Super Hoop","price":2392.0}],"tax":251.42,"total":4443.52,"comments":"Late afternoon is best. Backup contact is Nancy Billsmer @ 338-4338."}" -Example_2_28: |- - [{"Time":"2001-11-23 15:01:42 -5","User":"ed","Warning":"This is an error message for the log file"},{"Time":"2001-11-23 15:02:31 -5","User":"ed","Warning":"A slightly different error message."},{"Date":"2001-11-23 15:03:17 -5","User":"ed","Fatal":"Unknown variable \"bar\"","Stack":[{"file":"TopClass.py","line":23,"code":"x = MoreObject(\"345\\n\")\n"},{"file":"MoreClass.py","line":58,"code":"foo = bar"}]}] \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/definitions/failing_tests.yml b/classes/vendor/dallgoot/yaml/tests/definitions/failing_tests.yml deleted file mode 100644 index 67b195e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/definitions/failing_tests.yml +++ /dev/null @@ -1,21 +0,0 @@ -compact_with_emptystring_as_key: | - {"key":{"":"foo"}} -compact_keyvalue_with_no_space: -compact_with_invalid_reference_and_comment: -compact_with_invalid_reference: -compact_with_no_closing_brace: -compact_with_no_keyvalue_pair: -invalid_quoting_in_compact: -key_in_key: -litteral_folded_with_immediate_value: -litteral_with_immediate_value: -map_key_with_scalar_and_sequence: -map_with_compact_with_duplicates: -map_with_embed_compact_and_comment: -seq_items_with_multiline_scalar_and_key: -seq_items_with_scalar_and_key: -sequence_items_with_no_space: -special_chars_with_no_sense: -string_alone_with_indented_key: -unescaped_double_quotes: -unescaped_simple_quotes: diff --git a/classes/vendor/dallgoot/yaml/tests/definitions/parsing_tests.yml b/classes/vendor/dallgoot/yaml/tests/definitions/parsing_tests.yml deleted file mode 100644 index 03137d1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/definitions/parsing_tests.yml +++ /dev/null @@ -1,116 +0,0 @@ -blockChompingWithInsideBlank: |- - {"bar":"one\n\ntwo\n"} -blockChompingWithKeepAndTrailing: |- - {"foo":"one\ntwo\n\n","bar":"one\ntwo\n\n\n"} -blockChompingWithKeep: |- - {"foo":"one\ntwo\n","bar":"one\ntwo\n"} -blockChompingWithStripAndTrailing: |- - {"foo":"one\ntwo","bar":"one\ntwo"} -blockChomping: |- - {"foo":"one\ntwo","bar":"one\ntwo"} -comment_at_first_and_inside_map: |- - {"services":{"app.foo_service":{"class":"Foo"},"app/bar_service":{"class":"Bar"}}} -comment_between_keys: |- - {"a":{"b":"hello","d":"hello"}} -comment_inside_litteral_in_subkey: |- - {"test":"foo\nbaz\n","collection":[{"one":"foo\nbaz\n"},{"two":"foo\nbaz\n"}]} -comments_inside_litteral: |- - {"pages":[{"title":"some title","content":"header\n\n \n

title

\n \n\nfooter\n"}]} -comment_with_a_colon: |- - {"foo":{"bar":"foobar"}} -compact_array_inside_mapping: |- - {"foo":{"fiz":["cat"]}} -compact_in_a_key_separated_by_comment: |- - {"foo":[{"bar":{"baz":[1,2,3]}}]} -complex_mapping_in_item: |- - [{"1":{"name":"végétalien"}}] -complex_mapping_in_key: |- - {"diet":{"1":{"name":"végétalien"}}} -complex_mapping: |- - {"1":{"name":"végétalien"}} -directive_at_start: |- - {"foo":1,"bar":2} -encoding_non_utf8: |- - {"foo":"äöüß","euro":"€","cp1252":"©ÉÇáñ"} -endOfDocumentMapping: |- - {"foo":"bar"} -endOfDocumentSequence: |- - [1,2,3] -folded_with_alpha_keys: |- - {"folded_with_alpha_keys":"- alphakey: alphakey_value\n- 0: a\n- 1: b\n- 2: c\n"} -key_separated_by_blank_line: |- - {"foo":{"bar":"baz"}} -keysWithTabs: |- - {"foo":"bar","baz":"bar","bor":"baz","boz":"biz"} -literalfolded_keep_trailing: |- - {"foo":"one two\n","bar":"one two\n\n"} -literalFolded_strip_trailing: |- - {"foo":"one two","bar":"one two"} -literalFolded_clip: |- - {"foo":"one two\n","bar":"one two\n"} -literal_keep_trailing_leading: |- - {"foo":"\n\nbar"} -literal_with_comment_at_lastline: |- - {"content":"header\n\n \n

title

\n \n\nfooter\n"} -map_in_an_empty_item: |- - {"foo":[{"bar":"foobar"}]} -map_with_boolean_keys: |- - {"true":"foo","false":"bar"} -map_with_comment_inside_item: |- - {"foo":[{"bar":"foobar","baz":"foobaz"}]} -map_with_duplicate_keys: |- - {"parent":{"child":"duplicate"}} -map_with_float_keys: |- - {"foo":{"1.2":"bar","1.3":"baz"}} -map_with_number_keys: |- - {"map":{"1":"one","2":"two"}} -map_with_quoted_number_keys: |- - {"map":{"0":"one","1":"two"}} -map_with_seq_and_embed_comment: |- - {"a":{"b":["c"],"d":"e"}} -multidoc_mapping: |- - [{"a":"Mark McGwire","b":"Sammy Sosa","c":"Ken Griffey"},{"a":"Chicago Cubs","b":"St Louis Cardinals"}] -multidoc_sequence: |- - [["Mark McGwire","Sammy Sosa","Ken Griffey"],["Chicago Cubs","St Louis Cardinals"]] -multiline_indented.keyslookalike: |- - {"a":"b c"} -multiline_quoted_in_subkey: |- - "{"foo":{"foobar":"foo #bar","bar":"baz"}}" -multiline_quoted_with_blank: |- - {"foobar":"foo\nbar"} -multiline_quoted_with_slash: |- - {"foobar":"foo\\ bar"} -multiline_quoted: |- - {"foo":"bar baz foobar foo","bar":"baz"} -multiline_unquoted_in_seqitem: |- - {"foo":[{"bar":"one\ntwo three"}]} -multiline_unquoted: |- - {"foo":"bar baz foobar foo","bar":"baz"} -multiline_with_boolean_strings: |- - {"test":"You can have things that don't look like strings here true yes you can"} -references_inside_compact: |- - {"var":"var-value","scalar":"var-value","list":["var-value"],"list_in_list":[["var-value"]],"map_in_list":[{"key":"var-value"}],"embedded_mapping":{"key":"var-value"},"map":{"key":"var-value"},"list_in_map":{"key":["var-value"]},"map_in_map":{"foo":{"bar":"var-value"}}} -sequence_item_with_multiple_keys: |- - {"collection":[{"key":"foo","foo":"bar"}]} -sequence_with_duplicate_keys: |- - {"array":[{"key":"one"},{"key":"two"}]} -sequence_with_linefeed_and_key: |- - {"a":[{"b":[{"bar":"baz"}]},"foo"],"d":"e"} -tags_as_casting: |- - {"1.2":"bar","1.3":"baz","true":"foo","false":"bar","null":null,"~":"null"} -tags_in_compact: |- - [{"tagName":"!foo","value":["foo","bar"]},{"tagName":"!quz","value":{"foo":"bar","quz":{"tagName":"!bar","value":{"one":"bar"}}}}] -tags_in_item_with_sequence: |- - [{"tagName":"!foo","value":["yaml"]},{"tagName":"!quz","value":["bar"]}] -tags_inline_long: |- - {"foo":{"tagName":"!inline","value":"bar"},"quz":{"tagName":"!long","value":"this is a long text\n"}} -tags_in_litteral: |- - {"data":"SGVsbG8gd29ybGQ="} -tags_in_mapping: |- - {"foo":{"tagName":"!quz","value":["bar"]},"quz":{"tagName":"!foo","value":{"quz":"bar"}}} -tags_with_quotes: |- - {"data":"SGVsbG8gd29ybGQ=","enclosed with single quotes":"SGVsbG8gd29ybGQ=","containing spaces":"SGVs bG8gd 29ybGQ="} -tag_symfony_phpobject: |- - {"foo":{"tagName":"!php/object","value":"O:30:\"Symfony\\Component\\Yaml\\Tests\\B\":1:{s:1:\"b\";s:3:\"foo\";}"},"bar":1} -yaml_in_literal_folded: |- - {"yamlObject_indices":"-\n - 1\n - 2\n - 3\n-\n memberOfO: some really really really really really really really really really very long text as a simple string\n"} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/units/BuilderTest.php b/classes/vendor/dallgoot/yaml/tests/units/BuilderTest.php deleted file mode 100644 index 489344d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/BuilderTest.php +++ /dev/null @@ -1,236 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Builder - */ -class BuilderTest extends TestCase -{ - /** - * @var Builder $builder An instance of "Builder" to test. - */ - private $builder; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->builder = new Builder(0,0); - } - - private function buildSimpleMapping() - { - // create a yaml mapping - $root = new Root; - $root->add(new Key('key: value', 1)); - return $this->builder->buildContent($root); - } - - private function buildSimpleSequence() - { - // create a yaml sequence - $root = new Root; - $root->add(new Item('- itemvalue', 1)); - return $this->builder->buildContent($root); - } - - private function buildMultiDoc() - { - $root = new Root; - $root->add(new DocStart('---', 1)); - $root->add(new Key('key: value', 2)); - $root->add(new DocEnd('...', 3)); - $root->add(new DocStart('---', 4)); - $root->add(new Key('key: value', 5)); - $root->add(new DocStart('---', 6)); - $root->add(new Key('key: value', 7)); - return $this->builder->buildContent($root); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildContent - * @todo test : - * simple literal - * only JSON content - */ - public function testBuildContent(): void - { - $debug_property = new \ReflectionProperty($this->builder, '_debug'); - $debug_property->setAccessible(true); - $debug_property->setValue($this->builder, 2); - ob_start(); - $this->assertEquals($this->builder->buildContent(new Root), null); - ob_end_clean(); - } - /** - * @covers \Dallgoot\Yaml\Builder::buildContent - */ - public function testBuildContentMAPPING(): void - { - //test simple mapping - $yamlMapping = $this->buildSimpleMapping(); - $this->assertTrue($yamlMapping instanceof YamlObject); - $this->assertTrue(property_exists($yamlMapping, 'key')); - $this->assertEquals($yamlMapping->key, 'value'); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildContent - */ - public function testBuildContentSEQUENCE(): void - { //test simple sequence - $yamlSequence = $this->buildSimpleSequence(); - $this->assertTrue($yamlSequence instanceof YamlObject); - $this->assertArrayHasKey(0, $yamlSequence); - $this->assertEquals($yamlSequence[0], 'itemvalue'); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildContent - */ - public function testBuildContentMULTIDOC(): void - { - // test multi document - $multiDoc = $this->buildMultiDoc(); - $this->assertTrue(is_array($multiDoc)); - $this->assertTrue(count($multiDoc) === 3); - $this->assertArrayHasKey(0, $multiDoc); - $this->assertTrue($multiDoc[0] instanceof YamlObject); - $this->assertArrayHasKey(1, $multiDoc); - $this->assertTrue($multiDoc[1] instanceof YamlObject); - $this->assertArrayHasKey(2, $multiDoc); - $this->assertTrue($multiDoc[2] instanceof YamlObject); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildContent - * @todo test : - * simple literal - * only JSON content - * multidocument - */ - public function testBuildContentException(): void - { - $this->expectException(\Exception::class); - $root = new Root; - $root->value = null; - $this->builder->buildContent($root); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildDocument - */ - public function testBuildDocument(): void - { - $nodekey = new Key('key: keyvalue', 1); - $list = new NodeList($nodekey); - $yamlObject = $this->builder->buildDocument($list, 0); - $this->assertTrue($yamlObject instanceof YamlObject); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildDocument - */ - public function testBuildDocumentDebug(): void - { - $output = - "Document #0\n". - "Dallgoot\Yaml\Nodes\Root Object\n". - "(\n". - " [line->indent] => -> -1\n". - " [value] => Dallgoot\Yaml\NodeList Object\n". - " (\n". - " [type] => \n". - " [flags:SplDoublyLinkedList:private] => 0\n". - " [dllist:SplDoublyLinkedList:private] => Array\n". - " (\n". - " )\n". - "\n". - " )\n". - "\n". - " [raw] => \n". - " [parent] => NO PARENT!!!\n". - ")\n"; - $debug = new \ReflectionProperty(Builder::class, '_debug'); - $debug->setAccessible(true); - $debug->setValue($this->builder,3); - $list = new NodeList; - $this->builder->buildDocument($list, 0); - $this->expectOutputString($output); - $debug->setValue($this->builder,0); - } - - /** - * @covers \Dallgoot\Yaml\Builder::buildDocument - */ - public function testBuildDocumentException(): void - { - $this->expectException(\Error::class); - $list = new NodeList(); - $list->push(new \StdClass); - $yamlObject = $this->builder->buildDocument($list, 0); - } - - - /** - * @covers \Dallgoot\Yaml\Builder::pushAndSave - */ - public function testPushAndSave(): void - { - $reflector = new \ReflectionClass($this->builder); - $method = $reflector->getMethod('pushAndSave'); - $method->setAccessible(true); - $child = new DocEnd('', 1); - $buffer = new NodeList; - $documents = []; - $this->assertTrue($buffer->count() === 0); - $method->invokeArgs($this->builder, [$child, &$buffer, &$documents]); - $this->assertTrue($buffer->count() === 0); - $this->assertTrue(count($documents) === 1); - } - - /** - * @covers \Dallgoot\Yaml\Builder::saveAndPush - */ - public function testSaveAndPush(): void - { - $reflector = new \ReflectionClass($this->builder); - $method = $reflector->getMethod('saveAndPush'); - $method->setAccessible(true); - $itemNode = new Item('- item', 1); - $buffer = new NodeList($itemNode); - $child = new DocStart('', 1); - $documents = []; - $this->assertTrue($buffer->count() === 1); - $method->invokeArgs($this->builder, [$child, &$buffer, &$documents]); - $this->assertTrue($buffer->count() === 1); - $this->assertTrue(count($documents) === 1); - $this->assertTrue($buffer->offsetGet(0) instanceof DocStart); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/DumperHandlersTest.php b/classes/vendor/dallgoot/yaml/tests/units/DumperHandlersTest.php deleted file mode 100644 index c981659..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/DumperHandlersTest.php +++ /dev/null @@ -1,136 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\DumperHandlers - */ -class DumperHandlersTest extends TestCase -{ - /** - * @var DumperHandlers $dumperHandler An instance of "DumperHandlers" to test. - */ - public $dumperHandler; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->dumperHandler = new DumperHandlers(new Dumper); - } - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::__construct - */ - public function test__construct() - { - $this->dumperHandler->__construct(new Dumper); - $reflector = new \ReflectionClass($this->dumperHandler); - $optionsProp = $reflector->getProperty('dumper'); - $optionsProp->setAccessible(true); - $this->assertTrue($optionsProp->getValue($this->dumperHandler) instanceof Dumper); - } - - - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpScalar - */ - public function testDumpScalar() - { - $this->assertEquals('.inf', $this->dumperHandler->dumpScalar(\INF)); - $this->assertEquals('-.inf', $this->dumperHandler->dumpScalar(-\INF)); - $this->assertEquals('true', $this->dumperHandler->dumpScalar(true)); - $this->assertEquals('false', $this->dumperHandler->dumpScalar(false)); - $this->assertEquals('.nan', $this->dumperHandler->dumpScalar(\NAN)); - $this->assertEquals('0.4500', $this->dumperHandler->dumpScalar(0.45)); - $this->assertEquals('0.1235', $this->dumperHandler->dumpScalar(0.123456)); - } - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpCompound - */ - public function testDumpCompoundException() - { - $callable = function () {return false;}; - $this->expectException(\Exception::class); - $dumpCompound = new \ReflectionMethod($this->dumperHandler, 'dumpCompound'); - $dumpCompound->setAccessible(true); - $dumpCompound->invoke($this->dumperHandler, $callable, 0); - } - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpCompound - */ - public function testDumpCompound() - { - $dumpCompound = new \ReflectionMethod($this->dumperHandler, 'dumpCompound'); - $dumpCompound->setAccessible(true); - $yamlObject = new YamlObject(0); - $yamlObject->a = 1; - $this->assertEquals('a: 1', $dumpCompound->invoke($this->dumperHandler, $yamlObject, 0)); - unset($yamlObject->a); - $yamlObject[0] = 'a'; - $this->assertEquals('- a', $dumpCompound->invoke($this->dumperHandler, $yamlObject, 0)); - $compact = new Compact([1,2,3]); - $this->assertEquals('[1, 2, 3]', $dumpCompound->invoke($this->dumperHandler, $compact, 0)); - $o = new \Stdclass; - $o->a = 1; - $compact = new Compact($o); - $this->assertEquals('{a: 1}', $dumpCompound->invoke($this->dumperHandler, $compact, 0)); - $this->assertEquals("- 1\n- 2\n- 3", $dumpCompound->invoke($this->dumperHandler, [1,2,3], 0)); - $tagged = new Tagged('!!str', 'somestring'); - $this->assertEquals("!!str somestring", $dumpCompound->invoke($this->dumperHandler, $tagged, 0)); - } - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpCompact - */ - public function testDumpCompact() - { - $this->assertEquals("[1, 2, 3]", $this->dumperHandler->dumpCompact([1,2,3], 0)); - $o = new \Stdclass; - $o->a = 1; - $o->b = [1, 2]; - $o->c = new \Stdclass; - $o->c->ca = 1; - $this->assertEquals("{a: 1, b: [1, 2], c: {ca: 1}}", $this->dumperHandler->dumpCompact($o, 0)); - } - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpString - */ - public function testDumpString() - { - $this->assertEquals('abc ', $this->dumperHandler->dumpString(' abc ', 0)); - } - - /** - * @covers \Dallgoot\Yaml\DumperHandlers::dumpTagged - */ - public function testDumpTagged() - { - $tagged = new Tagged('!!str', 'somestring'); - $this->assertEquals("!!str somestring", $this->dumperHandler->dumpTagged($tagged, 0)); - $tagged = new Tagged('!!omap', [1,2]); - $this->assertEquals("!!omap\n - 1\n - 2", $this->dumperHandler->dumpTagged($tagged, 0)); - } - -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/units/DumperTest.php b/classes/vendor/dallgoot/yaml/tests/units/DumperTest.php deleted file mode 100644 index 7e736a8..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/DumperTest.php +++ /dev/null @@ -1,110 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Dumper - */ -class DumperTest extends TestCase -{ - /** - * @var Dumper $dumper An instance of "Dumper" to test. - */ - private $dumper; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->dumper = new Dumper(); - } - /** - * @covers \Dallgoot\Yaml\DumperHandlers::__construct - */ - public function test__construct() - { - $this->dumper->__construct(1); - $reflector = new \ReflectionClass($this->dumper); - $optionsProp = $reflector->getProperty('options'); - $optionsProp->setAccessible(true); - $this->assertEquals(1, $optionsProp->getValue($this->dumper)); - } - /** - * @covers \Dallgoot\Yaml\Dumper::toString - */ - public function testToString(): void - { - $this->assertEquals("- 1\n- 2\n- 3", $this->dumper->toString([1,2,3])); - $this->assertEquals("--- some text\n", $this->dumper->toString('some text')); - } - - /** - * @covers \Dallgoot\Yaml\Dumper::toFile - */ - public function testToFile(): void - { - $filename = 'dumperTest.yml'; - $result = $this->dumper->toFile($filename, [1,2,3]); - $this->assertTrue($result); - $this->assertEquals("- 1\n- 2\n- 3", file_get_contents($filename)); - unlink($filename); - } - /** - * @covers \Dallgoot\Yaml\Dumper::dump - */ - public function testDump() - { - $this->assertEquals('', $this->dumper->dump(null, 0)); - $this->assertEquals('stream', $this->dumper->dump(fopen(__FILE__, 'r'), 0)); - $this->assertEquals('str', $this->dumper->dump('str', 0)); - $this->assertEquals('- 1', $this->dumper->dump([1], 0)); - $o = new \Stdclass; - $o->prop = 1; - $this->assertEquals('prop: 1', $this->dumper->dump($o, 0)); - } - - - /** - * @covers \Dallgoot\Yaml\Dumper::dumpYamlObject - */ - public function testDumpYamlObject() - { - $dumpYamlObject = new \ReflectionMethod($this->dumper, 'dumpYamlObject'); - $dumpYamlObject->setAccessible(true); - $yamlObject = new YamlObject(0); - $yamlObject->a = 1; - $this->assertEquals('a: 1', $dumpYamlObject->invoke($this->dumper, $yamlObject, 0)); - unset($yamlObject->a); - $yamlObject[0] = 'a'; - $this->assertEquals('- a', $dumpYamlObject->invoke($this->dumper, $yamlObject, 0)); - } - - /** - * @covers \Dallgoot\Yaml\Dumper::IteratorToString - */ - public function testIteratorToString() - { - $iteratorToString = new \ReflectionMethod($this->dumper, 'iteratorToString'); - $iteratorToString->setAccessible(true); - $yamlObject = new YamlObject(0); - $yamlObject[0] = 'a'; - $yamlObject[1] = 'b'; - $this->assertEquals("- a\n- b", $iteratorToString->invoke($this->dumper, $yamlObject, '-', "\n", 0)); - } - -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/LoaderTest.php b/classes/vendor/dallgoot/yaml/tests/units/LoaderTest.php deleted file mode 100644 index 6a0769d..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/LoaderTest.php +++ /dev/null @@ -1,243 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Loader - */ -class LoaderTest extends TestCase -{ - /** - * @var Loader $loader An instance of "Loader" to test. - */ - private $loader; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->loader = new Loader(); - } - - /** - * @covers \Dallgoot\Yaml\Loader::__construct - */ - public function testConstruct(): void - { - $this->expectException(\Exception::class); - $this->loader->__construct("non sense string"); - } - - /** - * @covers \Dallgoot\Yaml\Loader::load - * @covers \Dallgoot\Yaml\Loader::getSourceGenerator - */ - public function testLoad(): void - { - $this->assertEquals($this->loader, $this->loader->load(__DIR__.'/../definitions/parsing_tests.yml')); - } - - /** - * @covers \Dallgoot\Yaml\Loader::load - */ - public function testLoadNoFile(): void - { - $this->expectException(\Exception::class); - $this->loader->load('./non_existent_file'); - } - - /** - * @covers \Dallgoot\Yaml\Loader::load - * @todo : make sure this tests covers the last Exception in method - */ - // public function testLoadNoRights(): void - // { - // if (strpos('microsoft', php_uname())) { - // $this->markTestSkipped( - // "this test won't work on WSL Windows" - // ); - // } - // $this->expectException(\Exception::class); - // $fileName = "./notreadable"; - // touch($fileName); - // chmod($fileName, 0222); - // $this->loader->load($fileName); - // unlink($fileName); - // } - - /** - * @covers \Dallgoot\Yaml\Loader::getSourceGenerator - */ - public function testGetSourceGenerator(): void - { - $method = new \ReflectionMethod($this->loader, 'getSourceGenerator'); - $method->setAccessible(true); - $result = $method->invoke($this->loader, ''); - $this->assertTrue($result instanceof \Generator, 'getSourceGenerator is NOT a \\Generator'); - } - - /** - * @covers \Dallgoot\Yaml\Loader::getSourceGenerator - */ - public function testGetSourceGeneratorException(): void - { - $this->expectException(\Exception::class); - $method = new \ReflectionMethod($this->loader, 'getSourceGenerator'); - $method->setAccessible(true); - $generator = $method->invoke($this->loader, null); - $generator->next(); - } - - /** - * @covers \Dallgoot\Yaml\Loader::getSourceGenerator - */ - public function testGetSourceGeneratorExceptionOnNoSource(): void - { - $this->expectException(\Exception::class); - $method = new \ReflectionMethod($this->loader, 'getSourceGenerator'); - $method->setAccessible(true); - $property = new \ReflectionProperty($this->loader, 'content'); - $property->setAccessible(true); - $property->setValue($this->loader, []); - $generator = $method->invoke($this->loader, null); - $generator->next(); - } - - /** - * @covers \Dallgoot\Yaml\Loader::parse - */ - public function testParse(): void - { - $result = $this->loader->parse("key: keyvalue\n other string\notherkey: othervalue"); - $this->assertTrue($result instanceof YamlObject); - $result = $this->loader->parse('key: keyvalue'); - $this->assertTrue($result instanceof YamlObject); - $multidoc = $this->loader->parse("---\nkey1: key1value\n---\nkey1: key1value\n"); - $this->assertTrue(is_array($multidoc), 'result is NOT a multi-documents (ie. array)'); - $this->assertTrue($multidoc[0] instanceof YamlObject, 'array #0 is NOT a YamlObject'); - $this->assertTrue($multidoc[1] instanceof YamlObject, 'array #1 is NOT a YamlObject'); - $yamlMapping = $this->loader->parse("key:\n insidekey: value\nlessindent: value"); - $this->assertTrue($yamlMapping instanceof YamlObject); - $this->assertTrue(\property_exists($yamlMapping, 'key')); - } - - /** - * @covers \Dallgoot\Yaml\Loader::parse - */ - public function testParseWithError(): void - { - $this->expectException(\Exception::class); - // fails because theres no NodeSetKey before - $result = $this->loader->parse(' :: keyvalue'); - } - - /** - * @covers \Dallgoot\Yaml\Loader::_attachBlankLines - */ - public function testAttachBlankLines(): void - { - $rootNode = new Root(); - $blankNode = new Blank('', 1); - // NodeBlank get private method - $reflectorBlank = new \ReflectionClass($blankNode); - $method = $reflectorBlank->getMethod('setParent'); - $method->setAccessible(true); - // blankNode->setParent($rootNode) : sets the parent for blankNode - $method->invoke($blankNode, $rootNode); - $this->assertTrue($rootNode->value->count() === 0, 'rootNode has a child yet'); - // Loader get private property '_blankBuffer' - $reflectorLoader = new \ReflectionClass($this->loader); - $blankBufferProp = $reflectorLoader->getProperty('_blankBuffer'); - $blankBufferProp->setAccessible(true); - $this->assertTrue(count($blankBufferProp->getValue($this->loader)) === 0, '_blankbuffer is NOT empty'); - // set _blankbuffer : ie. add blankNode - $blankBufferProp->setValue($this->loader, [$blankNode]); - $this->assertTrue(count($blankBufferProp->getValue($this->loader)) === 1, 'blankBuffer has NO content'); - $this->assertTrue($blankBufferProp->getValue($this->loader)[0] instanceof Blank, 'blankBuffer has NO nodeBlank'); - //attach to parents => add child to parent - // $this->loader->attachBlankLines($rootNode); - $attachBlankLinesMethod = new \ReflectionMethod($this->loader, '_attachBlankLines'); - $attachBlankLinesMethod->setAccessible(true); - $attachBlankLinesMethod->invoke($this->loader, $rootNode); - $this->assertTrue(count($blankBufferProp->getValue($this->loader)) === 0, '_blankbuffer is NOT empty'); - $this->assertTrue($rootNode->value->count() === 1, 'rootnode has NO child'); - $this->assertTrue($rootNode->value->offsetGet(0) instanceof Blank, 'rootnode child is NOT a blanknode'); - } - - /** - * @covers \Dallgoot\Yaml\Loader::needsSpecialProcess - * @todo assert a true value also - */ - public function testNeedsSpecialProcess(): void - { - $needsSpecialProcessMethod = new \ReflectionMethod($this->loader, 'needsSpecialProcess'); - $needsSpecialProcessMethod->setAccessible(true); - $current = new Scalar('some text', 1); - $previous = new Root(); - // $this->assertFalse($this->loader->needsSpecialProcess($current, $previous)); - $this->assertFalse($needsSpecialProcessMethod->invoke($this->loader, $current, $previous)); - $current = new Blank('', 1); - $previous = new Root(); - // $this->assertTrue($this->loader->needsSpecialProcess($current, $previous)); - $this->assertTrue($needsSpecialProcessMethod->invoke($this->loader, $current, $previous)); - $previous = new Key('key: "partial value', 1); - $current = new Scalar(' end of partial value"',2); - // $this->assertTrue($this->loader->needsSpecialProcess($current, $previous)); - $this->assertTrue($needsSpecialProcessMethod->invoke($this->loader, $current, $previous)); - $current = new Partial(' " oddly quoted'); - // $this->assertFalse($this->loader->needsSpecialProcess($current, $previous)); - $this->assertFalse($needsSpecialProcessMethod->invoke($this->loader, $current, $previous)); - } - - /** - * @covers \Dallgoot\Yaml\Loader::onError - */ - public function testOnError(): void - { - $this->expectException(\Exception::class); - $generator = function() { - yield 1 => 'this is the first line'; - yield 2 => 'this is the second line'; - }; - // $this->loader->onError(new \Exception, $generator()); - $onErrorMethod = new \ReflectionMethod($this->loader, 'onError'); - $onErrorMethod->setAccessible(true); - $onErrorMethod->invoke(new \Exception, $generator()); - } - - /** - * @covers \Dallgoot\Yaml\Loader::onError - */ - public function testOnErrorButNoException(): void - { - $this->loader = new Loader(null, Loader::NO_PARSING_EXCEPTIONS); - $generator = function() { - yield 1 => 'this is the first line'; - yield 2 => 'this is the second line'; - }; - $onErrorMethod = new \ReflectionMethod($this->loader, 'onError'); - $onErrorMethod->setAccessible(true); - $this->assertEquals(null, $onErrorMethod->invoke($this->loader, new \Exception, $generator()->key())); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/NodeFactoryTest.php b/classes/vendor/dallgoot/yaml/tests/units/NodeFactoryTest.php deleted file mode 100644 index c16288e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/NodeFactoryTest.php +++ /dev/null @@ -1,283 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\NodeFactory - */ -class NodeFactoryTest extends TestCase -{ - /** - * @var NodeFactory $nodeFactory An instance of "NodeFactory" to test. - */ - private $nodeFactory; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeFactory = new NodeFactory(); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::get - */ - public function testGet(): void - { - $this->assertTrue($this->nodeFactory::get('', 1) instanceof Blank, 'Not a NodeBlank'); - $this->assertTrue($this->nodeFactory::get(' ...', 1) instanceof DocEnd, 'Not a NodeDocEnd'); - $this->assertTrue($this->nodeFactory::get(' key : value', 1) instanceof Key, 'Not a NodeKey'); - $this->assertTrue($this->nodeFactory::get('$qsd = 3213', 1) instanceof Scalar, 'Not a NodeScalar'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::get - */ - public function testGetException(): void - { - $this->expectException(\Exception::class); - $this->nodeFactory::get('%INVALID_DIRECTIVE xxx', 1); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onSpecial - */ - public function testOnSpecial(): void - { - $reflector = new \ReflectionClass($this->nodeFactory); - $method = $reflector->getMethod('onSpecial'); - $method->setAccessible(true); - $nodeString = '#qsd = 3213'; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Comment, 'Not a NodeComment'); - $nodeString = '%YAML 1.2'; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Directive, 'Not a NodeDirective'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onSpecial - */ - public function testOnSpecialParseError(): void - { - $this->expectException(\ParseError::class); - $reflector = new \ReflectionClass($this->nodeFactory); - $method = $reflector->getMethod('onSpecial'); - $method->setAccessible(true); - $nodeString = '%INVALID_DIRECTIVE xxx'; - $method->invoke(null,$nodeString[0], $nodeString, 1); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onQuoted - */ - public function testOnQuoted(): void - { - $reflector = new \ReflectionClass($this->nodeFactory); - $method = $reflector->getMethod('onQuoted'); - $method->setAccessible(true); - $nodeString = ' "double quoted" '; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Quoted, - 'Not a NodeQuoted'); - $nodeString = " 'simple quoted' "; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Quoted, - 'Not a NodeQuoted'); - $nodeString = " 'simple partial "; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Partial, - 'Not a NodePartial'); - $nodeString = '" double partial '; - $this->assertTrue($method->invoke(null,$nodeString[0], $nodeString, 1) instanceof Partial, - 'Not a NodePartial'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onSetElement - */ - public function testOnSetElement(): void - { - $reflector = new \ReflectionClass($this->nodeFactory); - $method = $reflector->getMethod('onSetElement'); - $method->setAccessible(true); - $nodeString = ' ? some setkey '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof SetKey, - 'Not a NodeSetKey'); - $nodeString = ' : some setvalue '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof SetValue, - 'Not a NodeSetValue'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactJSON(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = '["a","b","c"]'; - $this->assertTrue($method->invoke(null, '', $nodeString, 1) instanceof JSON, - 'Not a NodeJSON'); - } - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactJSONMAPPING(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = '{"key":"value","key1":"value1"}'; - $this->assertTrue($method->invoke(null, '', $nodeString, 1) instanceof JSON, 'Not a NodeJSON'); - } - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactMAPPING(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = '{ key : value , key1 : value1 }'; - $output = $method->invoke(null, '', $nodeString, 1); - $this->assertTrue($output instanceof CompactMapping, get_class($output).' instead of a NodeCompactMapping'); - } - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactSEQUENCE(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = '[a,b,c]'; - $output = $method->invoke(null, '', $nodeString, 1); - $this->assertTrue($output instanceof CompactSequence, get_class($output).' instead of a NodeCompactSequence'); - } - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactPartialMapping(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = ' { a: b, '; - $output = $method->invoke(null, '', $nodeString, 1); - $this->assertTrue($output instanceof Partial, get_class($output).' instead of a Partial'); - } - /** - * @covers \Dallgoot\Yaml\NodeFactory::onCompact - */ - public function testOnCompactPartialSequence(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onCompact'); - $method->setAccessible(true); - $nodeString = ' [ a, b, '; - $output = $method->invoke(null, '', $nodeString, 1); - $this->assertTrue($output instanceof Partial, get_class($output).' instead of a Partial'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onHyphen - */ - public function testOnHyphen(): void - { - $reflector = new \ReflectionClass($this->nodeFactory); - $method = $reflector->getMethod('onHyphen'); - $method->setAccessible(true); - $nodeString = '- '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Item, - 'Not a NodeItem'); - $nodeString = '-- '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Scalar, - 'Not a NodeScalar'); - $nodeString = '---'; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof DocStart, - 'Not a NodeDocStart'); - $nodeString = ' - simpleitem '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Item, - 'Not a NodeItem'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onNodeAction - */ - public function testOnNodeAction(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onNodeAction'); - $method->setAccessible(true); - $nodeString = '***'; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Scalar, - 'Not a NodeScalar'); - $nodeString = '&emptyanchor'; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Anchor, - 'Not a NodeAnchor'.get_class($method->invoke(null, trim($nodeString)[0], $nodeString, 1))); - $nodeString = '&anchor [1,2,3]'; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Anchor, - 'Not a NodeAnchor'); - $nodeString = '*anchorcall '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Anchor, - 'Not a NodeAnchor'); - $nodeString = '!!emptytag'; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Tag, - 'Not a NodeTag'); - $nodeString = '!!str 345 '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Tag, - 'Not a NodeTag'); - } - - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onLiteral - */ - public function testOnLiteral(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onLiteral'); - $method->setAccessible(true); - $nodeString = ' |- '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof Literal, - 'Not a NodeLit'); - $nodeString = ' >+ '; - $this->assertTrue($method->invoke(null, trim($nodeString)[0], $nodeString, 1) instanceof LiteralFolded, - 'Not a NodeLitFolded'); - } - - /** - * @covers \Dallgoot\Yaml\NodeFactory::onLiteral - */ - public function testOnLiteralFail(): void - { - $method = new \ReflectionMethod($this->nodeFactory, 'onLiteral'); - $method->setAccessible(true); - $nodeString = ' x '; - $this->expectException(\ParseError::class); - $method->invoke(null, trim($nodeString)[0], $nodeString, 1); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/NodeListTest.php b/classes/vendor/dallgoot/yaml/tests/units/NodeListTest.php deleted file mode 100644 index c4ee9f2..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/NodeListTest.php +++ /dev/null @@ -1,178 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\NodeList - */ -class NodeListTest extends TestCase -{ - /** - * @var NodeList $nodeList An instance of "NodeList" to test. - */ - private $nodeList; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeList = new NodeList(new Blank('', 1)); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::__construct - */ - public function testConstruct(): void - { - $this->assertTrue($this->nodeList->count() === 1); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::has - */ - public function testHas(): void - { - $this->assertTrue($this->nodeList->has('Blank')); - $this->assertFalse($this->nodeList->has('Item')); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::hasContent - */ - public function testHasContent(): void - { - $this->assertFalse($this->nodeList->hasContent()); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::hasContent - */ - public function testHasContentWithDocStart(): void - { - $docstartNode = new DocStart('--- some value', 1); - $this->nodeList->push($docstartNode); - $this->assertTrue($this->nodeList->hasContent()); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::push - */ - public function testPush(): void - { - $this->assertTrue(is_null($this->nodeList->type)); - $this->nodeList->push(new Item('- item', 1)); - $this->assertEquals($this->nodeList->type, $this->nodeList::SEQUENCE); - - $this->nodeList = new NodeList; - $this->nodeList->push(new Key(' key: value', 1)); - $this->assertEquals($this->nodeList->type, $this->nodeList::MAPPING); - - $this->nodeList = new NodeList; - $this->nodeList->push(new SetKey(' ? simplekey ', 1)); - $this->assertEquals($this->nodeList->type, $this->nodeList::SET); - - $this->nodeList = new NodeList; - $this->nodeList->push(new Scalar('whatever string', 1)); - $this->assertEquals($this->nodeList->type, $this->nodeList::MULTILINE); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::checkTypeCoherence - */ - public function testCheckTypeCoherence(): void - { - $this->assertFalse($this->nodeList->checkTypeCoherence(null)); - $this->assertFalse($this->nodeList->checkTypeCoherence(0)); - $this->assertTrue($this->nodeList->checkTypeCoherence(4)); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::build - * @depends testPush - */ - public function testBuild(): void - { - $keyNode = new Key('key: keyvalue', 1); - $itemNode = new Item(' - itemvalue', 1); - $scalarNode = new Scalar('a string value', 1); - //expect object - $this->nodeList->push($keyNode); - $this->assertTrue(is_object($this->nodeList->build())); - // expect array - $this->nodeList = new NodeList; - $this->nodeList->push($itemNode); - $this->assertTrue(is_array($this->nodeList->build())); - // expect string - $this->nodeList = new NodeList; - $this->nodeList->push($scalarNode); - $this->assertTrue(is_string($this->nodeList->build())); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::buildList - */ - public function testBuildList(): void - { - $arr = []; - $this->assertEquals($arr, $this->nodeList->buildList($arr)); - $obj = new \StdClass; - $this->assertEquals($obj, $this->nodeList->buildList($obj)); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::buildMultiline - */ - public function testBuildMultiline(): void - { - //test when empty - $this->assertEquals(1, $this->nodeList->count(), 'NodeList count is wrong (+1 Nodeblank on setUp)'); - $this->assertEquals('', $this->nodeList->buildMultiline(), 'buildMultiline did not return a string'); - //test with one child - $this->nodeList->push(new Scalar('some string', 2));//var_dump($this->nodeList); - $this->assertEquals(2, $this->nodeList->count(), 'NodeList does NOT contain 2 children'); - $this->assertEquals('some string', $this->nodeList->buildMultiline(), 'buildMultiline failed with 2 children'); - //test with one child AND one blank - $this->nodeList->push(new Blank('', 2));//var_dump($this->nodeList); - $this->nodeList->push(new Scalar('other string', 3));//var_dump($this->nodeList); - $this->assertEquals(4, $this->nodeList->count(), 'NodeList does NOT contain 2 children'); - $this->assertEquals("some string\nother string", $this->nodeList->buildMultiline(), 'buildMultiline failed with 2 children'); - //test with two child - $this->nodeList->push(new Scalar('and some other string', 3)); - $this->assertEquals(5, $this->nodeList->count(), 'NodeList does NOT contain 3 nodes'); - $this->assertEquals("some string\nother string and some other string", $this->nodeList->buildMultiline(), "buildMultiline failed to provide correct string"); - } - - /** - * @covers \Dallgoot\Yaml\NodeList::filterComment - * @todo problem with building comments on YamlObject since theres no Root NodeGeneric and no Yaml object - */ - public function testFilterComment(): void - { - $this->nodeList->push(new Comment('# this is a comment', 1)); - $this->assertEquals(2, $this->nodeList->count()); - $filtered = $this->nodeList->filterComment(); - $this->assertEquals(1, $filtered->count()); - $this->assertEquals(2, $this->nodeList->count()); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/RegexTest.php b/classes/vendor/dallgoot/yaml/tests/units/RegexTest.php deleted file mode 100644 index 338d225..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/RegexTest.php +++ /dev/null @@ -1,91 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Regex - */ -class RegexTest extends TestCase -{ - /** - * @var Regex $regex An instance of "Regex" to test. - */ - private $regex; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->regex = new Regex(); - } - - /** - * @covers \Dallgoot\Yaml\Regex::isDate - */ - public function testIsDate(): void - { - $this->assertTrue($this->regex::isDate('2002-12-14')); - $this->assertTrue($this->regex::isDate('2002/12/14')); - $this->assertTrue($this->regex::isDate('2001-12-15T02:59:43.1Z')); - $this->assertTrue($this->regex::isDate('2001-12-14 21:59:43.10 -5')); - $this->assertTrue($this->regex::isDate('2001-12-14t21:59:43.10-05:00')); - //not conforing dates - $this->assertFalse($this->regex::isDate('20-12-2004')); - } - - /** - * @covers \Dallgoot\Yaml\Regex::isDate - */ - public function testIsDateWithNoString(): void - { - $this->expectException(\TypeError::class); - $this->assertFalse($this->regex::isDate(null)); - } - - /** - * @covers \Dallgoot\Yaml\Regex::isNumber - */ - public function testIsNumber(): void - { - $this->assertTrue($this->regex::isNumber('0o45')); - $this->assertTrue($this->regex::isNumber('0xa7')); - $this->assertTrue($this->regex::isNumber('123')); - $this->assertTrue($this->regex::isNumber('123.456')); - $this->assertTrue($this->regex::isNumber('.6')); - // not standard numbers - $this->assertFalse($this->regex::isNumber('123.45.6')); - $this->assertFalse($this->regex::isNumber('0x')); - $this->assertFalse($this->regex::isNumber('0o')); - } - - /** - * @covers \Dallgoot\Yaml\Regex::isProperlyQuoted - */ - public function testIsProperlyQuoted(): void - { - $this->assertTrue($this->regex::isProperlyQuoted(' " " ')); - $this->assertTrue($this->regex::isProperlyQuoted(' " \" " ')); - $this->assertTrue($this->regex::isProperlyQuoted(" ' ' ")); - $this->assertTrue($this->regex::isProperlyQuoted(" ' \' ' ")); - $this->assertTrue($this->regex::isProperlyQuoted("' 'a' 'b' '")); - $this->assertTrue($this->regex::isProperlyQuoted('" "a" "b" "')); - $this->assertTrue($this->regex::isProperlyQuoted('" \"a\" \'b\' "')); - - $this->assertFalse($this->regex::isProperlyQuoted('" \"a\" \'b\' ')); - - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/YamlTest.php b/classes/vendor/dallgoot/yaml/tests/units/YamlTest.php deleted file mode 100644 index 640ba63..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/YamlTest.php +++ /dev/null @@ -1,111 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml - */ -class YamlTest extends TestCase -{ - /** - * @var Yaml $yaml An instance of "Yaml" to test. - */ - private $yaml; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->yaml = new Yaml(); - } - - /** - * @covers \Dallgoot\Yaml::parse - */ - public function testParse(): void - { - $yaml = "- 1\n- 2\n- 3\n"; - $this->assertTrue($this->yaml::parse($yaml) instanceof YamlObject); - } - - /** - * @covers \Dallgoot\Yaml::parse - */ - public function testParseException(): void - { - $this->expectException(\Exception::class); - $this->yaml::parse('::'); - } - - /** - * @covers \Dallgoot\Yaml::parseFile - */ - public function testParseFile(): void - { - $this->assertTrue($this->yaml::parseFile(__DIR__."/../definitions/parsing_tests.yml") instanceof YamlObject); - } - - /** - * @covers \Dallgoot\Yaml::parseFile - */ - public function testParseFileException(): void - { - $this->expectException(\Exception::class); - $this->yaml::parseFile('ssh:example.com'); - } - - /** - * @covers \Dallgoot\Yaml::dump - */ - public function testDump(): void - { - $this->assertEquals("- 1\n- 2\n- 3", $this->yaml::dump([1,2,3])); - $this->assertEquals("--- some text\n", $this->yaml::dump('some text')); - } - - /** - * @covers \Dallgoot\Yaml::dump - */ - public function testDumpException(): void - { - $this->expectException(\Throwable::class); - $this->yaml::dump(null); - } - - /** - * @covers \Dallgoot\Yaml::dumpFile - */ - public function testDumpFile(): void - { - $filename = 'dumperTest.yml'; - $result = $this->yaml::dumpFile($filename, [1,2,3]); - $this->assertTrue($result); - $this->assertEquals("- 1\n- 2\n- 3", file_get_contents($filename)); - unlink($filename); - } - - /** - * @covers \Dallgoot\Yaml::dumpFile - */ - public function testDumpFileException(): void - { - $this->expectException(\Throwable::class); - $this->yaml::dumpFile('someFileName', null); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/AnchorTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/AnchorTest.php deleted file mode 100644 index 5115974..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/AnchorTest.php +++ /dev/null @@ -1,77 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Anchor - */ -class AnchorTest extends TestCase -{ - /** - * @var Anchor $nodeAnchor An instance of "Nodes\Anchor" to test. - */ - private $nodeAnchor; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeAnchor = new Anchor('&aaa sometext', 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Anchor::build - */ - public function testBuild(): void - { - $yamlObject = new YamlObject(0); - $rootNode = new Root(); - $rootNode->add($this->nodeAnchor); - $reflector = new \ReflectionClass($rootNode); - $buildFinal = $reflector->getMethod('buildFinal'); - $buildFinal->setAccessible(true); - $buildFinal->invoke($rootNode, $yamlObject); - $this->assertEquals('sometext', $this->nodeAnchor->build()); - // test exsting reference - $anchorValue = '12345'; - $yamlObject = new YamlObject(0); - $rootNode = new Root(); - $this->nodeAnchor = new Anchor('*aaa', 1); - - $rootNode->add($this->nodeAnchor); - $yamlObject->addReference('aaa', $anchorValue); - $buildFinal = new \ReflectionMethod($rootNode, 'buildFinal'); - $buildFinal->setAccessible(true); - $buildFinal->invoke($rootNode, $yamlObject); - $this->assertEquals('12345', $this->nodeAnchor->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Anchor::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertFalse($this->nodeAnchor->IsAwaitingChild($uselessNode)); - $this->nodeAnchor->value = null; - $this->assertTrue($this->nodeAnchor->IsAwaitingChild($uselessNode)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/BlankTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/BlankTest.php deleted file mode 100644 index 6a83a80..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/BlankTest.php +++ /dev/null @@ -1,106 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Blank - */ -class BlankTest extends TestCase -{ - /** - * @var Blank $nodeBlank An instance of "Nodes\Blank" to test. - */ - private $nodeBlank; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeBlank = new Blank('', 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Blank::add - */ - public function testAdd(): void - { - $nodeLit = new Literal('|', 1); - $this->assertTrue(is_null($nodeLit->value)); - $nodeLit->add($this->nodeBlank); - $this->assertTrue($nodeLit->value->offsetGet(0) === $this->nodeBlank); - $nodeScalar = new Scalar('sometext', 3); - $this->nodeBlank->add($nodeScalar); - $this->assertTrue($nodeLit->value instanceof NodeList); - $this->assertTrue($nodeLit->value->offsetGet(1) === $nodeScalar); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Blank::specialProcess - */ - public function testSpecialProcess(): void - { - $blankBuffer = []; - $previousScalarParent = new Literal('|-', 1); - $previousScalar = new Scalar(' sometext', 2); - $previousScalarParent->add($previousScalar); - $this->assertTrue($this->nodeBlank->specialProcess($previousScalar, $blankBuffer)); - $this->assertEquals($this->nodeBlank, $blankBuffer[0]); - $this->assertEquals($this->nodeBlank->getParent(), $previousScalarParent); - $blankBuffer = []; - $keyNode = new Key(' somelit: |', 1); - $this->assertTrue($this->nodeBlank->specialProcess($keyNode, $blankBuffer)); - $this->assertEquals($this->nodeBlank, $blankBuffer[0]); - $this->assertEquals($this->nodeBlank->getParent(), $keyNode->value); - - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Blank::build - */ - public function testBuild(): void - { - $this->assertEquals("\n", $this->nodeBlank->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Blank::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $uselessNode = new Scalar('sometext with no indent', 3); - $blankBuffer = []; - $keyNode = new Key(' somelit: |', 1); - $keyNode->add($this->nodeBlank); - $this->assertEquals($this->nodeBlank->getTargetOnEqualIndent($uselessNode), $keyNode); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Blank::getTargetOnMoreIndent - */ - public function testGetTargetOnMoreIndent(): void - { - $uselessNode = new Scalar('sometext with no indent', 3); - $blankBuffer = []; - $keyNode = new Key(' somelit: |', 1); - $keyNode->add($this->nodeBlank); - $this->assertEquals($this->nodeBlank->getTargetOnMoreIndent($uselessNode), $keyNode); } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/CommentTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/CommentTest.php deleted file mode 100644 index 5f65dd7..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/CommentTest.php +++ /dev/null @@ -1,69 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Comment - */ -class CommentTest extends TestCase -{ - /** - * @var Comment $nodeComment An instance of "Nodes\Comment" to test. - */ - private $nodeComment; - - private $commentLine = 5; - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeComment = new Comment('#this is a comment for test', $this->commentLine); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Comment::specialProcess - */ - public function testSpecialProcess(): void - { - $keyNode = new Key(' key: keyvalue',1); - $rootNode = new Root(); - $rootNode->add($keyNode); - $blankBuffer = []; - $this->assertTrue($this->nodeComment->specialProcess($keyNode, $blankBuffer)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Comment::build - */ - public function testBuild(): void - { - $yamlObject = new YamlObject(0); - $rootNode = new Root; - $reflector = new \ReflectionClass($rootNode); - $method = $reflector->getMethod('buildFinal'); - $method->setAccessible(true); - $method->invoke($rootNode, $yamlObject); - $rootNode->add($this->nodeComment); - $this->nodeComment->build(); - $this->assertEquals($yamlObject->getComment($this->commentLine), $this->nodeComment->raw); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactMappingTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactMappingTest.php deleted file mode 100644 index 945dcf4..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactMappingTest.php +++ /dev/null @@ -1,72 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\CompactMapping - */ -class CompactMappingTest extends TestCase -{ - /** - * @var CompactMapping $nodeCompactMapping An instance of "Nodes\CompactMapping" to test. - */ - private $nodeCompactMapping; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeCompactMapping = new CompactMapping(" {a : 123, b: abc } ", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\CompactMapping::__construct - */ - public function testConstruct(): void - { - $children = $this->nodeCompactMapping->value; - $this->assertTrue($children instanceof NodeList); - $this->assertTrue($children[0] instanceof Key); - $this->assertTrue($children[0]->value instanceof Scalar); - $this->assertTrue($children[1] instanceof Key); - $this->assertTrue($children[1]->value instanceof Scalar); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\CompactMapping::build - */ - public function testBuild(): void - { - $result = $this->nodeCompactMapping->build(); - $this->assertTrue($result instanceof Compact); - $this->assertTrue(property_exists($result, 'a')); - $this->assertEquals(123, $result->a); - $this->assertTrue(property_exists($result, 'b')); - $this->assertEquals('abc', $result->b); - $this->nodeCompactMapping->value = null; - $this->assertTrue(is_null($this->nodeCompactMapping->build())); - // test single value converted to list - $this->nodeCompactMapping = new CompactMapping(" { a : 123 } ", 42); - $result = $this->nodeCompactMapping->build(); - $this->assertTrue($result instanceof Compact); - $this->assertTrue(property_exists($result, 'a')); - $this->assertEquals(123, $result->a); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactSequenceTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactSequenceTest.php deleted file mode 100644 index 8dc3995..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/CompactSequenceTest.php +++ /dev/null @@ -1,77 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\CompactSequence - */ -class CompactSequenceTest extends TestCase -{ - /** - * @var CompactSequence $nodeCompactSequence An instance of "Nodes\CompactSequence" to test. - */ - private $nodeCompactSequence; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeCompactSequence = new CompactSequence(" [ 1, ad, [456] ]", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\CompactSequence::__construct - */ - public function testConstruct(): void - { - $children = $this->nodeCompactSequence->value; - $this->assertTrue($children instanceof NodeList); - $this->assertTrue($children[0] instanceof Item); - $this->assertTrue($children[0]->value instanceof Scalar); - $this->assertTrue($children[1] instanceof Item); - $this->assertTrue($children[1]->value instanceof Scalar); - $this->assertTrue($children[2] instanceof item); - $this->assertTrue($children[2]->value instanceof JSON); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\CompactSequence::build - */ - public function testBuild(): void - { - $result = $this->nodeCompactSequence->build(); - $this->assertTrue($result instanceof Compact); - $this->assertArrayHasKey(0, $result); - $this->assertEquals(1, $result[0]); - $this->assertArrayHasKey(1, $result); - $this->assertEquals('ad', $result[1]); - $this->assertArrayHasKey(2, $result); - $this->assertEquals([456], $result[2]); - $this->nodeCompactSequence->value = null; - $this->assertTrue(is_null($this->nodeCompactSequence->build())); - //test single NodeGeneric absorbed in NodeList - $this->nodeCompactSequence = new CompactSequence(" [ [456] ]", 42); - $result = $this->nodeCompactSequence->build(); - $this->assertTrue($result instanceof Compact); - $this->assertArrayHasKey(0, $result); - $this->assertEquals([456], $result[0]); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/DirectiveTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/DirectiveTest.php deleted file mode 100644 index e9837ce..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/DirectiveTest.php +++ /dev/null @@ -1,73 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Directive - */ -class DirectiveTest extends TestCase -{ - /** - * @var NodeDirective $nodeDirective An instance of "Nodes\Directive" to test. - */ - private $nodeDirective; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeDirective = new Directive('%YAML 1.2'); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Directive::build - */ - public function testBuild(): void - { - $this->assertTrue(is_null($this->nodeDirective->build())); - $this->nodeDirective = new Directive('%TAG ! tag:clarkevans.com,2002:'); - $rootNode = new Root; - $rootNode->add($this->nodeDirective); - $yamlObject = new YamlObject(0); - $rootNode->build($yamlObject); - $this->assertEquals('tag:clarkevans.com,2002:', TagFactory::$schemaHandles['!']); - } - - public function testBuildError(): void - { - $this->expectException(\ParseError::class); - $this->nodeDirective = new Directive('%TAG ! tag:clarkevans.com,2002:'); - $directive2 = new Directive('%TAG ! tag:clarkevans.com,2002:'); - $rootNode = new Root; - $rootNode->add($this->nodeDirective); - $yamlObject = new YamlObject(0); - $rootNode->build($yamlObject); - } - /** - * @covers \Dallgoot\Yaml\Nodes\Directive::add - */ - public function testAdd(): void - { - $uselessNode = new Blank('', 2); - $this->assertTrue($this->nodeDirective->add($uselessNode) === $uselessNode); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/DocEndTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/DocEndTest.php deleted file mode 100644 index a7e69b1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/DocEndTest.php +++ /dev/null @@ -1,43 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\DocEnd - */ -class DocEndTest extends TestCase -{ - /** - * @var DocEnd $nodeDocEnd An instance of "Nodes\DocEnd" to test. - */ - private $nodeDocEnd; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeDocEnd = new DocEnd('...'); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocEnd::build - */ - public function testBuild(): void - { - $this->assertTrue(is_null($this->nodeDocEnd->build())); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/DocStartTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/DocStartTest.php deleted file mode 100644 index b31785a..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/DocStartTest.php +++ /dev/null @@ -1,133 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\DocStart - */ -class DocStartTest extends TestCase -{ - /** - * @var DocStart $nodeDocStart An instance of "Nodes\DocStart" to test. - */ - private $nodeDocStart; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeDocStart = new DocStart("---", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocStart::__construct - */ - public function testConstruct(): void - { - $this->assertTrue(is_null($this->nodeDocStart->value)); - $this->nodeDocStart = new DocStart("--- sometext", 42); - $this->assertTrue($this->nodeDocStart->value instanceof Scalar); - $this->nodeDocStart = new DocStart("--- !sometag", 42); - $this->assertTrue($this->nodeDocStart->value instanceof Tag); - $this->nodeDocStart = new DocStart("--- #some comment", 42); - $this->assertTrue($this->nodeDocStart->value instanceof Comment); - $this->nodeDocStart = new DocStart("--- &someanchor", 42); - $this->assertTrue($this->nodeDocStart->value instanceof Anchor); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocStart::add - */ - public function testAdd(): void - { - $blankNode = new Blank('', 2); - $this->assertEquals($blankNode, $this->nodeDocStart->add($blankNode)); - $this->assertEquals($blankNode, $this->nodeDocStart->value); - $nodeTag = new Tag('!tagname', 2); - $this->nodeDocStart->value = null; - $this->nodeDocStart->add($nodeTag); - $this->assertEquals($nodeTag, $this->nodeDocStart->value); - $this->nodeDocStart->add($blankNode); - $this->assertEquals($nodeTag, $this->nodeDocStart->value); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocStart::build - */ - public function testBuild(): void - { - $yamlObject = new YamlObject(0); - $this->assertTrue(is_null($this->nodeDocStart->build($yamlObject))); - $this->nodeDocStart->add(new Tag('!', 2)); - $this->nodeDocStart->build($yamlObject); - $this->assertTrue($yamlObject->isTagged()); - $this->nodeDocStart->value = null; - $nodeLit = new LiteralFolded('>-', 1); - $nodeScalar1 = new Scalar(' some text', 2); - $nodeScalar2 = new Scalar(' other text', 3); - $nodeLit->add($nodeScalar1); - $nodeLit->add($nodeScalar2); - $this->nodeDocStart->add($nodeLit); - $this->assertTrue(is_null($this->nodeDocStart->build($yamlObject))); - $this->assertEquals("some text other text", ''.$yamlObject); - - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocStart::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertFalse($this->nodeDocStart->isAwaitingChild($uselessNode)); - - $this->nodeDocStart->value = new Anchor('&anchor anchorDefinedWithValue', 1); - $this->assertTrue($this->nodeDocStart->isAwaitingChild($uselessNode)); - - $this->nodeDocStart->value = new Literal('|+', 1); - $this->assertTrue($this->nodeDocStart->isAwaitingChild($uselessNode)); - - $this->nodeDocStart->value = new LiteralFolded('>-', 1); - $this->assertTrue($this->nodeDocStart->isAwaitingChild($uselessNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\DocStart::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $blank = new Blank('', 1); - $rootNode = new Root(); - $rootNode->add($this->nodeDocStart); - $this->assertEquals($rootNode, $this->nodeDocStart->GetTargetOnEqualIndent($blank)); - - $nodeLitFolded = new LiteralFolded('>-', 1); - $this->nodeDocStart->value = $nodeLitFolded; - $this->assertEquals($nodeLitFolded, $this->nodeDocStart->GetTargetOnEqualIndent($blank)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/ItemTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/ItemTest.php deleted file mode 100644 index 5423296..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/ItemTest.php +++ /dev/null @@ -1,174 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Item - */ -class ItemTest extends TestCase -{ - /** - * @var Item $nodeItem An instance of "Nodes\Item" to test. - */ - private $nodeItem; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeItem = new Item(" -", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::__construct - */ - public function testConstruct(): void - { - $this->assertTrue(is_null($this->nodeItem->value)); - $this->nodeItem = new Item(" - itemvalue", 42); - $this->assertTrue($this->nodeItem->value instanceof Scalar); - $this->nodeItem = new Item(" - keyinside: keyvalue", 42); - $this->assertTrue($this->nodeItem->value instanceof Key); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::add - */ - public function testAdd(): void - { - $this->assertTrue(is_null($this->nodeItem->value)); - // - $this->nodeItem = new Item(' - keyinside: keyvalue', 1); - $keyNode = new Key(' anotherkey: anothervalue', 3); - $this->nodeItem->add($keyNode); - $this->assertTrue($this->nodeItem->value instanceof NodeList); - // - $this->nodeItem = new Item(' - keyinside:', 3); - $keyNode = new Key(' childkey: anothervalue', 4); - $this->nodeItem->add($keyNode); - $keyinside = $this->nodeItem->value; - $this->assertEquals($keyNode, $keyinside->value); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::add - */ - public function testAddException(): void - { - $this->expectException(\ParseError::class); - $this->nodeItem = new Item(' - keyinside: keyvalue', 1); - $keyNode = new Key(' anotherkey: anothervalue', 3); - $this->nodeItem->add($keyNode); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $rootNode = new Root; - $rootNode->add($this->nodeItem); - $itemNode = new Item('- item2', 1); - $this->assertEquals($rootNode, $this->nodeItem->getTargetOnEqualIndent($itemNode)); - // - $rootNode = new Root; - $this->nodeItem = new Item('- sameindentitem', 3); - $keyNode = new Key('key_with_no_indent_a_sequence:', 1); - $rootNode->add($keyNode); - $keyNode->add($this->nodeItem); - // $this->nodeItem->add($keyNode); - $itemNode2 = new Item('- item_with_no_indent: 123', 2); - $parent = $this->nodeItem->getTargetOnEqualIndent($itemNode2); - $this->assertEquals($rootNode, $parent); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::getTargetOnMoreIndent - */ - public function testGetTargetOnMoreIndent(): void - { - $blankNode = new Blank('', 1); - $this->assertEquals($this->nodeItem, $this->nodeItem->getTargetOnMoreIndent($blankNode)); - $keyNode = new Key('key:', 1); - $this->nodeItem->add($keyNode); - $this->assertEquals($keyNode, $this->nodeItem->getTargetOnMoreIndent($blankNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::build - */ - public function testBuild(): void - { - // no parent - $this->assertEquals([null], $this->nodeItem->build()); - $parent = []; - $this->assertEquals(null, $this->nodeItem->build($parent)); - $this->assertEquals([0 => null], $parent); - $parent = new YamlObject(0); - $this->assertEquals(null, $this->nodeItem->build($parent)); - $this->assertArrayHasKey(0, $parent); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::build - */ - public function testBuildWhenParentIsString() - { - $this->expectException(\Exception::class); - $parent = ''; - $this->nodeItem->build($parent); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::build - */ - public function testBuildWhenParentIsObject() - { - $this->expectException(\Exception::class); - $parent = new \StdClass; - $this->nodeItem->build($parent); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Item::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $blankNode = new Blank('', 1); - $this->assertTrue($this->nodeItem->isAwaitingChild($blankNode)); - // - $setkeyNode = new SetKey('? setkey', 1); - $setvalueNode = new SetValue(': setvalue', 2); - $this->nodeItem->add($setkeyNode); - $this->assertTrue($this->nodeItem->isAwaitingChild($setvalueNode)); - // - $this->nodeItem->value = null; - $keyNode = new Key(' key: ', 42); - $scalarNode = new Scalar(' some text', 43); - $this->nodeItem->add($keyNode); - $this->assertTrue($this->nodeItem->isAwaitingChild($scalarNode)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/JSONTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/JSONTest.php deleted file mode 100644 index f67e438..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/JSONTest.php +++ /dev/null @@ -1,43 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\JSON - */ -class JSONTest extends TestCase -{ - /** - * @var JSON $nodeJSON An instance of "Nodes\JSON" to test. - */ - private $nodeJSON; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeJSON = new JSON(' [1,2,3]',1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\JSON::build - */ - public function testBuild(): void - { - $this->assertEquals([1,2,3], $this->nodeJSON->build()); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/KeyTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/KeyTest.php deleted file mode 100644 index 1000a2a..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/KeyTest.php +++ /dev/null @@ -1,211 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Key - */ -class KeyTest extends TestCase -{ - /** - * @var Key $nodeKey An instance of "Nodes\Key" to test. - */ - private $nodeKey; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeKey = new Key("key: value", 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::__construct - */ - public function testConstruct(): void - { - $this->assertTrue($this->nodeKey->value instanceof Scalar); - $this->nodeKey = new Key("key:", 1); - $this->assertTrue(is_null($this->nodeKey->value)); - $this->nodeKey = new Key("key: ", 1); - $this->assertTrue(is_null($this->nodeKey->value)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::__construct - */ - public function testConstructException(): void - { - $this->expectException(\ParseError::class); - $this->nodeKey->__construct('not a key at all and no matches', 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::setIdentifier - */ - public function testSetIdentifier(): void - { - $reflector = new \ReflectionClass($this->nodeKey); - $identifier = $reflector->getProperty('identifier'); - $identifier->setAccessible(true); - - $this->nodeKey->setIdentifier('newkey'); - $this->assertEquals('newkey', $identifier->getValue($this->nodeKey)); - - $this->nodeKey->setIdentifier('!!str 1.2'); - $this->assertEquals(null, $this->nodeKey->tag); - $this->assertEquals('1.2', $identifier->getValue($this->nodeKey)); - - $this->nodeKey->setIdentifier('&anchor 1.2'); - $this->assertEquals(null, $this->nodeKey->anchor); - $this->assertEquals('1.2', $identifier->getValue($this->nodeKey)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::setIdentifier - */ - public function testSetIdentifierAsEmptyString() - { - $this->expectException(\ParseError::class); - $this->nodeKey->setIdentifier(''); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::add - */ - public function testAdd(): void - { - $scalarNode = new Scalar('sometext', 2); - $this->nodeKey = new Key("key:", 1); - $this->nodeKey->add($scalarNode); - $this->assertEquals($scalarNode, $this->nodeKey->value); - // - $this->nodeKey = new Key("key: |", 1); - $this->nodeKey->add($scalarNode); - $nodeLit = $this->nodeKey->value; - $this->assertEquals($scalarNode, $nodeLit->value->offsetGet(0)); - // - $this->nodeKey = new Key("key: >", 1); - $this->nodeKey->add($scalarNode); - $nodeLitFolded = $this->nodeKey->value; - $this->assertEquals($scalarNode, $nodeLitFolded->value->offsetGet(0)); - // - $this->nodeKey = new Key("key: &anchor", 1); - $this->nodeKey->add($scalarNode); - $nodeAnchor = $this->nodeKey->value; - $this->assertEquals($scalarNode, $nodeAnchor->value); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $nodeItem = new Item(' - an_item', 2); - $this->nodeKey = new Key(" key:", 1); - $this->assertEquals($this->nodeKey, $this->nodeKey->getTargetOnEqualIndent($nodeItem)); - - $blankNode = new Blank('', 3); - $rootNode = new Root; - $rootNode->add($this->nodeKey); - $this->assertEquals($this->nodeKey->getParent(), $this->nodeKey->getTargetOnEqualIndent($blankNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::getTargetOnMoreIndent - */ - public function testGetTargetOnMoreIndent(): void - { - $blankNode = new Blank('', 2); - $this->assertEquals($this->nodeKey, $this->nodeKey->getTargetOnMoreIndent($blankNode)); - - $this->nodeKey = new Key(" key: &anchor |", 1); - $anchorNode = $this->nodeKey->value; - $this->assertEquals($anchorNode->value, $this->nodeKey->getTargetOnMoreIndent($blankNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Key::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $blankNode = new Blank('', 42); - $this->assertTrue($this->nodeKey->isAwaitingChild($blankNode)); - // - $this->nodeKey->value = new Comment('# this is a comment', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild($blankNode)); - // - $this->nodeKey->value = new Scalar('this is a text', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild($blankNode)); - // - $this->nodeKey->value = new Item(' - item', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild(new Item(' - item2', 2))); - // - $this->nodeKey->value = new Key(' key1:', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild(new Key(' key2:', 2))); - // - $this->nodeKey->value = new Literal(' |', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild(new Key(' key2:', 2))); - // - $this->nodeKey->value = new Anchor(' &anchor', 1); - $this->assertTrue($this->nodeKey->isAwaitingChild(new Key(' key2:', 2))); - // - $this->nodeKey->value = new Anchor(' &anchor already have a value', 1); - $this->assertFalse($this->nodeKey->isAwaitingChild(new Key(' key2:', 2))); - } - /** - * @covers \Dallgoot\Yaml\Nodes\Key::build - */ - public function testBuild(): void - { - $keyTagged = new Key('!!str 1.2: value', 1); - $built = $keyTagged->build(); - $this->assertTrue(property_exists($built, '1.2')); - $this->assertEquals('value', $built->{'1.2'}); - // - $built = $this->nodeKey->build(); - $this->assertTrue(property_exists($built, 'key')); - $this->assertEquals('value', $built->key); - // - $parent = new \StdClass; - $built = $this->nodeKey->build($parent); - $this->assertTrue(property_exists($parent, 'key')); - $this->assertEquals('value', $parent->key); - // - $parent = new YamlObject(0); - $built = $this->nodeKey->build($parent); - $this->assertTrue(property_exists($parent, 'key')); - $this->assertEquals('value', $parent->key); - // - $this->nodeKey->value = null; - $built = $this->nodeKey->build(); - $this->assertTrue(property_exists($built, 'key')); - $this->assertEquals(null, $built->key); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralFoldedTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralFoldedTest.php deleted file mode 100644 index ed495f3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralFoldedTest.php +++ /dev/null @@ -1,59 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\LiteralFolded - */ -class LiteralFoldedTest extends TestCase -{ - /** - * @var LiteralFolded $nodeLitFolded An instance of "Nodes\LiteralFolded" to test. - */ - private $nodeLitFolded; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeLitFolded = new LiteralFolded('>-', 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\LiteralFolded::getFinalString - */ - public function testGetFinalString(): void - { - $line1 = new Scalar(' - with inside', 2); - $line1a = new Scalar(' two', 3); - $line1b = new Scalar(' children', 4); - $line2 = new Scalar(' some more indented text', 5); - $line3 = new Scalar(' other less indented text', 6); - $list = new NodeList; - $list->push($line1); - $list->push($line1a); - $list->push($line1b); - $list->push($line2); - $list->push($line3); - $this->assertEquals( - "- with inside\ntwo\nchildren\nsome more indented text\nother less indented text", - $this->nodeLitFolded->getFinalString($list)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralTest.php deleted file mode 100644 index 735bd5c..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/LiteralTest.php +++ /dev/null @@ -1,53 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Literal - */ -class LiteralTest extends TestCase -{ - /** - * @var Literal $nodeLit An instance of "Nodes\Literal" to test. - */ - private $nodeLit; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeLit = new Literal('|', 1); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literal::getFinalString - */ - public function testGetFinalString(): void - { - $line1 = new Scalar(' some text', 2); - $line2 = new Scalar(' some more indented text', 3); - $line3 = new Scalar(' other less indented text', 4); - $list = new NodeList; - $list->push($line1); - $list->push($line2); - $list->push($line3); - $this->assertEquals("some text\n some more indented text\nother less indented text", - $this->nodeLit->getFinalString($list)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/PartialTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/PartialTest.php deleted file mode 100644 index 1590b5e..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/PartialTest.php +++ /dev/null @@ -1,92 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Partial - */ -class PartialTest extends TestCase -{ - /** - * @var Partial $nodePartial An instance of "Nodes\Partial" to test. - */ - private $nodePartial; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodePartial = new Partial(' " partially quoted'); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Partial::specialProcess - */ - public function testSpecialProcess(): void - { - $blankBuffer = []; - $node = new Scalar(' end of quoting"', 2); - $parent = new Scalar(' emptykey:', 1); - $parent->add($this->nodePartial); - $this->assertTrue($this->nodePartial->specialProcess($node, $blankBuffer)); - $this->assertTrue($parent->value instanceof Quoted); - $this->assertEquals(" partially quoted end of quoting", $parent->value->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Partial::specialProcess - */ - public function testSpecialProcessWithPreviousLineFeed(): void - { - $this->nodePartial = new Partial(" ' partially quoted\n"); - $blankBuffer = []; - $node = new Scalar(" end of quoting'", 2); - $parent = new Scalar(' emptykey:', 1); - $parent->add($this->nodePartial); - $this->assertTrue($this->nodePartial->specialProcess($node, $blankBuffer)); - $this->assertTrue($parent->value instanceof Quoted); - $this->assertEquals(" partially quoted\nend of quoting", $parent->value->build()); - - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Partial::specialProcess - */ - public function testSpecialProcessWithNodeBlank(): void - { - $blankBuffer = []; - $current = new Blank('', 2); - $parent = new Scalar(' emptykey:', 1); - $parent->add($this->nodePartial); - $this->assertTrue($this->nodePartial->specialProcess($current, $blankBuffer)); - $this->assertTrue($parent->value instanceof Partial); - $this->assertEquals(" \" partially quoted\n", $parent->value->raw); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Partial::build - */ - public function testBuild(): void - { - $this->expectException(\ParseError::class); - $this->nodePartial->build(); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/QuotedTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/QuotedTest.php deleted file mode 100644 index e7ca4fe..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/QuotedTest.php +++ /dev/null @@ -1,43 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Quoted - */ -class QuotedTest extends TestCase -{ - /** - * @var Quoted $nodeQuoted An instance of "Nodes\Quoted" to test. - */ - private $nodeQuoted; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeQuoted = new Quoted('"a quoted string"'); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Quoted::build - */ - public function testBuild(): void - { - $this->assertEquals("a quoted string", $this->nodeQuoted->build()); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/RootTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/RootTest.php deleted file mode 100644 index 75a9ff9..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/RootTest.php +++ /dev/null @@ -1,114 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Root - */ -class RootTest extends TestCase -{ - /** - * @var Root $nodeRoot An instance of "Nodes\Root" to test. - */ - private $nodeRoot; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->nodeRoot = new Root(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::__construct - */ - public function testConstruct(): void - { - $this->assertTrue($this->nodeRoot->value instanceof NodeList); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::getParent - */ - public function testGetParent(): void - { - $this->assertEquals($this->nodeRoot, $this->nodeRoot->getParent()); - $keyNode = new Key(' falsekey:', 1); - $keyNode->add($this->nodeRoot); - $this->expectException(\ParseError::class); - $this->nodeRoot->getParent(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::getRoot - */ - public function testGetRoot(): void - { - $this->assertEquals($this->nodeRoot, $this->nodeRoot->getRoot()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::getYamlObject - */ - public function testYamlObjectAbsent() - { - $this->expectException(\Exception::class); - $this->nodeRoot->getYamlObject(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::buildFinal - */ - public function testBuildFinal(): void - { - $buildFinal = new \ReflectionMethod($this->nodeRoot, 'buildFinal'); - $buildFinal->setAccessible(true); - $yamlObject = new YamlObject(0); - $result = $buildFinal->invoke($this->nodeRoot, $yamlObject); - $this->assertEquals($yamlObject, $result); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::getYamlObject - * @depends testBuildFinal - */ - public function testYamlObjectPresent() - { - $buildFinal = new \ReflectionMethod($this->nodeRoot, 'buildFinal'); - $buildFinal->setAccessible(true); - $yamlObject = new YamlObject(0); - $result = $buildFinal->invoke($this->nodeRoot, $yamlObject); - - $this->assertEquals($yamlObject, $result); - $this->assertEquals($yamlObject, $this->nodeRoot->getYamlObject()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Root::build - */ - public function testBuild(): void - { - $yamlObject = new YamlObject(0); - $this->assertTrue($this->nodeRoot->build($yamlObject) instanceof YamlObject); - } - -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/ScalarTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/ScalarTest.php deleted file mode 100644 index 10fa311..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/ScalarTest.php +++ /dev/null @@ -1,138 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Scalar - */ -class ScalarTest extends TestCase -{ - /** - * @var Scalar $nodeScalar An instance of "Nodes\Scalar" to test. - */ - private $nodeScalar; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeScalar = new Scalar("a string to test", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::__construct - */ - public function testConstruct(): void - { - // only a Sclar Node - $this->assertTrue(is_null($this->nodeScalar->value)); - // with a comment - $nodeScalar = new Scalar(' value # a comment', 1); - $this->assertTrue($nodeScalar->value instanceof NodeList); - $this->assertTrue($nodeScalar->value->offsetGet(0) instanceof Scalar); - $this->assertTrue($nodeScalar->value->offsetGet(1) instanceof Comment); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::build - */ - public function testBuild(): void - { - $this->assertEquals("a string to test", $this->nodeScalar->build()); - // - $this->nodeScalar->value = new Scalar('another string', 2); - $this->assertEquals('another string', $this->nodeScalar->build()); - // - $this->nodeScalar->raw = "123"; - $this->nodeScalar->value = null; - $this->assertEquals(123, $this->nodeScalar->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::build - */ - public function testBuildTagged(): void - { - $this->nodeScalar = new Scalar("123", 42); - $this->nodeScalar->tag = '!!str'; - $this->assertEquals('123', $this->nodeScalar->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::getTargetOnLessIndent - */ - public function testGetTargetOnLessIndent(): void - { - $parent = new Key(' emptykey: |', 1); - $nodeScalar = new Scalar(' somestring', 2); - $parent->add($this->nodeScalar); - $this->assertEquals($parent, $this->nodeScalar->getTargetOnLessIndent($parent)); - $this->assertTrue($this->nodeScalar->getParent() instanceof Literal); - // - $parent2 = new Key(' emptykey2:', 1); - $this->nodeScalar = new Scalar('somestring', 2); - $parent2->add($this->nodeScalar); - $blankNode = new Blank('', 3); - $this->assertEquals($parent2, $this->nodeScalar->getTargetOnLessIndent($blankNode)); - $this->assertEquals($parent2, $this->nodeScalar->getParent()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::getTargetOnMoreIndent - */ - public function testGetTargetOnMoreIndent(): void - { - $parent = new Key(' emptykey:', 1); - $parent->add($this->nodeScalar); - $this->assertEquals($parent, $this->nodeScalar->getTargetOnMoreIndent($parent)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::getScalar - */ - public function testGetScalar(): void - { - $this->assertEquals($this->nodeScalar->getScalar('yes') , true); - $this->assertEquals($this->nodeScalar->getScalar('no') , false); - $this->assertEquals($this->nodeScalar->getScalar('true') , true); - $this->assertEquals($this->nodeScalar->getScalar('false'), false); - $this->assertEquals($this->nodeScalar->getScalar('null') , null); - $this->assertEquals($this->nodeScalar->getScalar('.inf') , \INF); - $this->assertEquals($this->nodeScalar->getScalar('-.inf'), -\INF); - $this->assertTrue(is_nan($this->nodeScalar->getScalar('.nan'))); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Scalar::getNumber - */ - public function testGetNumber(): void - { - $reflector = new \ReflectionClass($this->nodeScalar); - $method = $reflector->getMethod('getNumber'); - $method->setAccessible(true); - $this->assertTrue(is_numeric($method->invoke($this->nodeScalar, '132'))); - $this->assertTrue(is_numeric($method->invoke($this->nodeScalar, '0x27'))); - $this->assertTrue(is_numeric($method->invoke($this->nodeScalar, '0xaf'))); - $this->assertTrue(is_float($method->invoke($this->nodeScalar, '132.123'))); - $this->assertFalse(is_float($method->invoke($this->nodeScalar, '132.12.3'))); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/SetKeyTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/SetKeyTest.php deleted file mode 100644 index e4a10ba..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/SetKeyTest.php +++ /dev/null @@ -1,69 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\SetKey - */ -class SetKeyTest extends TestCase -{ - /** - * @var SetKey $nodeSetKey An instance of "Nodes\SetKey" to test. - */ - private $nodeSetKey; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeSetKey = new SetKey(" ? someStringKey", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetKey::__construct - */ - public function testConstruct(): void - { - $this->assertTrue($this->nodeSetKey->value instanceof Scalar); - $this->assertEquals('someStringKey', $this->nodeSetKey->value->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetKey::build - */ - public function testBuild(): void - { - $parent = new \StdClass; - $built = $this->nodeSetKey->build($parent); - $this->assertTrue(property_exists($parent, 'someStringKey')); - $this->assertEquals(null, $parent->someStringKey); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetKey::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertFalse($this->nodeSetKey->isAwaitingChild($uselessNode)); - $this->nodeSetKey->value = null; - $this->assertTrue($this->nodeSetKey->isAwaitingChild($uselessNode)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/SetValueTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/SetValueTest.php deleted file mode 100644 index 94150d3..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/SetValueTest.php +++ /dev/null @@ -1,70 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\SetValue - */ -class SetValueTest extends TestCase -{ - /** - * @var SetValue $nodeSetValue An instance of "Nodes\SetValue" to test. - */ - private $nodeSetValue; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeSetValue = new SetValue(" : a string to test", 42); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetValue::__construct - */ - public function testConstruct(): void - { - $this->assertTrue($this->nodeSetValue->value instanceof Scalar); - $this->assertEquals('a string to test', $this->nodeSetValue->value->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetValue::build - */ - public function testBuild(): void - { - $parent = new \StdClass; - $parent->lastKey = null; - $this->nodeSetValue->build($parent); - $this->assertTrue(property_exists($parent, 'lastKey')); - $this->assertEquals('a string to test', $parent->lastKey); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\SetValue::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertFalse($this->nodeSetValue->isAwaitingChild($uselessNode)); - $this->nodeSetValue->value = null; - $this->assertTrue($this->nodeSetValue->isAwaitingChild($uselessNode)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/TagTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/TagTest.php deleted file mode 100644 index 8b06eaa..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/TagTest.php +++ /dev/null @@ -1,90 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Tag - */ -class TagTest extends TestCase -{ - /** - * @var Tag $nodeTag An instance of "Nodes\Tag" to test. - */ - private $nodeTag; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->nodeTag = new Tag('!!str 654',0); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Tag::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertFalse($this->nodeTag->isAwaitingChild($uselessNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Tag::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $uselessNode = new Blank('', 1); - $parent = new Key(' key:', 1); - $parent->add($this->nodeTag); - $this->assertEquals($parent, $this->nodeTag->getTargetOnEqualIndent($uselessNode)); - // $this->nodeTag->value = null; - // $this->assertEquals($this->nodeTag, $this->nodeTag->getTargetOnEqualIndent($uselessNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Tag::build - */ - public function testBuild(): void - { - // test value tranformed - $parent = new Key(' key:',1); - $parent->add($this->nodeTag); - $built = $this->nodeTag->build(); - $this->assertEquals('654', $built); - // test apply tag to YamlObject (cause value is null and parent is a NodeRoot) - $rootNode = new Root(); - $rootNode->add($this->nodeTag); - $this->nodeTag->value = null; - $yamlObject = new YamlObject(0); - $this->assertFalse($yamlObject->isTagged()); - // add yamlObject to NodeRoot - $rootNode->build($yamlObject);// this triggers this->nodeTag->build - $this->assertTrue($yamlObject->isTagged()); - // test "unknown" ag: must return a Tag object - $this->nodeTag = new Tag('!!unknown 654',1); - $built = $this->nodeTag->build($yamlObject); - $this->assertTrue($built instanceof Tagged); - $this->assertEquals("!!unknown", $built->tagName); - $this->assertEquals("654", $built->value); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/ActionsTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/ActionsTest.php deleted file mode 100644 index 8a50fbe..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/ActionsTest.php +++ /dev/null @@ -1,62 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Actions - */ -class ActionsTest extends TestCase -{ - /** - * @var Actions $nodeActions An instance of "Nodes\Actions" to test. - */ - private $nodeActions; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - // $this->nodeActions = new Actions(" !!str sometext", 42); - $this->nodeActions = $this->getMockBuilder(Actions::class) - ->setConstructorArgs([" !!str sometext", 42]) - ->getMockForAbstractClass(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Actions::__construct - */ - public function testConstruct(): void - { - //note : true behaviour for Tag is "testConstructWithTag" - $this->assertEquals("!!str", $this->nodeActions->anchor); - $this->assertTrue($this->nodeActions->value instanceof Scalar); - $this->assertEquals("sometext", $this->nodeActions->value->raw); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Actions::__construct - */ - public function testConstructWithTag(): void - { - $tagNode = new Tag(" !!str sometext", 42); - $this->assertEquals("!!str", $tagNode->tag); - $this->assertTrue($tagNode->value instanceof Scalar); - $this->assertEquals("sometext", $tagNode->value->raw); - } - -} \ No newline at end of file diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/LiteralsTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/LiteralsTest.php deleted file mode 100644 index 445f7a5..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/LiteralsTest.php +++ /dev/null @@ -1,191 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\Literals - */ -class LiteralsTest extends TestCase -{ - /** - * @var Literals $nodeLiterals An instance of "Nodes\Literals" to test. - */ - private $nodeLiterals; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs(["|-", 42]) - ->getMockForAbstractClass(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::__construct - */ - public function testConstruct(): void - { - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs(["|", 42]) - ->getMockForAbstractClass(); - $reflector = new \ReflectionClass($this->nodeLiterals); - $identifier = $reflector->getProperty('identifier'); - $identifier->setAccessible(true); - $this->assertEquals(null, $identifier->getValue($this->nodeLiterals)); - // - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs(["|-", 42]) - ->getMockForAbstractClass(); - // - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs(["|+", 42]) - ->getMockForAbstractClass(); - $this->assertEquals('+', $identifier->getValue($this->nodeLiterals)); - // - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs([">-", 42]) - ->getMockForAbstractClass(); - // - $this->nodeLiterals = $this->getMockBuilder(Literals::class) - ->setConstructorArgs([">+", 42]) - ->getMockForAbstractClass(); - $this->assertEquals('+', $identifier->getValue($this->nodeLiterals)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::add - */ - public function testAdd(): void - { - $this->assertTrue(is_null($this->nodeLiterals->value)); - $this->nodeLiterals->add(new Scalar(' some text', 2)); - $this->assertTrue($this->nodeLiterals->value instanceof NodeList); - // - $this->nodeLiterals->value = null; - $falseItem = new Item(' - not an item', 2); - - $this->assertTrue($this->nodeLiterals->add($falseItem) instanceof Scalar); - $this->assertFalse($this->nodeLiterals->value->offsetGet(0) instanceof Item); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::litteralStripLeading - */ - public function testLitteralStripLeading(): void - { - $list = new NodeList(new Blank('', 1)); - $list->push(new Blank('', 2)); - $stripLeading = new \ReflectionMethod(Literals::class, 'litteralStripLeading'); - $stripLeading->setAccessible(true); - $stripLeading->invokeArgs(null, [&$list]); - $this->assertEquals(0, $list->count()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::litteralStripTrailing - */ - public function testLitteralStripTrailing(): void - { - $list = new NodeList(new Blank('', 1)); - $list->push(new Blank('', 2)); - $stripTrailing = new \ReflectionMethod(Literals::class, 'litteralStripTrailing'); - $stripTrailing->setAccessible(true); - $stripTrailing->invokeArgs(null, [&$list]); - $this->assertEquals(0, $list->count()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::build - */ - public function testBuild(): void - { - $this->assertEquals('', $this->nodeLiterals->build()); - // - $nodeLit = new Literal("|", 42); - $nodeLit->add(new Scalar(' sometext', 2)); - $nodeLit->add(new Scalar(' othertext', 2)); - $this->assertTrue($nodeLit->value instanceof NodeList); - $this->assertTrue($nodeLit->value->offsetGet(0) instanceof Scalar); - $this->assertEquals("sometext\nothertext\n", $nodeLit->build()); - // // - $nodeLitClipped = new Literal("|-", 42); - $nodeLitClipped->add(new Scalar(' sometext', 2)); - $nodeLitClipped->add(new Scalar(' othertext', 2)); - $this->assertTrue($nodeLitClipped->value instanceof NodeList); - $this->assertTrue($nodeLitClipped->value->offsetGet(0) instanceof Scalar); - $this->assertEquals("sometext\nothertext", $nodeLitClipped->build()); - // - $nodeLitFolded = new LiteralFolded(">", 42); - $nodeLitFolded->add(new Scalar(' sometext', 2)); - $nodeLitFolded->add(new Scalar(' othertext', 2)); - $this->assertTrue($nodeLitFolded->value instanceof NodeList); - $this->assertTrue($nodeLitFolded->value->offsetGet(0) instanceof Scalar); - $this->assertEquals("sometext othertext\n", $nodeLitFolded->build()); - // // - $nodeLitFoldedClipped = new LiteralFolded(">-", 42); - $nodeLitFoldedClipped->add(new Scalar(' sometext', 2)); - $nodeLitFoldedClipped->add(new Scalar(' othertext', 2)); - $this->assertTrue($nodeLitFoldedClipped->value instanceof NodeList); - $this->assertTrue($nodeLitFoldedClipped->value->offsetGet(0) instanceof Scalar); - $this->assertEquals("sometext othertext", $nodeLitFoldedClipped->build()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::getChildValue - */ - public function testGetChildValue(): void - { - $getChildValue = new \ReflectionMethod($this->nodeLiterals, 'getChildValue'); - $getChildValue->setAccessible(true); - $nodeQuoted = new Quoted(' "sometext"', 1); - $nodeScalar = new Scalar(' sometext', 1); - $nodeItem = new Comment(' - itemtext', 1); - $nodeKey = new Blank(' key: somevalue', 1); - // - $scalarResult = $getChildValue->invokeArgs($this->nodeLiterals, [$nodeScalar, 4]); - $this->assertEquals('sometext', $scalarResult); - // - $keyResult = $getChildValue->invokeArgs($this->nodeLiterals, [$nodeKey, 4]); - $this->assertEquals("", $keyResult); - // - $itemResult = $getChildValue->invokeArgs($this->nodeLiterals, [$nodeItem, 4]); - // $this->assertEquals("- itemtext\n", $itemResult); - - $quotedResult = $getChildValue->invokeArgs($this->nodeLiterals, [$nodeQuoted, 4]); - $this->assertEquals("sometext", $quotedResult); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\Literals::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $uselessNode = new Blank('', 1); - $this->assertTrue($this->nodeLiterals->isAwaitingChild($uselessNode)); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/NodeGenericTest.php b/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/NodeGenericTest.php deleted file mode 100644 index 0dc7060..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/nodes/abstract/NodeGenericTest.php +++ /dev/null @@ -1,244 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric - */ -class NodeGenericTest extends TestCase -{ - /** - * @var NodeGeneric $node An instance of "NodeGeneric" to test. - */ - private $node; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe check arguments of this constructor. */ - $this->node = $this->getMockBuilder(NodeGeneric::class) - ->setConstructorArgs(["a string to test", 1]) - ->getMockForAbstractClass(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::__construct - */ - public function testConstruct(): void - { - $rawValue = ' somestring'; - $lineNumber = 45; - $this->node->__construct($rawValue, $lineNumber); - $this->assertEquals($rawValue, $this->node->raw); - $this->assertEquals($lineNumber, $this->node->line); - $this->assertEquals(4, $this->node->indent); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::setParent - */ - public function testSetParent(): void - { - $nodeRoot = new Root(); - $reflector = new \ReflectionClass($this->node); - $method = $reflector->getMethod('setParent'); - $property = $reflector->getProperty('_parent'); - $method->setAccessible(true); - $property->setAccessible(true); - - $result = $method->invoke($this->node, $nodeRoot); - $this->assertTrue($result instanceof NodeGeneric); - $this->assertTrue($property->getValue($this->node) instanceof Root); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getParent - */ - public function testGetParent(): void - { - //direct parent : $indent = null - $nodeRoot = new Root(); - $nodeRoot->add($this->node); - $this->assertTrue($this->node->getParent() instanceof Root, 'parent is not a NodeRoot'); - //undirect parent : $indent = 2 - $nodeRoot = new Root(); - $nodeKey = new Key(' sequence:', 1); - $nodeItem = new Item(' -', 2); - $nodeKeyInside = new Key(' keyinitem: value', 3); - $nodeKeyInside->add($this->node); - $nodeItem->add($nodeKeyInside); - $nodeKey->add($nodeItem); - $nodeRoot->add($nodeKey); - $this->assertEquals($nodeKey, $this->node->getParent(4)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getParent - */ - public function testGetParentException(): void - { - $this->expectException(\Exception::class); - $this->node->getParent(); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getRoot - */ - public function testGetRoot(): void - { - $nodeRoot = new Root(); - $nodeKey = new Key(' sequence:', 1); - $nodeItem = new Item(' -', 2); - $nodeKeyInside = new Key(' keyinitem: value', 3); - $nodeKeyInside->add($this->node); - $nodeItem->add($nodeKeyInside); - $nodeKey->add($nodeItem); - $nodeRoot->add($nodeKey); - $getRoot = new \ReflectionMethod($this->node, 'getRoot'); - $getRoot->setAccessible(true); - $this->assertEquals($nodeRoot, $getRoot->invoke($this->node)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getRoot - */ - public function testGetRootException(): void - { - $this->expectException(\Exception::class); - $method = new \ReflectionMethod($this->node, 'getRoot'); - $method->setAccessible(true); - $method->invoke($this->node, null); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::add - */ - public function testAdd(): void - { - // value is empty - $this->assertEquals(null, $this->node->value); - // add one Node - $blankNode = new Blank('', 1); - $addResult = $this->node->add($blankNode); - $this->assertEquals($blankNode, $addResult); - $this->assertEquals($blankNode, $this->node->value); - //value is already a NodeGeneric : add one - $addResult2 = $this->node->add($blankNode); - $this->assertEquals($blankNode, $addResult2); - // should change to NodeList - $this->assertTrue($this->node->value instanceof NodeList); - //and theres 2 children - $this->assertEquals(2, $this->node->value->count()); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getDeepestNode - */ - public function testGetDeepestNode(): void - { - $child = NodeFactory::get(' key: &anchor |', 1); - $this->node->add($child);//var_dump($child->getDeepestNode()); - $this->assertTrue($child->getDeepestNode() instanceof Literal); - $this->assertTrue($this->node->getDeepestNode() instanceof Literal); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::specialProcess - * @todo : test call for ALL NODETYPES using folder "types" listing and object creation - */ - public function testSpecialProcess(): void - { - $previous = new Blank('', 1); - $blankBuffer = []; - $this->assertFalse($this->node->specialProcess($previous, $blankBuffer)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getTargetOnEqualIndent - */ - public function testGetTargetOnEqualIndent(): void - { - $blankNode = new Blank('', 1); - $nodeRoot = new Root(); - $nodeRoot->add($this->node); - $this->assertEquals($nodeRoot, $this->node->getTargetOnEqualIndent($blankNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getTargetOnLessIndent - * - * @todo test with more content before this one - */ - public function testGetTargetOnLessIndent(): void - { - $nodeRoot = new Root(); - $keyNode = new Key('sequence:', 1); - $itemNode1 = new Item(' - item1', 2); - $itemNode2 = new Item(' - item2', 3); - $nodeRoot->add($keyNode); - $keyNode->add($itemNode1); - $this->assertEquals($keyNode, $itemNode1->getTargetOnLessIndent($itemNode2)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::getTargetOnMoreIndent - */ - public function testGetTargetOnMoreIndent(): void - { - $previousNode = new Key('emptykey:',1); - $nextNode = new Item(' - itemvalue',2); - $this->assertEquals($previousNode, $previousNode->getTargetOnMoreIndent($nextNode)); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::isAwaitingChild - */ - public function testIsAwaitingChild(): void - { - $isAwaitingChild = new \ReflectionMethod($this->node, 'isAwaitingChild'); - $isAwaitingChild->setAccessible(true); - $this->assertFalse($isAwaitingChild->invoke($this->node, new Blank('', 1))); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::isOneOf - */ - public function testIsOneOf(): void - { - $rootNode = new Root; - $this->assertTrue($rootNode->isOneOf('Root')); - $this->assertFalse($rootNode->isOneOf('Key')); - $this->assertFalse($rootNode->isOneOf('Blank')); - } - - /** - * @covers \Dallgoot\Yaml\Nodes\NodeGeneric::__debugInfo - */ - public function testDebugInfo(): void - { - $this->assertTrue(is_array($this->node->__debugInfo())); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/tag/TagFactoryTest.php b/classes/vendor/dallgoot/yaml/tests/units/tag/TagFactoryTest.php deleted file mode 100644 index 58a88a9..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/tag/TagFactoryTest.php +++ /dev/null @@ -1,80 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\TagFactory - */ -class TagFactoryTest extends TestCase -{ - /** - * @var TagFactory $tagFactory An instance of "TagFactory" to test. - */ - private $tagFactory; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->tagFactory = new TagFactory(); - } - - public function testCreateCoreSchema() - { - $this->tagFactory::$schemas = []; - $this->tagFactory::$schemaHandles = []; - $createCoreSchema = new \ReflectionMethod($this->tagFactory, 'createCoreSchema'); - $createCoreSchema->setAccessible(true); - $createCoreSchema->invoke(null); - $this->assertArrayHasKey('!!', $this->tagFactory::$schemaHandles); - $this->assertArrayHasKey(CoreSchema::SCHEMA_URI, $this->tagFactory::$schemas); - $this->assertTrue($this->tagFactory::$schemas[CoreSchema::SCHEMA_URI] instanceof CoreSchema); - } - - public function testRegisterSchema() - { - $coreSchema = new CoreSchema; - $this->tagFactory::registerSchema($coreSchema::SCHEMA_URI, $coreSchema); - $this->assertArrayHasKey(CoreSchema::SCHEMA_URI, $this->tagFactory::$schemas); - } - - public function testRegisterHandle() - { - $coreSchema = new CoreSchema; - $this->tagFactory::registerHandle("!dummy!", $coreSchema::SCHEMA_URI); - $this->assertArrayHasKey('!dummy!', $this->tagFactory::$schemaHandles); - } - - public function testTransform() - { - $scalarNode = new Scalar('somestring', 1); - $transformed = $this->tagFactory::transform('!!str', $scalarNode); - $this->assertEquals('somestring', $transformed); - } - - public function testRunHandler() - { - $scalarNode = new Scalar('somestring', 1); - $tagged = $this->tagFactory::runHandler('!!', 'str', $scalarNode); - $this->assertEquals('somestring', $tagged); - } - -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/types/CompactTest.php b/classes/vendor/dallgoot/yaml/tests/units/types/CompactTest.php deleted file mode 100644 index 53d326f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/types/CompactTest.php +++ /dev/null @@ -1,52 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Compact - */ -class CompactTest extends TestCase -{ - /** - * @var Compact $compact An instance of "Compact" to test. - */ - private $compact; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->compact = new Compact([]); - } - - /** - * @covers \Dallgoot\Yaml\Compact::__construct - */ - public function testConstruct(): void - { - $this->compact[12] = 'abc'; - $this->assertEquals('abc', $this->compact[12]); - $this->compact->prop = '123'; - $this->assertEquals('123', $this->compact->prop); - } - - /** - * @covers \Dallgoot\Yaml\Compact::jsonSerialize - */ - public function testJsonSerialize(): void - { - $this->assertTrue(is_array($this->compact->jsonSerialize())); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/types/TaggedTest.php b/classes/vendor/dallgoot/yaml/tests/units/types/TaggedTest.php deleted file mode 100644 index 8de54e1..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/types/TaggedTest.php +++ /dev/null @@ -1,51 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\Tagged - */ -class TaggedTest extends TestCase -{ - /** - * @var Tagged $tag An instance of "Tagged" to test. - */ - private $tag; - - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - $this->tag = new Tagged("tagName", "a string to test"); - } - - /** - * @covers \Dallgoot\Yaml\Tagged::__construct - */ - public function testConstruct(): void - { - $this->assertEquals("tagName",$this->tag->tagName); - $this->assertEquals("a string to test",$this->tag->value); - } - - /** - * @covers \Dallgoot\Yaml\Tagged::__construct - */ - public function testConstructEmptyName(): void - { - $this->expectException(\Exception::class); - $this->tag = new Tagged("", "a string to test"); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/units/types/YamlObjectTest.php b/classes/vendor/dallgoot/yaml/tests/units/types/YamlObjectTest.php deleted file mode 100644 index e10d98f..0000000 --- a/classes/vendor/dallgoot/yaml/tests/units/types/YamlObjectTest.php +++ /dev/null @@ -1,180 +0,0 @@ -. - * @license https://opensource.org/licenses/MIT The MIT license. - * @link https://github.com/dallgoot/yaml - * @since File available since Release 1.0.0 - * - * @covers \Dallgoot\Yaml\YamlObject - */ -class YamlObjectTest extends TestCase -{ - /** - * @var YamlObject $yamlObject An instance of "YamlObject" to test. - */ - private $yamlObject; - - private $refValue = 123; - private $commentValue = '# this a full line comment'; - /** - * {@inheritdoc} - */ - protected function setUp(): void - { - /** @todo Maybe add some arguments to this constructor */ - $this->yamlObject = new YamlObject(0); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::__construct - */ - public function testConstruct(): void - { - $reflector = new \ReflectionClass($this->yamlObject); - $__yaml__object__api = $reflector->getProperty('__yaml__object__api'); - $__yaml__object__api->setAccessible(true); - $this->yamlObject->__construct(0); - $this->assertTrue($__yaml__object__api->getValue($this->yamlObject) instanceof YamlProperties); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::__toString - */ - public function testToString(): void - { - $this->yamlObject->setText('some text value'); - $this->assertTrue(is_string(''.$this->yamlObject)); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::jsonSerialize - */ - public function testJsonSerialize(): void - { - $this->assertEquals("_Empty YamlObject_", $this->yamlObject->jsonSerialize()); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::addReference - */ - public function testAddReference(): void - { - $this->assertEquals($this->yamlObject->getAllReferences(), []); - $this->yamlObject->addReference('referenceName', $this->refValue); - $this->assertEquals($this->yamlObject->getReference('referenceName'), $this->refValue); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::getReference - */ - public function testGetReference(): void - { - $this->assertEquals($this->yamlObject->getAllReferences(), []); - $this->yamlObject->addReference('referenceName', $this->refValue); - $this->assertEquals($this->yamlObject->getReference('referenceName'), $this->refValue); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::getAllReferences - */ - public function testGetAllReferences(): void - { - $this->assertEquals($this->yamlObject->getAllReferences(), []); - $this->yamlObject->addReference('referenceName', $this->refValue); - $this->assertEquals($this->yamlObject->getAllReferences(), ['referenceName' => $this->refValue]); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::addComment - */ - public function testAddComment(): void - { - $this->assertEquals($this->yamlObject->getComment(), []); - $this->yamlObject->addComment(20, $this->commentValue); - $this->assertEquals($this->yamlObject->getComment(20), $this->commentValue); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::getComment - * @depends testAddComment - */ - public function testGetComment(): void - { - $this->assertEquals($this->yamlObject->getComment(), []); - $this->yamlObject->addComment(20, $this->commentValue); - $this->assertEquals($this->yamlObject->getComment(20), $this->commentValue); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::setText - */ - public function testSetText(): void - { - $container = new ReflectionProperty($this->yamlObject, '__yaml__object__api'); - $container->setAccessible(true); - $this->assertTrue(is_null($container->getValue($this->yamlObject)->value)); - $txt = ' a text with leading spaces'; - $yamlObject = $this->yamlObject->setText($txt); - $this->assertTrue($container->getValue($this->yamlObject)->value === ltrim($txt)); - $this->assertTrue($yamlObject instanceof YamlObject); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::addTag - */ - public function testAddTag(): void - { - $this->assertFalse($this->yamlObject->isTagged()); - $this->yamlObject->addTag('!', 'tag:clarkevans.com,2002'); - $this->assertTrue($this->yamlObject->isTagged()); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::hasDocStart - */ - public function testHasDocStart(): void - { - $this->assertFalse($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(false); - $this->assertTrue($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(true); - $this->assertTrue($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(null); - $this->assertFalse($this->yamlObject->hasDocStart()); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::setDocStart - */ - public function testSetDocStart(): void - { - $this->assertFalse($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(false); - $this->assertTrue($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(true); - $this->assertTrue($this->yamlObject->hasDocStart()); - $this->yamlObject->setDocStart(null); - $this->assertFalse($this->yamlObject->hasDocStart()); - } - - /** - * @covers \Dallgoot\Yaml\YamlObject::isTagged - */ - public function testIsTagged(): void - { - $this->assertFalse($this->yamlObject->isTagged()); - $this->yamlObject->addTag('!', 'tag:clarkevans.com,2002'); - $this->assertTrue($this->yamlObject->isTagged()); - } -} diff --git a/classes/vendor/dallgoot/yaml/tests/xdebug-filter.php b/classes/vendor/dallgoot/yaml/tests/xdebug-filter.php deleted file mode 100644 index b84e974..0000000 --- a/classes/vendor/dallgoot/yaml/tests/xdebug-filter.php +++ /dev/null @@ -1,12 +0,0 @@ -. + */ +/** + * For more information, please contact + */ + +namespace Goat1000\SVGGraph; + +/** + * Class for algebraic functions + */ +class Algebraic { + + private $type = 'straight'; + private $coeffs = [0, 1]; + + public function __construct($type) + { + $this->type = $type; + } + + /** + * Sets the coefficients in order, lowest power first + */ + public function setCoefficients(array $coefficients) + { + $this->coeffs = $coefficients; + } + + /** + * Returns the y value for a + bx + cx^2 ... + */ + public function __invoke($x) + { + $val = 0; + foreach($this->coeffs as $p => $c) { + switch($p) { + case 0: $val = bcadd($val, $c); + break; + case 1: $val = bcadd($val, bcmul($c, $x)); + break; + default: + $val = bcadd($val, bcmul($c, bcpow($x, $p))); + break; + } + } + return $val; + } + + /** + * Creates a row of the vandermonde matrix + */ + public function vandermonde($x) + { + $t = $this->type; + return $this->{$t}($x); + } + + private function straight($x) + { + return [$x]; + } + + private function quadratic($x) + { + return [$x, bcmul($x, $x)]; + } + + private function cubic($x) + { + $res = [$x, bcmul($x, $x)]; + $res[] = bcmul($res[1], $x); + return $res; + } + + private function quartic($x) + { + $res = $this->cubic($x); + $res[] = bcmul($res[1], $res[1]); + return $res; + } + + private function quintic($x) + { + $res = $this->cubic($x); + $res[] = bcmul($res[1], $res[1]); + $res[] = bcmul($res[1], $res[2]); + return $res; + } +} + diff --git a/classes/vendor/goat1000/svggraph/Average.php b/classes/vendor/goat1000/svggraph/Average.php index cf43d0e..24a13ee 100644 --- a/classes/vendor/goat1000/svggraph/Average.php +++ b/classes/vendor/goat1000/svggraph/Average.php @@ -1,6 +1,6 @@ getTitle($graph, $avg, $d); - if(strlen($title) > 0) + if($title !== null && strlen($title) > 0) $line[] = $title; $cg = new ColourGroup($graph, null, 0, $d, 'average_colour'); @@ -54,13 +54,12 @@ public function __construct(&$graph, &$values, $datasets) $line['text_colour'] = $cg->stroke(); } - $sw = new Number($graph->getOption(['average_stroke_width', $d], 1)); - $line['stroke_width'] = $sw; + $line['stroke_width'] = new Number($graph->getOption(['average_stroke_width', $d], 1)); + $line['font_size'] = Number::units($graph->getOption(['average_font_size', $d])); $opts = ["opacity", "above", "dash", "title_align", "title_angle", "title_opacity", "title_padding", "title_position", - "font", "font_size", "font_adjust", "font_weight", - "length", "length_units"]; + "font", "font_adjust", "font_weight", "length", "length_units"]; foreach($opts as $opt) { $g_opt = str_replace('title', 'text', $opt); $line[$g_opt] = $graph->getOption(['average_' . $opt, $d]); diff --git a/classes/vendor/goat1000/svggraph/BestFit.php b/classes/vendor/goat1000/svggraph/BestFit.php index c572028..c9b762a 100644 --- a/classes/vendor/goat1000/svggraph/BestFit.php +++ b/classes/vendor/goat1000/svggraph/BestFit.php @@ -1,6 +1,6 @@ graph->getOption(['best_fit', $dataset]); - if($type !== 'straight') + if($type !== 'straight' && $type !== 'curve') return; // range and projection @@ -63,7 +63,10 @@ public function add($dataset, $points) $points = $this->filterPoints($points, $r_start, $r_end); } - $best_fit = new BestFitLine($this->graph, $points); + $class = '\\Goat1000\\SVGGraph\\' . ($type === 'straight' ? 'BestFitLine' : 'BestFitCurve'); + $subtypes = $this->graph->getOption(['best_fit_type', $dataset]); + + $best_fit = new $class($this->graph, $points, $subtypes); $best_fit->calculate($this->bbox, $r_start, $r_end, $p_start, $p_end); if($this->graph->getOption(['best_fit_above', $dataset])) $this->lines_above[$dataset] = $best_fit; @@ -162,6 +165,7 @@ protected function getLinePath($dataset, $line_path, $proj_path) $dash = $this->graph->getOption(['best_fit_dash', $dataset]); $opacity = $this->graph->getOption(['best_fit_opacity', $dataset]); $above = $this->graph->getOption(['best_fit_above', $dataset]); + $type = $this->graph->getOption(['best_fit', $dataset]); $path = [ 'd' => $line_path, 'stroke' => $colour->isNone() ? '#000' : $colour, @@ -172,6 +176,8 @@ protected function getLinePath($dataset, $line_path, $proj_path) $path['stroke-dasharray'] = $dash; if($opacity != 1) $path['opacity'] = $opacity; + if($type != 'straight') + $path['fill'] = 'none'; // don't fill curves $line = $this->graph->element('path', $path); if($proj_path->isEmpty()) diff --git a/classes/vendor/goat1000/svggraph/BestFitCurve.php b/classes/vendor/goat1000/svggraph/BestFitCurve.php new file mode 100644 index 0000000..8e4005a --- /dev/null +++ b/classes/vendor/goat1000/svggraph/BestFitCurve.php @@ -0,0 +1,245 @@ +. + */ +/** + * For more information, please contact + */ + +namespace Goat1000\SVGGraph; + +/** + * Class for calculating a curved best-fit line + */ +class BestFitCurve { + + protected $graph; + protected $points; + protected $line; + protected $projection; + protected $types; + + public function __construct(&$graph, $points, $types = null) + { + $this->graph =& $graph; + $this->line = new PathData; + $this->projection = new PathData; + $this->points = $points; + $this->types = $types === null || is_array($types) ? $types : [$types]; + } + + /** + * Calculates the line and projection + */ + public function calculate(BoundingBox $area, $limit_start, $limit_end, + $project_start, $project_end) + { + // can't draw a line through fewer than 2 points + $count = count($this->points); + if($count < 2) + return false; + + $old_scale = bcscale(50); + $b = []; + $y = new Matrix($count, 1); + foreach($this->points as $p) + $b[] = $p->y; + $y->load($b); + + $supported_types = ['straight', 'quadratic', 'cubic', 'quartic', 'quintic']; + + // choose which functions to fit + if($this->types !== null) { + $types = []; + foreach($this->types as $type) { + if(!in_array($type, $supported_types)) + throw new \Exception("Unknown curve type '{$type}'"); + $types[] = $type; + } + } else { + $types = ['quintic']; + switch($count) + { + case 2 : $types = ['straight']; + break; + case 3 : $types = ['quadratic']; + break; + case 4 : $types = ['cubic']; + break; + case 5 : $types = ['quartic']; + } + } + + // fit the functions, measure the error + $results = []; + $errors = []; + foreach($types as $t) { + $v = $this->vandermonde($t); + $result = $this->solve($v, $y); + if($result !== null) { + $errors[$t] = $this->error($v, $result); + $results[$t] = $result; + } + } + + if(!empty($errors)) { + + // sort by error, best first + uasort($errors, 'bccomp'); + $best = null; + foreach($errors as $k => $v) { + $best = $k; + break; + } + + $r = $results[$best]; + $c = $r->asArray(); + + // plot the function + $fn = new Algebraic($best); + $fn->setCoefficients($c); + $this->buildPaths($fn, $area, $limit_start, $limit_end, + $project_start, $project_end); + } + bcscale($old_scale); + } + + /** + * Calculates the error + */ + protected function error(Matrix $v, Matrix $r) + { + $old_scale = bcscale(50); + $tr = $r->transpose(); + $vr = $v->multiply($tr); + $i = 0; + $err = "0"; + foreach($this->points as $p) { + $diff = bcsub($vr($i, 0), $p->y); + if(bccomp($diff, "0") == -1) + $err = bcsub($err, $diff); + else + $err = bcadd($err, $diff); + ++$i; + } + bcscale($old_scale); + return $err; + } + + /** + * Solves the normal equation + */ + protected function solve(Matrix $v, Matrix $y) + { + $v_t = $v->transpose(); + $v_t_v = $v_t->multiply($v); + $v_t_y = $v_t->multiply($y); + return $v_t_v->gaussian_solve($v_t_y); + } + + /** + * Returns the Vandermonde matrix for the curve type + */ + protected function vandermonde($type) + { + $old_scale = bcscale(50); + + // find size of matrix + $a = new Algebraic($type); + $test = $a->vandermonde(1); + $m = count($this->points); + $n = count($test) + 1; + $v = new Matrix($m, $n); + + $i = 0; + foreach($this->points as $p) + { + $v($i, 0, 1); + $bcx = sprintf("%20.20F", $p->x); + $cols = $a->vandermonde($bcx); + foreach($cols as $k => $value) + $v($i, $k + 1, $value); + ++$i; + } + bcscale($old_scale); + return $v; + } + + /** + * Builds the line and projection paths. + * For vertical lines, $slope = null and $y_int = $x + */ + protected function buildPaths(&$fn, $area, $limit_start, $limit_end, + $project_start, $project_end) + { + + // initialize min and max points of line + $x_min = $limit_start === null ? 0 : max($limit_start, 0); + $x_max = $limit_end === null ? $area->width() : min($limit_end, $area->width()); + $y_min = 0; + $y_max = $area->height(); + $line = new PathData; + $projection = new PathData; + + $step = 1; + if($project_start) + $this->buildPath($projection, $fn, 0, $x_min, $y_min, $y_max, $step, $area); + $this->buildPath($line, $fn, $x_min, $x_max, $y_min, $y_max, $step, $area); + if($project_end) + $this->buildPath($projection, $fn, $x_max, $area->width(), $y_min, $y_max, $step, $area); + + $this->projection = $projection; + $this->line = $line; + return true; + } + + /** + * Builds a single path section between $x1 and $x2 + */ + private function buildPath(&$path, &$fn, $x1, $x2, $y_min, $y_max, $step, $area) + { + $cmd = 'M'; + for($x = $x1; $x <= $x2; $x += $step) { + $y = $fn($x); + if($y < $y_min || $y > $y_max) { + $cmd = 'M'; + continue; + } + $path->add($cmd, $area->x1 + $x, $area->y2 - $y); + switch($cmd) { + case 'M' : $cmd = 'L'; break; + case 'L' : $cmd = ''; break; + } + } + } + + /** + * Returns the best-fit line as PathData + */ + public function getLine() + { + return $this->line; + } + + /** + * Returns the projection line(s) as PathData + */ + public function getProjection() + { + return $this->projection; + } +} + diff --git a/classes/vendor/goat1000/svggraph/CHANGES.txt b/classes/vendor/goat1000/svggraph/CHANGES.txt index 397e460..3fc24c1 100644 --- a/classes/vendor/goat1000/svggraph/CHANGES.txt +++ b/classes/vendor/goat1000/svggraph/CHANGES.txt @@ -1,3 +1,8 @@ +Version 3.20 (24/04/2023) +------------ +- Added support for curved best-fit lines. +- Added support for CSS units in font sizes and line spacing. + Version 3.19 (10/01/2023) ------------ - Added ParetoChart. diff --git a/classes/vendor/goat1000/svggraph/ContextMenu.php b/classes/vendor/goat1000/svggraph/ContextMenu.php index 955492a..9d08d4c 100644 --- a/classes/vendor/goat1000/svggraph/ContextMenu.php +++ b/classes/vendor/goat1000/svggraph/ContextMenu.php @@ -1,6 +1,6 @@ js->addInitFunction('contextMenuInit'); $opts = ['link_target', 'link_underline', 'stroke_width', 'round', 'font', - 'font_size', 'font_weight', 'document_menu', 'spacing', 'min_width', + 'font_weight', 'document_menu', 'spacing', 'min_width', 'shadow_opacity', 'mouseleave']; $colours = ['colour', 'link_colour', 'link_hover_colour', 'back_colour']; $vars = []; foreach($opts as $opt) $vars[$opt] = $this->graph->getOption('context_' . $opt); + $vars['font_size'] = Number::units($this->graph->getOption('context_font_size')); foreach($colours as $opt) $vars[$opt] = new Colour($this->graph, $this->graph->getOption('context_' . $opt)); diff --git a/classes/vendor/goat1000/svggraph/CrossHairs.php b/classes/vendor/goat1000/svggraph/CrossHairs.php index 7f68c25..8caa637 100644 --- a/classes/vendor/goat1000/svggraph/CrossHairs.php +++ b/classes/vendor/goat1000/svggraph/CrossHairs.php @@ -121,6 +121,7 @@ public function getCrossHairs() foreach($text_options as $opt) $t_opt[$opt] = $this->graph->getOption('crosshairs_text_' . $opt); + // text group for grid details $text_group = ['id' => $this->graph->newId(), 'visibility' => 'hidden']; $text_rect = [ @@ -133,7 +134,7 @@ public function getCrossHairs() $text_rect['stroke-width'] = $t_opt['stroke_width']; $text_rect['stroke'] = $t_opt['colour']; } - $font_size = max(3, (int)$t_opt['font_size']); + $font_size = max(3, Number::units($t_opt['font_size'])); $text_element = [ 'x' => 0, 'y' => $font_size, 'font-family' => $t_opt['font'], diff --git a/classes/vendor/goat1000/svggraph/DataLabels.php b/classes/vendor/goat1000/svggraph/DataLabels.php index a778daa..a78bf60 100644 --- a/classes/vendor/goat1000/svggraph/DataLabels.php +++ b/classes/vendor/goat1000/svggraph/DataLabels.php @@ -1,6 +1,6 @@ getOption( ['axis_text_colour_' . $o, $axis_no], 'axis_text_colour', ['@', $styles['colour']])); - $styles['t_line_spacing'] = $get_axis_option('axis_text_line_spacing'); + $styles['t_line_spacing'] = Number::units($get_axis_option('axis_text_line_spacing')); if($styles['t_line_spacing'] === null || $styles['t_line_spacing'] < 1) $styles['t_line_spacing'] = $styles['t_font_size']; $styles['t_back_colour'] = null; @@ -202,9 +202,9 @@ public function __construct(&$graph, &$axis, $axis_no, $orientation, $type, $styles['l_font'] = $graph->getOption( ['label_font_' . $o, $axis_no], 'label_font', ['axis_font_' . $o, $axis_no], 'axis_font'); - $styles['l_font_size'] = $graph->getOption( + $styles['l_font_size'] = Number::units($graph->getOption( ['label_font_size_' . $o, $axis_no], 'label_font_size', - ['axis_font_size_' . $o, $axis_no], 'axis_font_size'); + ['axis_font_size_' . $o, $axis_no], 'axis_font_size')); $styles['l_font_weight'] = $graph->getOption( ['label_font_weight_' . $o, $axis_no], 'label_font_weight'); $styles['l_colour'] = new Colour($graph, $graph->getOption( @@ -213,7 +213,7 @@ public function __construct(&$graph, &$axis, $axis_no, $orientation, $type, ['@', $styles['colour']])); $styles['l_space'] = $graph->getOption('label_space'); $styles['l_pos'] = $get_axis_option('axis_label_position'); - $styles['l_line_spacing'] = $get_axis_option('label_line_spacing'); + $styles['l_line_spacing'] = Number::units($get_axis_option('label_line_spacing')); if($styles['l_line_spacing'] === null || $styles['l_line_spacing'] < 1) $styles['l_line_spacing'] = $styles['l_font_size']; } diff --git a/classes/vendor/goat1000/svggraph/Graph.php b/classes/vendor/goat1000/svggraph/Graph.php index 89f8bee..fb9b530 100644 --- a/classes/vendor/goat1000/svggraph/Graph.php +++ b/classes/vendor/goat1000/svggraph/Graph.php @@ -557,12 +557,12 @@ protected function getTitle() if($svg_text->strlen($info['title']) <= 0) return $info; - $info['font_size'] = $this->getOption('graph_title_font_size'); + $info['font_size'] = Number::units($this->getOption('graph_title_font_size')); $info['weight'] = $this->getOption('graph_title_font_weight'); $info['colour'] = $this->getOption('graph_title_colour'); $info['pos'] = $this->getOption('graph_title_position'); $info['space'] = $this->getOption('graph_title_space'); - $info['line_spacing'] = $this->getOption('graph_title_line_spacing'); + $info['line_spacing'] = Number::units($this->getOption('graph_title_line_spacing')); if($info['line_spacing'] === null || $info['line_spacing'] < 1) $info['line_spacing'] = $info['font_size']; @@ -579,15 +579,15 @@ protected function getTitle() $svg_subtext = new Text($this, $info['sfont']); if($svg_subtext->strlen($info['stitle']) > 0) { - $info['sfont_size'] = $this->getOption('graph_subtitle_font_size', - 'graph_title_font_size'); + $info['sfont_size'] = Number::units($this->getOption('graph_subtitle_font_size', + 'graph_title_font_size')); $info['sweight'] = $this->getOption('graph_subtitle_font_weight', 'graph_title_font_weight'); $info['scolour'] = $this->getOption('graph_subtitle_colour', 'graph_title_colour'); $info['sspace'] = $this->getOption('graph_subtitle_space', 'graph_title_space'); - $info['sline_spacing'] = $this->getOption('graph_subtitle_line_spacing'); + $info['sline_spacing'] = Number::units($this->getOption('graph_subtitle_line_spacing')); if($info['sline_spacing'] === null || $info['sline_spacing'] < 1) $info['sline_spacing'] = $info['sfont_size']; diff --git a/classes/vendor/goat1000/svggraph/Guidelines.php b/classes/vendor/goat1000/svggraph/Guidelines.php index 86330ec..c580b83 100644 --- a/classes/vendor/goat1000/svggraph/Guidelines.php +++ b/classes/vendor/goat1000/svggraph/Guidelines.php @@ -1,6 +1,6 @@ guidelines = []; // set up options - $opts = ['above', 'dash', 'font', 'font_adjust', 'font_size', - 'font_weight', 'length', 'length_units', 'opacity', 'stroke_width', - 'text_align', 'text_angle', 'text_padding', 'text_position', 'line_spacing']; + $opts = ['above', 'dash', 'font', 'font_adjust', 'font_weight', + 'length', 'length_units', 'opacity', 'stroke_width', + 'text_align', 'text_angle', 'text_padding', 'text_position' ]; foreach($opts as $opt) $this->{$opt} = $graph->getOption('guideline_' . $opt); @@ -80,6 +80,8 @@ public function __construct(&$graph, $flip_axes, $assoc, $datetime) $graph->getOption('guideline_text_colour', 'guideline_colour')); $this->text_opacity = $graph->getOption('guideline_text_opacity', 'guideline_opacity'); + $this->font_size = Number::units($graph->getOption('guideline_font_size')); + $this->line_spacing = Number::units($graph->getOption('guideline_line_spacing')); $lines = $this->normalize($lines); foreach($lines as $line) @@ -154,7 +156,6 @@ protected function calculate($g) $text_opts = [ 'opacity' => 'opacity', 'font' => 'font-family', - 'font_size' => 'font-size', 'font_weight' => 'font-weight', 'text_opacity' => 'opacity', // overrides line opacity @@ -164,7 +165,6 @@ protected function calculate($g) 'text_padding' => 'text_padding', 'text_angle' => 'text_angle', 'text_align' => 'text_align', - 'line_spacing' => 'line_spacing', ]; // handle colours first @@ -177,6 +177,12 @@ protected function calculate($g) $topts['fill'] = new Colour($this->graph, $g['text_colour']); } + // font size and line spacing + if(isset($g['font_size'])) + $topts['font-size'] = Number::units($g['font_size']); + if(isset($g['line_spacing'])) + $topts['line_spacing'] = Number::units($g['line_spacing']); + // copy other options to line or text array foreach($line_opts as $okey => $opt) if(isset($g[$okey])) diff --git a/classes/vendor/goat1000/svggraph/Javascript.php b/classes/vendor/goat1000/svggraph/Javascript.php index 6af2a01..9b80ad8 100644 --- a/classes/vendor/goat1000/svggraph/Javascript.php +++ b/classes/vendor/goat1000/svggraph/Javascript.php @@ -1,6 +1,6 @@ addFuncs('getE', 'setattr', 'newel', 'newtext'); - $opts = ['padding', 'colour', 'font', 'font_size', 'font_weight', - 'line_spacing', 'align']; + $opts = ['padding', 'colour', 'font', 'font_weight', 'align']; $vars = []; foreach($opts as $opt) $vars[$opt] = $this->graph->getOption('tooltip_' . $opt); + $vars['font_size'] = Number::units($this->graph->getOption('tooltip_font_size')); + $vars['line_spacing'] = Number::units($this->graph->getOption('tooltip_line_spacing')); $vars['colour'] = new Colour($this->graph, $vars['colour'], false, false); $vars['ttoffset'] = $vars['font_size'] + $vars['padding']; if($vars['line_spacing'] === null || $vars['line_spacing'] < 1) diff --git a/classes/vendor/goat1000/svggraph/Legend.php b/classes/vendor/goat1000/svggraph/Legend.php index 91dea32..b5799df 100644 --- a/classes/vendor/goat1000/svggraph/Legend.php +++ b/classes/vendor/goat1000/svggraph/Legend.php @@ -67,7 +67,7 @@ public function __construct(&$graph) // copy options to class $opts = ['autohide', 'autohide_opacity', 'back_colour', 'colour', 'columns', 'draggable', 'entries', 'entry_height', 'entry_width', 'font', - 'font_adjust', 'font_size', 'font_weight', 'position', 'round', + 'font_adjust', 'font_weight', 'position', 'round', 'shadow_opacity', 'show_empty', 'stroke_colour', 'stroke_width', 'text_side', 'title', 'title_link', 'title_font_weight', 'type', 'unique_fields']; @@ -76,17 +76,18 @@ public function __construct(&$graph) } // slightly more complicated options + $this->font_size = Number::units($graph->getOption('legend_font_size')); $this->title_colour = $graph->getOption('legend_title_colour', 'legend_colour'); $this->title_font = $graph->getOption('legend_title_font', 'legend_font'); $this->title_font_adjust = $graph->getOption('legend_title_font_adjust', 'legend_font_adjust'); - $this->title_font_size = $graph->getOption('legend_title_font_size', - 'legend_font_size'); - $this->line_spacing = $graph->getOption('legend_line_spacing'); + $this->title_font_size = Number::units($graph->getOption('legend_title_font_size', + 'legend_font_size')); + $this->line_spacing = Number::units($graph->getOption('legend_line_spacing')); if($this->line_spacing === null || $this->line_spacing < 1) $this->line_spacing = $this->font_size; - $this->title_line_spacing = $graph->getOption('legend_title_line_spacing'); + $this->title_line_spacing = Number::units($graph->getOption('legend_title_line_spacing')); if($this->title_line_spacing === null || $this->title_line_spacing < 1) $this->title_line_spacing = $this->title_font_size; } diff --git a/classes/vendor/goat1000/svggraph/Matrix.php b/classes/vendor/goat1000/svggraph/Matrix.php new file mode 100644 index 0000000..a00b1e3 --- /dev/null +++ b/classes/vendor/goat1000/svggraph/Matrix.php @@ -0,0 +1,346 @@ +. + */ +/** + * For more information, please contact + */ + +namespace Goat1000\SVGGraph; + +/** + * Class for matrix maths + */ +class Matrix { + private $rows = 0; + private $cols = 0; + private $data = []; + const MAX_SIZE = 100000; + + public function __construct($r, $c) + { + if(!is_int($c) || !is_int($r) || $c < 1 || $r < 1) + throw new \InvalidArgumentException("{$r}\u{00d7}{$c} matrix size invalid"); + if($c * $r > Matrix::MAX_SIZE) + throw new \InvalidArgumentException("{$r}\u{00d7}{$c} matrix too large"); + + $this->rows = $r; + $this->cols = $c; + $this->data = array_fill(0, $c * $r, 0); + } + + /** + * Returns the number of rows and cols in an array + */ + public function dimensions() + { + return [$this->rows, $this->cols]; + } + + /** + * Returns the size as a string + */ + public function size() + { + return $this->rows . "\u{00d7}" . $this->cols; + } + + /** + * Element access + */ + public function &__invoke($r, $c, $v = null) + { + if($c < 0 || $r < 0 || $c >= $this->cols || $r >= $this->rows) + throw new \InvalidArgumentException("({$r},{$c}) out of range of " . + $this->size() . " matrix"); + + $item = $this->cols * $r + $c; + if($v !== null) { + if(!is_numeric($v)) + throw new \InvalidArgumentException("Matrix values must be numeric"); + if(is_string($v)) + $this->data[$item] = $v; + elseif(is_int($v)) + $this->data[$item] = (string)$v; + else + $this->data[$item] = sprintf("%.40F", $v); + } + return $this->data[$item]; + } + + /** + * Fill the array with values (row-major order) + */ + public function load(array $values) + { + for($i = 0; $i < $this->rows * $this->cols; ++$i) { + $value = $values[$i]; + if(isset($value) && is_numeric($value)) { + $this->data[$i] = is_int($value) ? (string)$value : + sprintf("%.40F", $value); + } + } + } + + /** + * Sets the identity matrix + */ + public function identity() + { + if($this->rows != $this->cols) + throw new \Exception($this->size() . " not a square matrix"); + $this->data = array_fill(0, $this->rows * $this->cols, 0); + for($i = 0; $i < $this->rows; ++$i) + $this->data[($i * $this->rows) + $i] = 1; + } + + /** + * Return the transpose of the matrix + */ + public function transpose() + { + $tc = $this->rows; + $tr = $this->cols; + $result = new Matrix($tr, $tc); + + // row or column vector = same data when transposed + if($tc == 1 || $tr == 1) { + $result->data = $this->data; + return $result; + } + + for($c = 0; $c < $tc; ++$c) { + for($r = 0; $r < $tr; ++$r) { + $result($r, $c, $this($c, $r)); + } + } + return $result; + } + + /** + * Add two matrices + */ + public function add(Matrix $m, $bcscale = 50) + { + if($m->rows != $this->rows || $m->cols != $this->cols) + throw new \InvalidArgumentException("Cannot add " . $this->size() . + " and " . $m->size() . " matrices."); + + $old_scale = bcscale($bcscale); + $result = new Matrix($this->cols, $this->rows); + foreach($this->data as $k => $value) + $result->data[$k] = bcadd($value, $m->data[$k]); + + bcscale($old_scale); + return $result; + } + + /** + * Subtract a matrix + */ + public function subtract(Matrix $m, $bcscale = 50) + { + if($m->rows != $this->rows || $m->cols != $this->cols) + throw new \InvalidArgumentException("Cannot subtract " . $m->size() . + " matrix from " . $this->size() . " matrix."); + + $old_scale = bcscale($bcscale); + $result = new Matrix($this->cols, $this->rows); + foreach($this->data as $k => $value) + $result->data[$k] = bcsub($value, $m->data[$k]); + + bcscale($old_scale); + return $result; + } + + /** + * Multiplication by a matrix + */ + public function multiply(Matrix $m1, $bcscale = 50) + { + if($this->cols != $m1->rows) + throw new \InvalidArgumentException("Cannot multiply " . $this->size() . + " matrix by " . $m1->size() . " matrix."); + $m = $this->rows; + $n = $this->cols; + $p = $m1->cols; + + $old_scale = bcscale($bcscale); + $result = new Matrix($m, $p); + for($i = 0; $i < $m; ++$i) { + for($j = 0; $j < $p; ++$j) { + $value = "0"; + for($k = 0; $k < $n; ++$k) { + $value = bcadd($value, bcmul($this($i, $k), $m1($k, $j))); + } + $result($i, $j, $value); + } + } + + bcscale($old_scale); + return $result; + } + + /** + * Gaussian elimination + */ + public function gaussian($bcscale = 50) + { + $old_scale = bcscale($bcscale); + + $argmax = function($a, $b, $m, $col) { + $max = 0; + $max_i = 0; + for($i = $a; $i < $b; ++$i) { + $value = $m($a, $col); + if(bccomp($value, "0") == -1) + $value = bcmul($value, "-1"); + if(bccomp($value, $max) == 1) { + $max_i = $i; + $max = $value; + } + return $max_i; + } + }; + + $m = $this->rows; + $n = $this->cols; + $h = $k = 0; + while($h < $m && $k < $n) { + $i_max = $argmax($h, $m, $this, $k); + if($this($i_max, $k) == 0) { + ++$k; + } else { + $this->rowSwap($h, $i_max); + for($i = $h + 1; $i < $m; ++$i) { + $f = bcdiv($this($i, $k), $this($h, $k)); + $this($i, $k, 0); + for($j = $k + 1; $j < $n; ++$j) { + $val = bcsub($this($i, $j), bcmul($this($h, $j), $f)); + $this($i, $j, $val); + } + } + ++$h; + ++$k; + } + } + + bcscale($old_scale); + } + + /** + * Use Gaussian elimination to solve the equations with given RHS + */ + public function gaussian_solve(Matrix $rhs, $bcscale = 50) + { + $a = $this->augment($rhs); + $a->gaussian($bcscale); + return $this->solve($a, $bcscale); + } + + /** + * Creates a new matrix with $this on left and $rhs on right + */ + public function augment(Matrix $rhs) + { + $m = $this->rows; + $n = $this->cols + $rhs->cols; + $aug = new Matrix($m, $n); + + $c = 0; + for($i = 0; $i < $m; ++$i) { + for($j = 0; $j < $this->cols; ++$j) + $aug->data[$c++] = $this($i, $j); + for($j = 0; $j < $rhs->cols; ++$j) + $aug->data[$c++] = $rhs($i, $j); + } + return $aug; + } + + /** + * Solves simultaneous equations using Gaussian elimination + */ + public function solve(Matrix $a, $bcscale) + { + $result = new Matrix(1, $a->rows); + $old_scale = bcscale($bcscale); + + // back substitution + $m = $a->rows; + $n = $a->cols; + for($i = $m - 1; $i >= 0; --$i) { + for($j = $n - 2; $j > $i; --$j) { + $value = bcsub($a($i, $n - 1), + bcmul($a($i, $j), $result(0, $j))); + $a($i, $n - 1, $value); + $a($i, $j, 0); + } + $d = $a($i, $i); + if($d == 0) + return null; + $value = bcdiv($a($i, $n - 1), $a($i, $i)); + $result(0, $i, $value); + } + + bcscale($old_scale); + return $result; + } + + /** + * Swaps two rows + */ + public function rowSwap($r1, $r2) + { + for($i = 0; $i < $this->cols; ++$i) { + $c = $this($r1, $i); + $this($r1, $i, $this($r2, $i)); + $this($r2, $i, $c); + } + } + + /** + * Output as string for debugging + */ + public function __toString() + { + $str = ''; + $m = 0; + foreach($this->data as $v) { + $m1 = abs($v); + if($m1 > $m) + $m = $m1; + } + + $digits = max(9,(int)log($m, 10) + 6); + for($r = 0; $r < $this->rows; ++$r) { + $str .= "\t"; + $r_offset = $r * $this->cols; + for($c = 0; $c < $this->cols; ++$c) { + $str .= sprintf(" %{$digits}.4f", $this->data[$r_offset + $c]); + } + $str .= "\n"; + } + return $str; + } + + /** + * Returns the data array + */ + public function asArray() + { + return $this->data; + } +} diff --git a/classes/vendor/goat1000/svggraph/Number.php b/classes/vendor/goat1000/svggraph/Number.php index 504198d..24fb373 100644 --- a/classes/vendor/goat1000/svggraph/Number.php +++ b/classes/vendor/goat1000/svggraph/Number.php @@ -1,6 +1,6 @@ units_before . $s . $this->units; } + + /** + * Converts a string with units to a value in SVG user units + */ + public static function units($value) + { + if(is_numeric($value) || $value === null) + return $value; + if(!is_string($value)) + throw new \InvalidArgumentException("Unit value not a string"); + + if(!preg_match('/^([0-9.]+)(px|in|cm|mm|pt|pc)$/', $value, $parts)) + throw new \InvalidArgumentException("Unit value {$value} not in supported format"); + + $count = (float)$parts[1]; + $units = $parts[2]; + $umap = [ + 'px' => 1.0, 'in' => 96.0, 'cm' => 37.795, 'mm' => 3.7795, 'pt' => 1.3333, 'pc' => 16.0 + ]; + return $count * $umap[$units]; + } } diff --git a/classes/vendor/goat1000/svggraph/README.txt b/classes/vendor/goat1000/svggraph/README.txt index 0012f90..31cc981 100644 --- a/classes/vendor/goat1000/svggraph/README.txt +++ b/classes/vendor/goat1000/svggraph/README.txt @@ -1,4 +1,4 @@ -SVGGraph Library version 3.19 +SVGGraph Library version 3.20 ============================= This library provides PHP classes and functions for easily creating SVG diff --git a/classes/vendor/goat1000/svggraph/SVGGraph.php b/classes/vendor/goat1000/svggraph/SVGGraph.php index 16a2fd1..6c7b3d9 100644 --- a/classes/vendor/goat1000/svggraph/SVGGraph.php +++ b/classes/vendor/goat1000/svggraph/SVGGraph.php @@ -25,7 +25,7 @@ class SVGGraph { use SVGGraphTrait; - const VERSION = 'SVGGraph 3.19'; + const VERSION = 'SVGGraph 3.20'; private $width = 100; private $height = 100; private $settings = []; diff --git a/classes/vendor/goat1000/svggraph/Text.php b/classes/vendor/goat1000/svggraph/Text.php index b72abd5..da3dd69 100644 --- a/classes/vendor/goat1000/svggraph/Text.php +++ b/classes/vendor/goat1000/svggraph/Text.php @@ -1,6 +1,6 @@ 0 ? $this->splitLines($text) : [$text]; $width = $height = 0; foreach($lines as $l) { @@ -259,6 +265,9 @@ private function getCacheKey($text, $font_size, $angle, $line_spacing) */ public function baseline($font_size) { + if(!is_numeric($font_size)) + throw new \InvalidArgumentException("Font size is not numeric"); + $metrics = $this->no_metrics ? false : $this->loadMetrics($this->font); if($metrics) { @@ -298,6 +307,9 @@ public function text($text, $line_spacing, $attribs, $styles = null) return $this->graph->element('text', $attribs, $styles, $content); } + if($line_spacing !== 0 && !is_numeric($line_spacing)) + throw new \InvalidArgumentException("Line spacing is not numeric"); + $lines = $this->splitLines($text); $content = ''; $group = 'text'; diff --git a/classes/vendor/goat1000/svggraph/TextShape.php b/classes/vendor/goat1000/svggraph/TextShape.php index bf9e7c7..04c5926 100644 --- a/classes/vendor/goat1000/svggraph/TextShape.php +++ b/classes/vendor/goat1000/svggraph/TextShape.php @@ -1,6 +1,6 @@ =7.1.10" + "php": ">=8.1.14" }, "require-dev": { - "composer/xdebug-handler": "^1.3", "ext-reflection": "*", - "paulthebaud/phpunit-generator": "^2.1", - "phan/phan": "^1.3", - "phploc/phploc": "^4.0", - "phpmetrics/phpmetrics": "^2.4", - "phpunit/phpunit": "^7", - "roave/better-reflection": "dev-master#c87d856" + "phan/phan": "*", + "phpmetrics/phpmetrics": "*", + "phpunit/phpunit": "*" }, "type": "library", "autoload": { - "classmap": [ - "sources" - ] + "psr-4": { + "Dallgoot\\Yaml\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -53,13 +49,65 @@ "email": "stephane.rebai@gmail.com" } ], - "description": "Provides loader, dumper and an API for YAML content. Loader builds to equivalent data types in PHP 7.x", + "description": "Provides loader, dumper and an API for YAML content. Loader builds to equivalent data types in PHP 8.x", "homepage": "https://github.com/dallgoot/yaml", "keywords": [ "parser", + "reader", + "writer", "yaml" ], - "time": "2020-01-08T19:03:03+00:00" + "support": { + "issues": "https://github.com/dallgoot/yaml/issues", + "source": "https://github.com/dallgoot/yaml/tree/0.9.1.1" + }, + "funding": [ + { + "url": "https://github.com/dallgoot", + "type": "github" + } + ], + "time": "2023-04-11T09:49:37+00:00" + }, + { + "name": "goat1000/svggraph", + "version": "3.20.0", + "source": { + "type": "git", + "url": "https://github.com/goat1000/SVGGraph.git", + "reference": "99576c9ad38763b8f10e6b03a9cff1ce32604869" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/goat1000/SVGGraph/zipball/99576c9ad38763b8f10e6b03a9cff1ce32604869", + "reference": "99576c9ad38763b8f10e6b03a9cff1ce32604869", + "shasum": "" + }, + "require": { + "ext-json": "*", + "lib-pcre": "*", + "php": ">=5.4.0" + }, + "suggest": { + "ext-iconv": "For non-ASCII text measurement support" + }, + "type": "library", + "autoload": { + "psr-4": { + "Goat1000\\SVGGraph\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "LGPL-3.0-only" + ], + "description": "Generates SVG graphs", + "homepage": "http://www.goat1000.com/svggraph.php", + "support": { + "issues": "https://github.com/goat1000/SVGGraph/issues", + "source": "https://github.com/goat1000/SVGGraph/tree/3.20.0" + }, + "time": "2023-04-25T08:27:40+00:00" } ], "packages-dev": [], @@ -70,5 +118,5 @@ "prefer-lowest": false, "platform": [], "platform-dev": [], - "plugin-api-version": "1.1.0" + "plugin-api-version": "2.0.0" } diff --git a/db/install.php b/db/install.php index 56aa56b..6af56d2 100644 --- a/db/install.php +++ b/db/install.php @@ -24,9 +24,8 @@ */ defined('MOODLE_INTERNAL') || die(); -require_once($CFG->dirroot . '/mod/verbalfeedback/classes/vendor/autoload.php'); require_once($CFG->dirroot . '/mod/verbalfeedback/db/upgradelib.php'); -require_once($CFG->dirroot . '/mod/verbalfeedback/classes/vendor/dallgoot/yaml/sources/Yaml.php'); +require_once($CFG->dirroot . '/mod/verbalfeedback/classes/vendor/dallgoot/yaml/src/Yaml.php'); use mod_verbalfeedback\model\language; use mod_verbalfeedback\model\localized_string; @@ -40,7 +39,7 @@ use mod_verbalfeedback\repository\template_criterion_repository; use mod_verbalfeedback\repository\template_repository; use mod_verbalfeedback\model\subrating; -use Dallgoot\Yaml; +use mod_verbalfeedback\Dallgoot\Yaml; /** * Install the plugin. diff --git a/thirdpartylibs.xml b/thirdpartylibs.xml index 38f8693..1cf22fa 100644 --- a/thirdpartylibs.xml +++ b/thirdpartylibs.xml @@ -10,7 +10,7 @@ classes/vendor/dallgoot/yaml/ Dallgoot : YAML library for PHP - v0.3.2 + 0.9.1.1 Apache 2.0