本文整理汇总了PHP中Alchemy\Phrasea\Command\Command::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Command::__construct方法的具体用法?PHP Command::__construct怎么用?PHP Command::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Alchemy\Phrasea\Command\Command
的用法示例。
在下文中一共展示了Command::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Constructor
*/
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Rescans records for technical datas');
$this->setHelp('Old Phraseanet version did not fully read technical datas. This command rescan all records of these datas.');
return $this;
}
示例2: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Checks if email addresses are uniques (mandatory since 3.5)');
$this->addOption('list', 'l', null, 'List all bad accounts instead of the interactive mode');
return $this;
}
示例3: __construct
public function __construct($name = null)
{
parent::__construct($name);
$dir = sprintf('%s/config/', dirname(dirname(dirname(dirname(__DIR__)))));
$this->setDescription('Backups Phraseanet Databases')->addArgument('directory', null, 'The directory where to backup', $dir)->addOption('timeout', 't', InputOption::VALUE_REQUIRED, 'The timeout for this command (default is 3600s / 1h). Set 0 to disable timeout.', 3600)->addOption('gzip', 'g', null, 'Gzip the output (requires gzip utility)')->addOption('bzip', 'b', null, 'Bzip the output (requires bzip2 utility)');
return $this;
}
示例4: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Exports all phraseanet records to a given directory');
/**
* To implement
*/
// $this->addOption('useoriginalname', 'o', InputOption::VALUE_OPTIONAL
// , 'Use original name for dest files', false);
/**
* To implement
*/
// $this->addOption('excludefield', 'f', InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY
// , 'Exclude field from XML', []);
/**
* To implement
*/
// $this->addOption('excludestatus', '', InputOption::VALUE_OPTIONAL
// , 'Exclude Status', false);
$this->addOption('docperdir', 'd', InputOption::VALUE_OPTIONAL, 'Maximum number of files per dir', 100);
$this->addOption('caption', 'c', InputOption::VALUE_OPTIONAL, 'Export Caption (XML)', false);
$this->addOption('limit', 'l', InputOption::VALUE_OPTIONAL, 'Limit files quantity (for test purposes)', false);
$this->addOption('base_id', 'b', InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY, 'Restrict on base_ids', []);
$this->addOption('sbas_id', 's', InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY, 'Restrict on sbas_ids', []);
$this->addArgument('directory', InputOption::VALUE_REQUIRED, 'The directory where to export');
$this->addOption('sanitize', '', InputOption::VALUE_REQUIRED, 'Sanitize filenames. Set to 0 to disable', true);
return $this;
}
示例5: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->executableFinder = new ExecutableFinder();
$this->setDescription("Installs Phraseanet")->addOption('email', null, InputOption::VALUE_OPTIONAL, 'Admin e-mail address', null)->addOption('password', null, InputOption::VALUE_OPTIONAL, 'Admin password', null)->addOption('db-host', null, InputOption::VALUE_OPTIONAL, 'MySQL server host', 'localhost')->addOption('db-port', null, InputOption::VALUE_OPTIONAL, 'MySQL server port', 3306)->addOption('db-user', null, InputOption::VALUE_OPTIONAL, 'MySQL server user', 'phrasea')->addOption('db-password', null, InputOption::VALUE_OPTIONAL, 'MySQL server password', null)->addOption('db-template', null, InputOption::VALUE_OPTIONAL, 'Metadata structure language template (available are fr (french) and en (english))', null)->addOption('databox', null, InputOption::VALUE_OPTIONAL, 'Database name for the DataBox', null)->addOption('appbox', null, InputOption::VALUE_OPTIONAL, 'Database name for the ApplicationBox', null)->addOption('data-path', null, InputOption::VALUE_OPTIONAL, 'Path to data repository', realpath(__DIR__ . '/../../../../../datas'))->addOption('server-name', null, InputOption::VALUE_OPTIONAL, 'Server name')->addOption('indexer', null, InputOption::VALUE_OPTIONAL, 'Path to Phraseanet Indexer', 'auto')->addOption('yes', 'y', InputOption::VALUE_NONE, 'Answer yes to all questions');
return $this;
}
示例6: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Performs a serie of tests against Phrasea Engine PHP Extension');
$this->addArgument('usr_id', InputOption::VALUE_REQUIRED, 'Usr_id to use.');
$this->addOption('query', '', InputOption::VALUE_OPTIONAL, 'The query', 'last');
return $this;
}
示例7: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Deletes a documentation field from a Databox');
$this->addArgument('meta_struct_id', InputArgument::REQUIRED, 'Metadata structure id destination');
$this->addArgument('sbas_id', InputArgument::REQUIRED, 'Databox sbas_id');
return $this;
}
示例8: __construct
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Merges databox documentation fields');
$this->addArgument('sbas_id', InputArgument::REQUIRED, 'Databox sbas_id');
$this->addArgument('destination', InputArgument::REQUIRED, 'Metadata structure id destination');
$this->addArgument('source', InputArgument::REQUIRED | InputArgument::IS_ARRAY, 'Metadata structure ids for source');
$this->addOption('separator', '', InputOption::VALUE_OPTIONAL, 'Separator for concatenation (if destination is monovalued)', ';');
return $this;
}
示例9: __construct
/**
* Constructor
*/
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Build subviews for given subview names and record types');
$this->addArgument('databox', InputArgument::REQUIRED, 'The databox id');
$this->addArgument('type', InputArgument::REQUIRED, 'Types of the document to rebuild');
$this->addArgument('subdefs', InputArgument::REQUIRED, 'Names of sub-definition to re-build');
$this->addOption('max_record', 'max', InputOption::VALUE_OPTIONAL, 'Max record id');
$this->addOption('min_record', 'min', InputOption::VALUE_OPTIONAL, 'Min record id');
$this->addOption('with-substitution', 'wsubstit', InputOption::VALUE_NONE, 'Regenerate subdefs for substituted records as well');
$this->addOption('substitution-only', 'substito', InputOption::VALUE_NONE, 'Regenerate subdefs for substituted records only');
return $this;
}
示例10: __construct
/**
* Constructor
*/
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription("Upgrades Phraseanet datas, useful after migrations")->setHelp(<<<EOF
Upgrade Phraseanet datas from older version
Steps are
- version 3.1 : records UUID
- version 3.5 : metadatas upgrade
EOF
);
$this->addOption('from', 'f', InputOption::VALUE_REQUIRED, 'The version where to start upgrade');
$this->addOption('at-version', null, InputOption::VALUE_REQUIRED, 'The version step to upgrade');
return $this;
}
示例11: __construct
public function __construct()
{
parent::__construct('translation:dump');
}
示例12: __construct
public function __construct()
{
parent::__construct('dependencies:all');
$this->setDescription('Installs all dependencies')->addOption('no-dev', 'd', InputOption::VALUE_NONE, 'Do not install dev dependencies')->addOption('prefer-source', 'p', InputOption::VALUE_NONE, 'Use the --prefer-source composer option')->addOption('clear-cache', null, InputOption::VALUE_NONE, 'If defined forces to clear the cache before installation');
}
示例13: __construct
/**
* Constructor
*/
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Builds subviews that previously failed to be generated / did not exist when records were added');
return $this;
}
示例14: __construct
/**
* Constructor
*/
public function __construct($name = null)
{
parent::__construct($name);
$this->setDescription('Creates a collection in Phraseanet')->setHelp('')->addArgument('databox_id', InputArgument::REQUIRED, 'The id of the databox where to create the collection', null)->addArgument('collname', InputArgument::REQUIRED, 'The name of the new collection', null)->addOption('base_id_rights', 'd', InputOption::VALUE_OPTIONAL, 'Duplicate rights from another collection', null);
return $this;
}
示例15: __construct
public function __construct()
{
parent::__construct('task-manager:scheduler:state');
$this->setDescription('Returns scheduler state')->addOption('short', null, InputOption::VALUE_NONE, 'print short result, ie: <info>stopped()</info> | <info>started(12345)</info> | <info>tostop(12345)</info> | <info>stopping(12345)</info>');
}