當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Generator::getReplacements方法代碼示例

本文整理匯總了PHP中Generator::getReplacements方法的典型用法代碼示例。如果您正苦於以下問題:PHP Generator::getReplacements方法的具體用法?PHP Generator::getReplacements怎麽用?PHP Generator::getReplacements使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Generator的用法示例。


在下文中一共展示了Generator::getReplacements方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     $modelGenerator = new ModelGenerator(['name' => $this->name]);
     $model = $modelGenerator->getRootNamespace() . '\\' . $modelGenerator->getName();
     $model = str_replace(["\\", '/'], '\\', $model);
     return array_merge(parent::getReplacements(), ['model' => $model]);
 }
開發者ID:eaglesistemas,項目名稱:eaglerepository,代碼行數:12,代碼來源:TransformerGenerator.php

示例2: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     $transformerGenerator = new TransformerGenerator(['name' => $this->name]);
     $transformer = $transformerGenerator->getRootNamespace() . '\\' . $transformerGenerator->getName() . 'Transformer';
     $transformer = str_replace(["\\", '/'], '\\', $transformer);
     echo $transformer;
     return array_merge(parent::getReplacements(), ['transformer' => $transformer]);
 }
開發者ID:eaglesistemas,項目名稱:eaglerepository,代碼行數:13,代碼來源:PresenterGenerator.php

示例3: getReplacements

 /**
  * Get template replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['extends' => $this->extends, 'section' => $this->section, 'content' => $this->content], $this->customReplacements);
 }
開發者ID:mayconbordin,項目名稱:laragen,代碼行數:9,代碼來源:ViewGenerator.php

示例4: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['controller' => $this->getControllerName(), 'plural' => $this->getPluralName(), 'singular' => $this->getSingularName(), 'validator' => $this->getValidator(), 'repository' => $this->getRepository(), 'appname' => $this->getAppNamespace()]);
 }
開發者ID:someline,項目名稱:starter-framework,代碼行數:9,代碼來源:ControllerGenerator.php

示例5: getReplacements

 /**
  * Get template replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['command' => $this->option('command', 'command:name'), 'description' => $this->option('description', 'Command description')]);
 }
開發者ID:Avantinternet,項目名稱:generators,代碼行數:9,代碼來源:ConsoleGenerator.php

示例6: getReplacements

 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['abstract_repository' => $this->AbstractRepository(), 'interface' => $this->getInterface()]);
 }
開發者ID:sthWrong,項目名稱:season5.co,代碼行數:4,代碼來源:RepositoryEloquentGenerator.php

示例7: getReplacements

 /**
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['transformer' => $this->getOption('transformer') ?: parent::getRootNamespace() . 'Repositories\\Transformers\\' . $this->getName()]);
 }
開發者ID:killtw,項目名稱:repository,代碼行數:7,代碼來源:PresenterGenerator.php

示例8: getReplacements

 /**
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['model' => strpos('\\', $this->getOption('model')) != false ? $this->getOption('model') : $this->getModelNamespace() . $this->getOption('model'), 'presenter' => $this->getOption('presenter'), 'presenterClass' => $this->getOption('presenterClass') ?: 'null']);
 }
開發者ID:killtw,項目名稱:repository,代碼行數:7,代碼來源:RepositoryGenerator.php

示例9: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['repository' => $this->getRepository(), 'eloquent' => $this->getEloquentRepository(), 'placeholder' => $this->bindPlaceholder]);
 }
開發者ID:eaglesistemas,項目名稱:eaglerepository,代碼行數:9,代碼來源:BindingsGenerator.php

示例10: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['appnamespace' => $this->getAppNamespace()]);
 }
開發者ID:leloulight,項目名稱:ProjectManager,代碼行數:9,代碼來源:PresenterGenerator.php

示例11: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     $modelGenerator = new ModelGenerator();
     return array_merge(parent::getReplacements(), ['model_namespace' => $modelGenerator->getRootNamespace()]);
 }
開發者ID:leloulight,項目名稱:ProjectManager,代碼行數:10,代碼來源:TransformerGenerator.php

示例12: getReplacements

 /**
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['model' => strpos('\\', $this->getOption('model')) != false ? $this->getOption('model') : $this->getModelNamespace() . $this->getOption('model')]);
 }
開發者ID:killtw,項目名稱:repository,代碼行數:7,代碼來源:TransformerGenerator.php

示例13: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['screenable' => $this->getScreenable()]);
 }
開發者ID:geehare,項目名稱:laraval-screen,代碼行數:9,代碼來源:ScreenGenerator.php

示例14: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     return array_merge(parent::getReplacements(), ['validator' => $this->getValidator(), 'repository' => $this->getRepository(), 'namespace' => 'namespace ' . $this->getRootNamespace() . '\\' . $this->getName() . ';', 'appname' => $this->getAppNamespace(), 'managername' => $this->getManagerName()]);
 }
開發者ID:mammutgroup,項目名稱:l5-repository,代碼行數:9,代碼來源:ManagerGenerator.php

示例15: getReplacements

 /**
  * Get array replacements.
  *
  * @return array
  */
 public function getReplacements()
 {
     $transformerGenerator = new TransformerGenerator(['name' => $this->name]);
     return array_merge(parent::getReplacements(), ['transformer_namespace' => $transformerGenerator->getNamespaceName()]);
 }
開發者ID:ptcong,項目名稱:l5-repository,代碼行數:10,代碼來源:PresenterGenerator.php


注:本文中的Generator::getReplacements方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。