Server IP : 162.213.251.212 / Your IP : 3.135.228.15 [ Web Server : LiteSpeed System : Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : allssztx ( 535) PHP Version : 8.1.31 Disable Function : NONE Domains : 1 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/allssztx/www/easybuyer/vendor/league/flysystem/src/Adapter/Polyfill/ |
Upload File : |
<?php namespace League\Flysystem\Adapter\Polyfill; use League\Flysystem\Config; trait StreamedCopyTrait { /** * Copy a file. * * @param string $path * @param string $newpath * * @return bool */ public function copy($path, $newpath) { $response = $this->readStream($path); if ($response === false || ! is_resource($response['stream'])) { return false; } $result = $this->writeStream($newpath, $response['stream'], new Config()); if ($result !== false && is_resource($response['stream'])) { fclose($response['stream']); } return $result !== false; } // Required abstract method /** * @param string $path * * @return resource */ abstract public function readStream($path); /** * @param string $path * @param resource $resource * @param Config $config * * @return resource */ abstract public function writeStream($path, $resource, Config $config); }