Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package net.trustyuri.file;
 
 
public class FileHasher {
	public FileHasher() {
	}
		MessageDigest md = null;
		try {
			md = MessageDigest.getInstance("SHA-256");
catch (NoSuchAlgorithmException ex) {}
		DigestInputStream d = null;
		try {
			d = new DigestInputStream(inmd);
			while (d.read() != -1) {}
finally {
			d.close();
		}
		return . + TrustyUriUtils.getBase64(md.digest());
	}
New to GrepCode? Check out our FAQ X