public class CRC32
extends Object implements Checksum
| java.lang.Object | |
| ↳ | java.util.zip.CRC32 |
一个可用于计算数据流的CRC-32的类。
也可以看看:
Public constructors |
|
|---|---|
CRC32() 创建一个新的CRC32对象。 |
|
Public methods |
|
|---|---|
long |
getValue() 返回CRC-32值。 |
void |
reset() 将CRC-32重置为初始值。 |
void |
update(byte[] b) 用指定的字节数组更新CRC-32校验和。 |
void |
update(byte[] b, int off, int len) 用指定的字节数组更新CRC-32校验和。 |
void |
update(int b) 用指定字节(参数b的低8位)更新CRC-32校验和。 |
Inherited methods |
|
|---|---|
java.lang.Object
|
|
java.util.zip.Checksum
|
|
void update (byte[] b)
用指定的字节数组更新CRC-32校验和。
| Parameters | |
|---|---|
b |
byte: the array of bytes to update the checksum with |
void update (byte[] b,
int off,
int len)
用指定的字节数组更新CRC-32校验和。
| Parameters | |
|---|---|
b |
byte: the byte array to update the checksum with |
off |
int: the start offset of the data |
len |
int: the number of bytes to use for the update |
void update (int b)
用指定字节(参数b的低8位)更新CRC-32校验和。
| Parameters | |
|---|---|
b |
int: the byte to update the checksum with |