17 #ifndef SCIP2_DECODE_H 18 #define SCIP2_DECODE_H 46 const std::string::const_iterator
begin_;
47 const std::string::const_iterator
end_;
54 std::string::const_iterator
pos_;
55 std::string::const_iterator
end_;
60 const std::string::const_iterator& pos,
61 const std::string::const_iterator& end,
70 return pos_ == it.
pos_;
74 return !operator==(it);
78 pos_ += L - remain_.
chars_;
95 std::string::const_iterator pos(pos_);
96 uint64_t buf(remain_.
buf_);
97 for (
size_t i = 0; i < L - remain_.
chars_; ++i)
102 buf |= (
static_cast<uint8_t
>(*pos) - 0x30);
110 : begin_(line.begin())
117 return Iterator(begin_, end_, remain_);
126 for (std::string::const_iterator it = begin_; it != end_; ++it)
135 #endif // SCIP2_DECODE_H
uint8_t getChecksum() const
const std::string::const_iterator begin_
bool operator!=(const Iterator &it) const
std::string::const_iterator pos_
bool operator==(const Iterator &it) const
std::string::const_iterator end_
const DecoderRemain remain_
DecoderRemain(const uint64_t &buf, const uint32_t &chars)
Decoder(const std::string &line, const DecoderRemain &remain=DecoderRemain())
const std::string::const_iterator end_
DecoderRemain getRemain() const
const uint64_t operator*()
Iterator(const std::string::const_iterator &pos, const std::string::const_iterator &end, const DecoderRemain &remain=DecoderRemain())