com.esf.util.algorithm.crc
Class Crc16

java.lang.Object
  extended bycom.esf.util.algorithm.crc.Crc16

public class Crc16
extends java.lang.Object

Used to calculate the CRC-16 (cyclical redundancy check) for an array of bytes.


Method Summary
static int getCrc16(byte[] buff, int buffLen, int crcSeed)
          calculate the crc for the passed buffer
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getCrc16

public static int getCrc16(byte[] buff,
                           int buffLen,
                           int crcSeed)
calculate the crc for the passed buffer

Parameters:
buff - byte array to calculate CRC of
buffLen - number of bytes in array to calculate against
crcSeed - starting seed for CRC calculation
Returns:
CRC16 as calculated for buff


Copyright © 2009 Eurotech Inc. All rights reserved.