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


PHP Command::__construct方法代碼示例

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


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

示例1: __construct

 /**
  * @param TransferFunds $useCase
  * @param EwalletExtension $formatter
  */
 public function __construct(TransferFunds $useCase, MemberFormatter $formatter)
 {
     parent::__construct();
     $this->formatter = $formatter;
     $this->useCase = $useCase;
     $this->useCase->attach($this);
 }
開發者ID:zoek1,項目名稱:php-testing-tools,代碼行數:11,代碼來源:TransferFundsCommand.php

示例2: __construct

 /**
  * @param UserRepository $userRepository
  * @param ReviewRepository $reviewRepository
  * @param ScoreManager $scoreManager
  */
 public function __construct(UserRepository $userRepository, ReviewRepository $reviewRepository, ScoreManager $scoreManager)
 {
     parent::__construct();
     $this->userRepository = $userRepository;
     $this->reviewRepository = $reviewRepository;
     $this->scoreManager = $scoreManager;
 }
開發者ID:oriodesign,項目名稱:tastd-backend-demo,代碼行數:12,代碼來源:ScoreCalculatorCommand.php

示例3:

 /**
  * @param IUserManager $userManager
  * @param IDBConnection $dbConnection
  */
 function __construct(IUserManager $userManager, IGroupManager $groupManager, IDBConnection $dbConnection)
 {
     parent::__construct();
     $this->userManager = $userManager;
     $this->groupManager = $groupManager;
     $this->dbConnection = $dbConnection;
 }
開發者ID:GitHubUser4234,項目名稱:core,代碼行數:11,代碼來源:CreateCalendar.php

示例4: __construct

 public function __construct(SlackService $slack)
 {
     parent::__construct();
     $this->emitter = $slack->getEmitter();
     $this->loop = $slack->getLoop();
     $this->slack = $slack;
 }
開發者ID:jyggen,項目名稱:pingu,代碼行數:7,代碼來源:PinguCommand.php

示例5: __construct

 /**
  * Constructor, used for Command
  *
  * @param string $name
  */
 public function __construct($name = null)
 {
     parent::__construct($name);
     $this->_mustache = new \Mustache_Engine();
     $this->_rootDir = dirname(__FILE__);
     $this->_swaggerSource = json_decode(file_get_contents(App::ENDPOINT . App::VERSION . self::SOURCE_URI), true);
 }
開發者ID:afosto,項目名稱:api-client,代碼行數:12,代碼來源:Generator.php

示例6: __construct

 public function __construct(Service\System\Import $importService, Connection $connection, LoggerInterface $logger)
 {
     parent::__construct();
     $this->importService = $importService;
     $this->connection = $connection;
     $this->logger = $logger;
 }
開發者ID:apioo,項目名稱:fusio-impl,代碼行數:7,代碼來源:ImportCommand.php

示例7: __construct

 public function __construct(DrupalApi $drupalApi, Client $httpClient, $appRoot)
 {
     $this->drupalApi = $drupalApi;
     $this->httpClient = $httpClient;
     $this->appRoot = $appRoot;
     parent::__construct();
 }
開發者ID:ddrozdik,項目名稱:DrupalConsole,代碼行數:7,代碼來源:DownloadCommand.php

示例8: __construct

 /**
  * class constructor. get $Silex argument and set it to property. this must be set in Commands.php file to make it work.
  * 
  * @param string | null $name The name of the command; passing null means it must be set in configure()
  * @param \Silex\Application $SilexApp The Silex application class which is contain database class in there.
  */
 public function __construct($name = null, \Silex\Application $SilexApp = null)
 {
     parent::__construct($name);
     $this->Silexapp = $SilexApp;
     $this->Db = $this->Silexapp['Db'];
     unset($SilexApp);
 }
開發者ID:AgniCMS,項目名稱:agni-framework,代碼行數:13,代碼來源:ModulesDisable.php

示例9: __construct

 public function __construct(Router $router, RoutingContextInterface $context, RequestScopeManager $scope)
 {
     parent::__construct();
     $this->router = $router;
     $this->context = $context;
     $this->requestScope = $scope;
 }
開發者ID:koolkode,項目名稱:http-komponent,代碼行數:7,代碼來源:DumpRoutesCommand.php

示例10: __construct

 public function __construct(IUserManager $userManager, IManager $shareManager, IMountManager $mountManager)
 {
     $this->userManager = $userManager;
     $this->shareManager = $shareManager;
     $this->mountManager = $mountManager;
     parent::__construct();
 }
開發者ID:rchicoli,項目名稱:owncloud-core,代碼行數:7,代碼來源:TransferOwnership.php

示例11: __construct

 /**
  * TravisCiCommand constructor.
  * @param TravisCiQuestionHelper $questionHelper
  * @param ConfigBuilder|null $configBuilder
  * @param ConfigWriter $configWriter
  * @throws \Symfony\Component\Console\Exception\LogicException
  */
 public function __construct(TravisCiQuestionHelper $questionHelper, ConfigBuilder $configBuilder, ConfigWriter $configWriter)
 {
     parent::__construct('ci:travis-ci');
     $this->configBuilder = $configBuilder;
     $this->configWriter = $configWriter;
     $this->questionHelper = $questionHelper;
 }
開發者ID:quickstrap,項目名稱:quickstrap,代碼行數:14,代碼來源:TravisCiCommand.php

示例12: __construct

 /**
  * @param GrumPHP    $config
  * @param Filesystem $filesystem
  * @param Repository $repository
  */
 public function __construct(GrumPHP $config, Filesystem $filesystem, Repository $repository)
 {
     parent::__construct();
     $this->config = $config;
     $this->filesystem = $filesystem;
     $this->repository = $repository;
 }
開發者ID:NoUseFreak,項目名稱:grumphp,代碼行數:12,代碼來源:ConfigureCommand.php

示例13: __construct

 /**
  * Construct an instance of a CleanCommand.
  */
 public function __construct()
 {
     parent::__construct('style:clean');
     $this->setDescription('Runs all fix and format operations.');
     $this->addOption('dry-run', null, InputOption::VALUE_NONE, 'Pretend to run and show operation that would be performed.');
     $this->addOption('diff', null, InputOption::VALUE_NONE, 'Show diff of changes.');
 }
開發者ID:MarkVaughn,項目名稱:standard,代碼行數:10,代碼來源:CleanCommand.php

示例14: __construct

 public function __construct(\OCA\User_Files_Restore\Db\RequestMapper $requestMapper)
 {
     $this->requestMapper = $requestMapper;
     $this->searchedStatus = null;
     $this->csv = FALSE;
     parent::__construct();
 }
開發者ID:ppaysant,項目名稱:user_files_restore,代碼行數:7,代碼來源:requestlist.php

示例15: __construct

 /**
  * @param string             $name
  * @param ContainerInterface $dic
  *
  * @throws \Symfony\Component\Console\Exception\InvalidArgumentException
  * @throws \Symfony\Component\Console\Exception\LogicException
  */
 public function __construct(string $name, ContainerInterface $dic)
 {
     $this->setDescription('Used to setup Yapeal-ng after Composer require or to interactively do so any time');
     $this->setName($name);
     $this->setDic($dic);
     parent::__construct($name);
 }
開發者ID:yapeal,項目名稱:yapeal-ng,代碼行數:14,代碼來源:YapealSetup.php


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