org.exoplatform.services.jcr.ext.artifact
Class CRCGenerator

java.lang.Object
  extended by org.exoplatform.services.jcr.ext.artifact.CRCGenerator

public class CRCGenerator
extends java.lang.Object

Created by The eXo Platform SAS.
Date: 21 Nov 2008

Version:
$Id: CheckSumGenerator.java
Author:
Dmytro Katayev

Constructor Summary
CRCGenerator()
           
 
Method Summary
static java.lang.String getChecksum(java.io.InputStream in, java.lang.String algo)
          Generates checksum for the InputStream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CRCGenerator

public CRCGenerator()
Method Detail

getChecksum

public static java.lang.String getChecksum(java.io.InputStream in,
                                           java.lang.String algo)
                                    throws java.security.NoSuchAlgorithmException,
                                           java.io.IOException
Generates checksum for the InputStream.

Parameters:
in - stream to generate CheckSum
algo - algorithm name
Returns:
hexadecimal string checksun representation
Throws:
java.security.NoSuchAlgorithmException
java.io.IOException


Copyright © 2012 eXo Platform SAS. All Rights Reserved.