<commit_before><?php

namespace Configula;

use CallbackFilterIterator;
use Configula\Exception\ConfigLogicException;
use Configula\Loader\ArrayValuesLoader;
use Configula\Loader\CascadingConfigLoader;
use Configula\Loader\ConfigFolderFilesLoader;
use Configula\Loader\ConfigLoaderInterface;
use Configula\Loader\FileLoader;

/**
 * Config Facade Class
 *
 * Provides convenience methods to load configuration using many different strategies in one-step
 *
 * @package Configula
 */
class ConfigFactory
{
    /**
     * Build configuration from array
     *
     * @param array $items
     * @return ConfigValues
     */
    public static function build(array $items): ConfigValues
    {
        return new ConfigValues($items);
    }

    /**
     * Load config using single loader<commit_msg>Change `ConfigFactory::build` to `ConfigFactory::fromArray`<commit_after><?php

namespace Configula;

use CallbackFilterIterator;
use Configula\Exception\ConfigLogicException;
use Configula\Loader\ArrayValuesLoader;
use Configula\Loader\CascadingConfigLoader;
use Configula\Loader\ConfigFolderFilesLoader;
use Configula\Loader\ConfigLoaderInterface;
use Configula\Loader\FileLoader;

/**
 * Config Facade Class
 *
 * Provides convenience methods to load configuration using many different strategies in one-step
 *
 * @package Configula
 */
class ConfigFactory
{
    /**
     * Build configuration from array
     *
     * @param array $items
     * @return ConfigValues
     */
    public static function fromArray(array $items): ConfigValues
    {
        return new ConfigValues($items);
    }

    /**
     * Load config using single loader
{'fraction_non_alphanumeric': 0.08302808302808302, 'fraction_numerical': 0.0, 'mean_word_length': 3.9969512195121952, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4515098', 'n_tokens_mistral': 430, 'n_tokens_neox': 429, 'n_words': 120}