Function hash_file
Source pub fn hash_file<P: AsRef<Path>>(
path: P,
algorithm: HashAlgorithm,
) -> Result<String>
Expand description
计算文件的哈希值
Calculate file hash
§Arguments / 参数
File path
Hash algorithm to use
§Returns
返回值
std::io::Result<String>
- 十六进制格式的哈希值
Hash value in hexadecimal format
§Errors
错误
- 如果文件无法打开或读取 / If the file cannot be opened or read