/** * @param $username * @param string $password * @param string $emailAddress */ public function __construct($username, $password = '', $emailAddress = '') { parent::__construct(); $this->username = $username; $this->password = $password; $this->emailAddress = $emailAddress; }
/** * @param $account * @param $hostname * @param $name */ public function __construct($hostname, Account $account, $name = '') { parent::__construct(); $this->account = $account; $this->hostname = $hostname; $this->name = $name; }
/** * @param Account $account * @param string $dbName * @param Host $host * @param int $dbPort */ public function __construct($dbName, Account $account, Host $host = NULL, $dbPort = 3306) { parent::__construct(); $this->dbName = $dbName; $this->account = $account; $this->host = $host; $this->port = $dbPort; }
/** * @param $id * @param $baseUrl * @param $baseUri * @param Account $account */ public function __construct($id, $baseUrl, $baseUri, Account $account) { parent::__construct(); // Set params $this->id = $id; $this->dir = new Dir(BUILD_WORKING_COPY_DIR . "/{$this->id}/"); $this->repoBaseUri = rtrim($baseUri, '/'); $this->repoBaseUrl = rtrim($baseUrl, '/'); $this->repoUrl = $this->repoBaseUrl . $this->repoBaseUri; $this->account = $account; }
/** * @param $dirName * @param Host $host */ public function __construct($dirName, Host $host = NULL) { parent::__construct(); // Establish if the path is a windows path or not $this->isWinDir = mb_substr($dirName, 1, 1) === ':'; $this->name = $dirName; // Try to clean up the path a bit if ($this->isWinDir) { $this->path = str_replace('/', '\\', $this->name); $this->path = preg_replace("/[\\\\]+/", '\\', $this->path); $this->path = trim($this->path, '\\') . '\\'; $this->separator = '\\'; } else { $this->path = str_replace('\\', '/', $this->name); $this->path = preg_replace('/[\\/]+/', '/', $this->path); $this->path = rtrim($this->path, '/') . '/'; $this->separator = '/'; } $this->host = $host; }