Class CRCGenerator
- java.lang.Object
-
- org.exoplatform.services.jcr.ext.artifact.CRCGenerator
-
public class CRCGenerator extends Object
Created by The eXo Platform SAS.
Date: 21 Nov 2008- Version:
- $Id: CheckSumGenerator.java
- Author:
- Dmytro Katayev
-
-
Constructor Summary
Constructors Constructor Description CRCGenerator()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringgetChecksum(InputStream in, String algo)Generates checksum for the InputStream.
-
-
-
Method Detail
-
getChecksum
public static String getChecksum(InputStream in, String algo) throws NoSuchAlgorithmException, IOException
Generates checksum for the InputStream.- Parameters:
in- stream to generate CheckSumalgo- algorithm name according to the <a href= "http://java.sun.com/j2se/1.4.2/docs/guide/security/CryptoSpec.html#AppA"> Java Cryptography Architecture API Specification & Reference </a>- Returns:
- hexadecimal string checksun representation
- Throws:
NoSuchAlgorithmExceptionIOException
-
-