32 class Iterator final {
33 using Base = std::conditional_t<Const,
const Value, Value>;
34 using RawIterator =
decltype(std::declval<Base&>().begin());
37 using iterator_category = std::forward_iterator_tag;
38 using difference_type = std::ptrdiff_t;
39 using value_type = ItemsWrapperValue<Base>;
40 using reference = value_type;
44 explicit Iterator(RawIterator it)
49 Iterator(
const Iterator& other) =
default;
50 Iterator(Iterator&& other)
noexcept =
default;
52 Iterator& operator=(
const Iterator& other) =
default;
53 Iterator& operator=(Iterator&& other)
noexcept =
default;
55 reference operator*()
const {
return {it_.GetName(), *it_}; }
57 Iterator operator++(
int) {
63 Iterator& operator++() {
68 bool operator==(
const Iterator& other)
const {
return it_ == other.it_; }
70 bool operator!=(
const Iterator& other)
const {
return !(*
this == other); }