当前位置: 首页>>代码示例>>PHP>>正文


PHP Repository::__construct方法代码示例

本文整理汇总了PHP中Illuminate\Config\Repository::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Repository::__construct方法的具体用法?PHP Repository::__construct怎么用?PHP Repository::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Illuminate\Config\Repository的用法示例。


在下文中一共展示了Repository::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 /**
  * Create a new configuration repository.
  *
  * @param \Laradic\Config\Loaders\LoaderInterface $loader
  * @param \Illuminate\Filesystem\Filesystem       $files
  * @param  string                                 $environment
  */
 public function __construct(LoaderInterface $loader, Filesystem $files, $environment)
 {
     parent::__construct();
     $this->setLoader($loader);
     $this->files = $files;
     $this->environment = $environment;
 }
开发者ID:laradic,项目名称:config,代码行数:14,代码来源:Repository.php

示例2: __construct

 /**
  * Settings constructor.
  *
  * @param CacheRepository $cache
  * @param Manager         $manager
  */
 public function __construct(CacheRepository $cache, Manager $manager)
 {
     $this->cache = $cache;
     parent::__construct($this->cache->rememberForever(self::CACHE_KEY, function () use($manager) {
         return Entities\Settings::all()->pluck('value', 'name')->all();
     }));
 }
开发者ID:rabbitcms,项目名称:settings,代码行数:13,代码来源:Repository.php

示例3: __construct

 public function __construct(LoaderInterface $loader, $environment, $defaultPath)
 {
     parent::__construct($loader, $environment);
     $this->defaultPath = $defaultPath;
     $this->loader = $loader;
     $this->files = $loader->getFilesystem();
 }
开发者ID:Rotron,项目名称:shop,代码行数:7,代码来源:Writer.php

示例4: __construct

 /**
  * Initialize the config repository and load files.
  *
  * @param Loader $loader
  */
 public function __construct(Loader $loader)
 {
     parent::__construct();
     $files = $loader->getFiles();
     foreach ($files as $key => $path) {
         $this->set($key, require $path);
     }
 }
开发者ID:loshmis,项目名称:simple-config,代码行数:13,代码来源:Config.php

示例5: __construct

 public function __construct($app)
 {
     $this->app = $app;
     $items = (array) $app->make('config');
     $items = end($items);
     parent::__construct($items);
     $this->init();
 }
开发者ID:microweber,项目名称:microweber,代码行数:8,代码来源:ConfigSave.php

示例6:

 /**
  * @param Finder $finder
  * @param $configRoot
  * @param null $envPath
  */
 function __construct(Finder $finder, $configRoot, $envPath = null)
 {
     $this->isLoaded = false;
     $this->finder = $finder;
     $this->configRoot = $configRoot;
     $this->envPath = $envPath;
     parent::__construct();
 }
开发者ID:fureszpeter,项目名称:laratools,代码行数:13,代码来源:Config.php

示例7: __construct

 /**
  * Create a new configuration repository.
  *
  * @param LoaderInterface $loader
  * @param SaverInterface  $saver
  * @param                 $environment
  */
 public function __construct(LoaderInterface $loader, SaverInterface $saver, $environment)
 {
     $this->saver = $saver;
     parent::__construct($loader, $environment);
 }
开发者ID:ppiedaderawnet,项目名称:concrete5,代码行数:12,代码来源:Repository.php

示例8: __construct

 /**
  * @param LoaderInterface $loader
  * @param string $env
  * @param array $setting
  */
 public function __construct(LoaderInterface $loader, $env, array $setting)
 {
     parent::__construct($loader, $env);
     $this->setting = $setting;
 }
开发者ID:the-hasanov,项目名称:larfing,代码行数:10,代码来源:Larfing.php

示例9: __construct

 /**
  * Create a new translator instance.
  * @param  \Illuminate\Config\LoaderInterface  $loader
  * @param  string  $environment
  * @return void
  */
 public function __construct(LoaderInterface $loader, $environment)
 {
     parent::__construct($loader, $environment);
     $appLoader = new FileLoader(new Filesystem(), app_path() . '/config');
     $this->appRepository = new IlluminateRepository($appLoader, $environment);
 }
开发者ID:tamboer,项目名称:LaravelOctober,代码行数:12,代码来源:Repository.php

示例10: __construct

 public function __construct($name, $path = 'config')
 {
     $this->name = $name;
     $this->path = $path;
     parent::__construct(Config::get($name));
 }
开发者ID:mean-cj,项目名称:config-writer,代码行数:6,代码来源:Repository.php

示例11: __construct

 /**
  * Create a new configuration repository.
  *
  * @param  array  $items
  * @param  FileWriter $writer
  * @return void
  */
 public function __construct($items = array(), $writer)
 {
     $this->writer = $writer;
     parent::__construct($items);
 }
开发者ID:astatroth,项目名称:laravel-config,代码行数:12,代码来源:Repository.php

示例12: __construct

 /**
  * ConfigRepo constructor.
  * @param array $items
  */
 public function __construct(array $items = [])
 {
     $items = app('config')->get('backuplay');
     parent::__construct($items);
 }
开发者ID:gummibeer,项目名称:backuplay,代码行数:9,代码来源:Config.php

示例13: __construct

 /**
  * Create a new configuration repository.
  *
  * @param  \Illuminate\Config\LoaderInterface  $loader
  * @param  string  $environment
  * @return void
  */
 public function __construct(LoaderInterface $loader, $environment)
 {
     $loader = new FileLoader($loader->getFilesystem(), app_path() . '/config');
     parent::__construct($loader, $environment);
 }
开发者ID:tjbp,项目名称:saveconfig,代码行数:12,代码来源:SaveConfig.php

示例14: __construct

 public function __construct($name)
 {
     $this->name = $name;
     parent::__construct(Config::get($name, []));
 }
开发者ID:larapack,项目名称:config-writer,代码行数:5,代码来源:Repository.php

示例15: __construct

 /**
  * Constructor.
  *
  * @return void
  */
 public function __construct(array $items = [], CacheManager $cache = null)
 {
     $this->cache = $cache;
     parent::__construct($items);
 }
开发者ID:sohailaammarocs,项目名称:lfc,代码行数:10,代码来源:Repository.php


注:本文中的Illuminate\Config\Repository::__construct方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。