Example #1
0
 /**
  * Create a new translator instance.
  * @param  \Illuminate\Translation\LoaderInterface  $loader
  * @param  string  $locale
  * @param  \Illuminate\Filesystem\Filesystem  $files
  * @return void
  */
 public function __construct(LoaderInterface $loader, $locale, $fallbackLocale, Filesystem $files)
 {
     parent::__construct($loader, $locale);
     parent::setFallback($fallbackLocale);
     $appLoader = new FileLoader($files, app_path() . '/lang');
     $this->appTranslator = new IlluminateTranslator($appLoader, $locale);
 }
 /**
  * Translator constructor.
  */
 public function __construct(Application $app, LoaderInterface $loader, $locale)
 {
     parent::__construct($loader, $locale);
     $this->suspendInPlaceEdit = 0;
     $this->inPlaceEditing = null;
     $this->useDB = 1;
     // fill in missing keys from DB by default
     $this->app = $app;
 }
 public function __construct(LoaderInterface $loader, $locale, $debugbar)
 {
     $this->debugbar = $debugbar;
     parent::__construct($loader, $locale);
 }
 public function __construct(LoaderInterface $database, LoaderInterface $loader, $locale, Application $app)
 {
     $this->database = $database;
     $this->app = $app;
     parent::__construct($loader, $locale);
 }
Example #5
0
 /**
  * Build the language class
  *
  * @param Container $app
  */
 public function __construct(Container $app)
 {
     $this->app = $app;
     $this->domain = $app['config']->get('polyglot::domain');
     parent::__construct($app['translation.loader'], $app['config']->get('app.locale'));
 }