2 // Copyright (c) 2020 Fraunhofer Institute for Applied Information Technology (FIT)
3 // Network Research Group (NET)
4 // Schloss Birlinghoven, 53754 Sankt Augustin, GERMANY
5 // Contact: support@wiback.org
7 // This file is part of the SENF code tree.
8 // It is licensed under the 3-clause BSD License (aka New BSD License).
9 // See LICENSE.txt in the top level directory for details or visit
10 // https://opensource.org/licenses/BSD-3-Clause
15 \brief SafeIterator inline template implementation */
17 #include "SafeIterator.ih"
21 #define prefix_ inline
22 //-/////////////////////////////////////////////////////////////////////////////////////////////////
24 //-/////////////////////////////////////////////////////////////////////////////////////////////////
25 // senf::SafePacketParserWrapper<Parser>
27 template <class Parser>
28 prefix_ senf::SafePacketParserWrapper<Parser>::SafePacketParserWrapper()
32 template <class Parser>
33 prefix_ senf::SafePacketParserWrapper<Parser>::SafePacketParserWrapper(Parser parser)
34 : parser_(parser), i_(parser)
37 template <class Parser>
38 prefix_ senf::SafePacketParserWrapper<Parser> & senf::SafePacketParserWrapper<Parser>::operator=(Parser parser)
45 template <class Parser>
46 prefix_ Parser & senf::SafePacketParserWrapper<Parser>::operator*()
49 SENF_ASSERT( i_, "Dereferencing empty SafePacketParserWrapper" );
50 parser_->i_ = PacketParserBase::data_iterator(i_);
54 template <class Parser>
55 prefix_ Parser * senf::SafePacketParserWrapper<Parser>::operator->()
58 SENF_ASSERT( i_, "Dereferencing empty SafePacketParserWrapper" );
59 parser_->i_ = PacketParserBase::data_iterator(i_);
63 template <class Parser>
64 prefix_ bool senf::SafePacketParserWrapper<Parser>::boolean_test()
70 //-/////////////////////////////////////////////////////////////////////////////////////////////////
78 // c-file-style: "senf"
79 // indent-tabs-mode: nil
80 // ispell-local-dictionary: "american"
81 // compile-command: "scons -u test"