public function ls(string $path = '') : array
    {
        return version_compare(PHP_VERSION, '7.2.0', '>=')
            ? $this->ls72($path)
            : $this->lsLegacy($path);

    }
public function ls(string $path = '') : array
    {
        return version_compare(PHP_VERSION, '7.2.0', '>=')
            ? $this->ls72($path)
            : $this->lsLegacy($path);

    }
public function ls ( string $ path = '' ) : array { return version_compare ( PHP_VERSION , '7.2.0' , '>=' ) ? $ this -> ls72 ( $ path ) : $ this -> lsLegacy ( $ path ) ; }
Return list of all files in directory.

@param  string $path
@return \SebastianFeldmann\Ftp\File[]
@throws \Exception
Return list of all files in directory .