An interface used to represent Checksum values in the Zip package.
More...
#include <src/main/decaf/util/zip/Checksum.h>
Public Member Functions |
virtual | ~Checksum () |
virtual long long | getValue () const =0 |
virtual void | reset ()=0 |
| Reset the checksum to its initial value.
|
virtual void | update (const std::vector< unsigned char > &buffer)=0 |
| Updates the current checksum with the specified vector of bytes.
|
virtual void | update (const std::vector< unsigned char > &buffer, int offset, int length)=0 |
| Updates the current checksum with the specified array of bytes.
|
virtual void | update (const unsigned char *buffer, int size, int offset, int length)=0 |
| Updates the current checksum with the specified array of bytes.
|
virtual void | update (int byte)=0 |
| Updates the current checksum with the specified byte value.
|
Detailed Description
An interface used to represent Checksum values in the Zip package.
- Since
- 1.0
Constructor & Destructor Documentation
virtual decaf::util::zip::Checksum::~Checksum |
( |
| ) |
|
|
virtual |
Member Function Documentation
virtual long long decaf::util::zip::Checksum::getValue |
( |
| ) |
const |
|
pure virtual |
virtual void decaf::util::zip::Checksum::reset |
( |
| ) |
|
|
pure virtual |
virtual void decaf::util::zip::Checksum::update |
( |
const std::vector< unsigned char > & |
buffer | ) |
|
|
pure virtual |
virtual void decaf::util::zip::Checksum::update |
( |
const std::vector< unsigned char > & |
buffer, |
|
|
int |
offset, |
|
|
int |
length |
|
) |
| |
|
pure virtual |
Updates the current checksum with the specified array of bytes.
- Parameters
-
buffer | The buffer to read the updated bytes from. |
offset | The position in the buffer to start reading. |
length | The amount of data to read from the byte buffer. |
- Exceptions
-
IndexOutOfBoundsException | if offset + length > size of the buffer. |
Implemented in decaf::util::zip::Adler32, and decaf::util::zip::CRC32.
virtual void decaf::util::zip::Checksum::update |
( |
const unsigned char * |
buffer, |
|
|
int |
size, |
|
|
int |
offset, |
|
|
int |
length |
|
) |
| |
|
pure virtual |
Updates the current checksum with the specified array of bytes.
- Parameters
-
buffer | The buffer to read the updated bytes from. |
size | The size of the passed buffer. |
offset | The position in the buffer to start reading. |
length | The amount of data to read from the byte buffer. |
- Exceptions
-
NullPointerException | if the passed buffer is NULL. |
IndexOutOfBoundsException | if offset + length > size of the buffer. |
Implemented in decaf::util::zip::Adler32, and decaf::util::zip::CRC32.
virtual void decaf::util::zip::Checksum::update |
( |
int |
byte | ) |
|
|
pure virtual |
The documentation for this class was generated from the following file: