bkcrack: Zip::Iterator Class Reference

bkcrack 1.8.1 Crack legacy zip encryption with Biham and Kocher's known plaintext attack.

Zip::Iterator Class Reference

Single-pass input iterator that reads successive Entry objects. More...

`#include <bkcrack/Zip.hpp>`

## Public Types
using | difference_type = std::ptrdiff_t
| Required types for iterators.
using | value_type = const Entry
| Required types for iterators.
using | pointer = const Entry*
| Required types for iterators.
using | reference = const Entry&
| Required types for iterators.
using | iterator_category = std::input_iterator_tag
| Required types for iterators.

## Public Member Functions
constexpr | Iterator () noexcept=default
| Construct end-of-stream iterator.
| Iterator (const Zip &archive)
auto | operator* () const -> const Entry &
| Get the current entry.
auto | operator-> () const -> const Entry *
| Access a member of the current entry.
auto | operator++ () -> Iterator &
| Read the next central directory record if any or assign end-of-stream iterator.
auto | operator++ (int) -> Iterator
| Read the next central directory record if any or assign end-of-stream iterator.
auto | operator== (const Zip::Iterator &other) const -> bool
| Test if iterators are equivalent, i.e. both are end-of-stream or both are valid.

## Detailed Description

Single-pass input iterator that reads successive Entry objects.

## Constructor & Destructor Documentation

## ◆ Iterator()

Zip::Iterator::Iterator | ( | const Zip & | archive | ) |
| explicit

Construct an iterator pointing to the beginning of the given archive's central directory, or end-of-stream iterator if the central directory is not found at the expected offset.

## Member Function Documentation

## ◆ operator*()

auto Zip::Iterator::operator* | ( |  | ) | const -> const Entry &
| inline

Get the current entry.

Precondition
  The iterator must be valid

## ◆ operator++() [1/2]

auto Zip::Iterator::operator++ | ( |  | ) | -> Iterator &

Read the next central directory record if any or assign end-of-stream iterator.

Precondition
  The iterator must be valid

## ◆ operator++() [2/2]

auto Zip::Iterator::operator++ | ( | int |  | ) | -> Iterator

Read the next central directory record if any or assign end-of-stream iterator.

Precondition
  The iterator must be valid

## ◆ operator->()

auto Zip::Iterator::operator-> | ( |  | ) | const -> const Entry *
| inline

Access a member of the current entry.

Precondition
  The iterator must be valid

The documentation for this class was generated from the following file:

- include/bkcrack/Zip.hpp