/** * Default Constructor. * * @param RODSAccount account iRODS account used for connection * @param string $path_str the path of this dir * @param boolean $verify whether verify if the path exsits * @param RODSDirStats $stats if the stats for this dir is already known, initilize it here. * @return a new ProdsDir */ public function __construct(RODSAccount &$account, $path_str, $verify = false, RODSDirStats $stats = NULL) { $this->position = 0; $this->stats = $stats; parent::__construct($account, $path_str); if ($verify === true) { if ($this->exists() === false) { throw new RODSException("Directory '{$this}' does not exist", 'PERR_PATH_DOES_NOT_EXISTS'); } } }
/** * The class constructor */ public function __construct(RODSAccount &$account, $path_str, $verify = false, RODSFileStats $stats = NULL) { $this->l1desc = -1; $this->stats = $stats; if ($path_str[strlen($path_str) - 1] == '/') { throw new RODSException("Invalid file name '{$path_str}' ", 'PERR_USER_INPUT_PATH_ERROR'); } parent::__construct($account, $path_str); if ($verify === true) { if ($this->exists() === false) { throw new RODSException("File '{$this}' does not exist", 'PERR_PATH_DOES_NOT_EXISTS'); } } }
public function __construct(RODSAccount &$account, $path_str) { parent::__construct($account, $path_str); }