...

#
Package crc32

In the call graph viewer below, each node
is a function belonging to this package
and its children are the functions it
calls—perhaps dynamically.

The root nodes are the entry points of the
package: functions that may be called from
outside the package.
There may be non-exported or anonymous
functions among them if they are called
dynamically from another package.

Click a node to visit that function's source code.
From there you can visit its callers by
clicking its declaring `func`

token.

Functions may be omitted if they were
determined to be unreachable in the
particular programs or tests that were
analyzed.

## Constants

Predefined polynomials.

const (
IEEE = 0xedb88320
Castagnoli = 0x82f63b78
Koopman = 0xeb31d82e
)

The size of a CRC-32 checksum in bytes.

const Size = 4

## Variables

IEEETable is the table for the IEEE polynomial.

var IEEETable = simpleMakeTable(IEEE)

func Checksum(data []byte, tab *Table) uint32

Checksum returns the CRC-32 checksum of data
using the polynomial represented by the Table.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.

func ChecksumIEEE(data []byte) uint32

ChecksumIEEE returns the CRC-32 checksum of data
using the IEEE polynomial.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.

func New(tab *Table) hash.Hash32

New creates a new hash.Hash32 computing the CRC-32 checksum
using the polynomial represented by the Table.
Its Sum method will lay the value out in big-endian byte order.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.

func NewIEEE() hash.Hash32

NewIEEE creates a new hash.Hash32 computing the CRC-32 checksum
using the IEEE polynomial.
Its Sum method will lay the value out in big-endian byte order.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.

func Update(crc uint32, tab *Table, p []byte) uint32

Update returns the result of adding the bytes in p to the crc.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.

Table is a 256-word table representing the polynomial for efficient processing.

type Table [256]uint32

func MakeTable(poly uint32) *Table

MakeTable returns a Table constructed from the specified polynomial.
The contents of this Table must not be modified.

▾ Internal call graph

This viewer shows the portion of the internal call
graph of this package that is reachable from this function.
See the package's call
graph for more information.