Interface Checksum

  • All Known Implementing Classes:
    Crc32, Crc32c
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    @FunctionalInterface
    public interface Checksum
    An interface representing API to compute a data checksum.

    Note: Instances should be threadsafe and stateless.

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      int compute​(long address, int offset, int length)
      Computes a checksum based on the contents of a java.nio.DirectByteBuffer.
    • Method Detail

      • compute

        int compute​(long address,
                    int offset,
                    int length)
        Computes a checksum based on the contents of a java.nio.DirectByteBuffer.
        Parameters:
        address - of the buffer.
        offset - within the buffer to begin at.
        length - of the data to read.
        Returns:
        computed checksum value.