Java Platform 1.2

java.util.zip
Interface Checksum

All Known Implementing Classes:
Adler32, CRC32

public abstract interface Checksum

An interface representing a data checksum.


Method Summary
 long getValue()
          Returns the current checksum value.
 void reset()
          Resets the checksum to its initial value.
 void update(byte[] b, int off, int len)
          Updates the current checksum with the specified array of bytes.
 void update(int b)
          Updates the current checksum with the specified byte.
 

Method Detail

update

public void update(int b)
Updates the current checksum with the specified byte.

update

public void update(byte[] b,
                   int off,
                   int len)
Updates the current checksum with the specified array of bytes.

getValue

public long getValue()
Returns the current checksum value.

reset

public void reset()
Resets the checksum to its initial value.

Java Platform 1.2

Submit a bug or feature Version 1.2 of Java Platform API Specification
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1998 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.