{"id":28913969,"url":"https://github.com/slexx1234/config","last_synced_at":"2025-07-24T15:05:03.678Z","repository":{"id":57053244,"uuid":"98798550","full_name":"slexx1234/config","owner":"slexx1234","description":"PHP Config manager","archived":false,"fork":false,"pushed_at":"2018-05-10T12:37:04.000Z","size":17,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-05-03T10:31:44.763Z","etag":null,"topics":["configuration","ini","json","php","yaml"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/slexx1234.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-07-30T13:14:38.000Z","updated_at":"2024-05-03T10:31:44.764Z","dependencies_parsed_at":"2022-08-24T04:11:35.957Z","dependency_job_id":null,"html_url":"https://github.com/slexx1234/config","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/slexx1234/config","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slexx1234%2Fconfig","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slexx1234%2Fconfig/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slexx1234%2Fconfig/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slexx1234%2Fconfig/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/slexx1234","download_url":"https://codeload.github.com/slexx1234/config/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slexx1234%2Fconfig/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261193147,"owners_count":23122913,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["configuration","ini","json","php","yaml"],"created_at":"2025-06-21T21:11:16.280Z","updated_at":"2025-07-24T15:05:03.666Z","avatar_url":"https://github.com/slexx1234.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"Config\n=========================================\n[![Latest Stable Version](https://poser.pugx.org/slexx/config/v/stable)](https://packagist.org/packages/slexx/config) [![Total Downloads](https://poser.pugx.org/slexx/config/downloads)](https://packagist.org/packages/slexx/config) [![Latest Unstable Version](https://poser.pugx.org/slexx/config/v/unstable)](https://packagist.org/packages/slexx/config) [![License](https://poser.pugx.org/slexx/config/license)](https://packagist.org/packages/slexx/config)\n\n## Установка\n\nУстановка через `composer`:\n\n```\n$ composer require slexx/config\n```\n\n## Документация\n\n### Config-\u003e__construct([$file])\n\n**Аргументы:**\n\n| Имя     | Тип               | Описание                    |\n|---------|-------------------|-----------------------------|\n| [$file] | `string`, `array` | Имя файла имя массив данных |\n\n**Пример:**\n\n```php\nnew Config('config.json');\nnew Config('config.ini');\nnew Config();\nnew Config(['foo' =\u003e 'bar']);\n```\n\n### Config-\u003esetFile($file)\n\nУстановка пути к файлу\n\n**Аргументы:**\n\n| Имя   | Тип              | Описание     |\n|-------|------------------|--------------|\n| $file | `null`, `string` | Путь к файлу |\n\n**Возвращает:** `$this`\n\n### Config-\u003egetFile()\n\nПолучение пути к файлу\n\n**Возвращает:** `null`, `string`\n\n### Config-\u003esave()\n\nСохранение конфигурайии\n\n**Возвращает:** `$this`\n\n**Пример:**\n\n```php\n$config = new Config('config.json')\n$config-\u003eset('foo', 'bar');\n$config-\u003esave();\n```\n\n### Config-\u003etoArray()\n\nПреобразование в массив\n\n**Возвращает:** `array`\n\n### Config-\u003eall()\n\n**Возвращает:** `array`\n\n### Config-\u003ecount()\n\n**Возвращает:** `int`\n\n### Config-\u003egetIterator()\n\n**Возвращает:** `\\ArrayIterator`\n\n### Config-\u003eset($key, $value)\n\nУстановка переменной конфигурации\n\n**Аргументы:**\n\n| Имя    | Тип      | Описание            |\n|--------|----------|---------------------|\n| $key   | `string` | Имя переменной      |\n| $value | `mixed`  | Значение переменной |\n\n**Возвращает:** `$this`\n\n### Config-\u003ehas($key)\n\nПроверка существования переменной конфигурации\n\n**Аргументы:**\n\n| Имя  | Тип      | Описание       |\n|------|----------|----------------|\n| $key | `string` | Имя переменной |\n\n**Возвращает:** `bool`\n\n### Config-\u003eget($key)\n\nПолучение значение переменной конфигурации\n\n**Аргументы:**\n\n| Имя  | Тип      | Описание       |\n|------|----------|----------------|\n| $key | `string` | Имя переменной |\n\n**Возвращает:** `mixed`, `null` - Значение переменной или null в случае её отсуцтвия\n\n### Config-\u003eremove($key)\n\nУдаление переменной конфигурации\n\n**Аргументы:**\n\n| Имя  | Тип      | Описание       |\n|------|----------|----------------|\n| $key | `string` | Имя переменной |\n\n**Возвращает:** `$this`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslexx1234%2Fconfig","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslexx1234%2Fconfig","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslexx1234%2Fconfig/lists"}