承接 liberty_code/config 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

liberty_code/config

最新稳定版本:v1.1.0

Composer 安装命令:

composer require liberty_code/config

包简介

Library

README 文档

README

Description

Library contains configuration components, allows to get value from specified key.

Requirement

  • Script language: PHP: version 7 || 8

Installation

Several ways are possible:

Composer

  1. Requirement

    It requires composer installation. For more information: https://getcomposer.org

  2. Command: Move in project root path

     cd "<project_root_path>"
    
  3. Command: Installation

     php composer.phar require liberty_code/config ["<version>"]
    
  4. Note

    • Include vendor

      If project uses composer, vendor must be included:

        require_once('<project_root_path>/vendor/autoload.php');
      
    • Configuration

      Installation command allows to add, on composer file "/composer.json", following configuration:

        {
            "require": {
                "liberty_code/config": "<version>"
            }
        }
      

Include

  1. Download

    • Download following repository.
    • Put it on repository root path.
  2. Include source

     require_once('<repository_root_path>/include/Include.php');
    

Usage

Configuration

Configuration allows to retrieve values from keys.

Elements

  • Config

    Configuration allows to design basic configuration class, with features to retrieve value, from specified key.

  • DataConfig

    Extends configuration features. It uses data features to get values.

  • RegisterConfig

    Extends configuration features. It uses register features to get values.

  • CacheConfig

    Extends configuration features. It uses cache repository features to get values.

Example

// Get data
use liberty_code\data\data\table\path\model\PathTableData;
$data = new PathTableData();
...
// Set data source
$data->setDataSrc(...);
...
// Get data configuration
use liberty_code\config\config\data\model\DataConfig;
$config = new DataConfig($data);
...
// Show specified value
echo($config->getValue('... string key'));
...

统计信息

  • 总下载量: 1.62k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 12
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2018-06-30