コード例 #1
0
ファイル: Mongodump.php プロジェクト: imjerrybao/phpbu
 /**
  * Fetch databases and collections to backup.
  *
  * @param array $conf
  */
 protected function setupSourceData(array $conf)
 {
     $this->databases = Util\Str::toList(Util\Arr::getValue($conf, 'databases'));
     $this->collections = Util\Str::toList(Util\Arr::getValue($conf, 'collections'));
     $this->excludeCollections = Util\Str::toList(Util\Arr::getValue($conf, 'excludeCollections'));
     $this->excludeCollectionsWithPrefix = Util\Str::toList(Util\Arr::getValue($conf, 'excludeCollectionsWithPrefix'));
 }
コード例 #2
0
ファイル: XtraBackup.php プロジェクト: todiadiyatmo/phpbu
 /**
  * Get tables and databases to backup.
  *
  * @param array $conf
  */
 protected function setupSourceData(array $conf)
 {
     $this->include = Util\Arr::getValue($conf, 'include');
     $this->databases = Util\Str::toList(Util\Arr::getValue($conf, 'databases'));
 }
コード例 #3
0
ファイル: Rsync.php プロジェクト: todiadiyatmo/phpbu
 /**
  * (non-PHPDoc)
  *
  * @see    \phpbu\App\Backup\Sync::setup()
  * @param  array $options
  * @throws \phpbu\App\Backup\Sync\Exception
  */
 public function setup(array $options)
 {
     $this->pathToRsync = Util\Arr::getValue($options, 'pathToRsync');
     if (Util\Arr::isSetAndNotEmptyString($options, 'args')) {
         $this->args = $options['args'];
     } else {
         if (!Util\Arr::isSetAndNotEmptyString($options, 'path')) {
             throw new Exception('option \'path\' is missing');
         }
         $this->path = Util\Str::replaceDatePlaceholders($options['path']);
         if (Util\Arr::isSetAndNotEmptyString($options, 'user')) {
             $this->user = $options['user'];
         }
         if (Util\Arr::isSetAndNotEmptyString($options, 'host')) {
             $this->host = $options['host'];
         }
         $this->excludes = Util\Str::toList(Util\Arr::getValue($options, 'exclude', ''), ':');
         $this->delete = Util\Str::toBoolean(Util\Arr::getValue($options, 'delete', ''), false);
         $this->isDirSync = Util\Str::toBoolean(Util\Arr::getValue($options, 'dirsync', ''), false);
     }
 }
コード例 #4
0
ファイル: Mysqldump.php プロジェクト: Rahul-Giri/phpbu
 /**
  * Get tables and databases to backup.
  *
  * @param array $conf
  */
 protected function setupSourceData(array $conf)
 {
     $this->tables = Util\Str::toList(Util\Arr::getValue($conf, 'tables'));
     $this->databases = Util\Str::toList(Util\Arr::getValue($conf, 'databases'));
     $this->ignoreTables = Util\Str::toList(Util\Arr::getValue($conf, 'ignoreTables'));
     $this->structureOnly = Util\Str::toList(Util\Arr::getValue($conf, 'structureOnly'));
 }
コード例 #5
0
ファイル: Arangodump.php プロジェクト: imjerrybao/phpbu
 /**
  * Get collections and data to backup.
  *
  * @param array $conf
  */
 protected function setupSourceData(array $conf)
 {
     $this->dumpData = Util\Str::toBoolean(Util\Arr::getValue($conf, 'dumpData'), false);
     $this->includeSystemCollections = Util\Str::toBoolean(Util\Arr::getValue($conf, 'includeSystemCollections'), false);
     $this->collections = Util\Str::toList(Util\Arr::getValue($conf, 'collections'));
 }