calculateHash function

Digest calculateHash(
  1. String path
)

Calculates the sha256 hash of a file's content.

This is likely to be an expensive operation if the file is large.

You can use this method to check if a file has changes since the last time you took the file's hash.

Throws FileNotFoundException if path doesn't exist. Throws NotAFileException if path is not a file.

Implementation

// ignore: discarded_futures
Digest calculateHash(String path) => waitForEx(core.calculateHash(path));