17 #ifndef HH_SENF_Packets_SafeIterator_ 18 #define HH_SENF_Packets_SafeIterator_ 1 20 #ifndef HH_SENF_Packets_Packets_ 21 #error "Don't include 'SafeIterator.hh' directly, include 'Packets.hh'" 25 #include <boost/iterator/iterator_facade.hpp> 33 class PacketParserBase;
48 :
public boost::iterator_facade< safe_data_iterator,
49 PacketData::value_type,
50 boost::random_access_traversal_tag >,
51 public senf::detail::packet::safe_data_iterator_base<PacketData::iterator>
53 typedef senf::detail::packet::safe_data_iterator_base<PacketData::iterator> Base;
78 friend class boost::iterator_core_access;
82 value_type & dereference()
const;
107 template <
class Parser>
109 :
public safe_bool< SafePacketParserWrapper<Parser> >
135 Parser * operator->()
const;
138 bool boolean_test()
const;
143 mutable boost::optional<Parser> parser_;
151 #if !defined(HH_SENF_Packets_Packets__decls_) && !defined(HH_SENF_Packets_SafeIterator_i_) 152 #define HH_SENF_Packets_SafeIterator_i_ safe_data_iterator & operator=(PacketData::iterator i)
Assign iterator.
unspecified_keyword_type parser
senf::detail::packet::iterator iterator
RestrictedInt< Base, Tag > operator*(OtherType a, RestrictedInt< Base, Tag > b)
Packet data STL-sequence view.
PacketData::size_type size_type
Re-validating data iterator.
PacketData & data() const
Access data container.
senf::detail::packet::size_type size_type
raw_container::difference_type difference_type
safe_data_iterator()
Make uninitialized iterator.
Iterator re-validating Parser wrapper.