ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
◀ ilDoc Overview
StreamHasher.php
Go to the documentation of this file.
1
<?php
2
3
namespace
League\Flysystem\Util
;
4
5
class
StreamHasher
6
{
10
private
$algo
;
11
17
public
function
__construct
(
$algo
)
18
{
19
$this->algo =
$algo
;
20
}
21
27
public
function
hash
($resource)
28
{
29
rewind($resource);
30
$context = hash_init($this->algo);
31
hash_update_stream($context, $resource);
32
fclose($resource);
33
34
return
hash_final($context);
35
}
36
}
League\Flysystem\Util\StreamHasher
Definition:
StreamHasher.php:5
League\Flysystem\Util\StreamHasher\__construct
__construct($algo)
StreamHasher constructor.
Definition:
StreamHasher.php:17
League\Flysystem\Util
Definition:
ContentListingFormatter.php:3
League\Flysystem\Util\StreamHasher\$algo
$algo
Definition:
StreamHasher.php:10
League\Flysystem\Util\StreamHasher\hash
hash($resource)
Definition:
StreamHasher.php:27
libs
composer
vendor
league
flysystem
src
Util
StreamHasher.php
Generated on Sat Jan 18 2025 19:01:05 for ILIAS by
1.8.13 (using
Doxyfile
)