Get an MD5 checksum of the stream's contents
bool $rawOutput Whether or not to use raw output:
bool $base64Encode Whether or not to base64 encode raw output (only if raw output is true):
bool|string Returns an MD5 string on success or FALSE on failure
Overrides EntityBodyInterface::getContentMd5
public function getContentMd5($rawOutput = false, $base64Encode = false) {
$hash = self::getHash($this, 'md5', $rawOutput);
return $hash && $base64Encode ? base64_encode($hash) : $hash;
}