20 #ifndef TPIE_COMPRESSED_STREAM_POSITION_H
21 #define TPIE_COMPRESSED_STREAM_POSITION_H
74 friend class compressed_stream_base_p;
80 uint64_t m_readOffset;
96 std::numeric_limits<uint64_t>::max() - 1,
97 std::numeric_limits<uint64_t>::max() - 1);
104 : m_readOffset(std::numeric_limits<uint64_t>::max())
105 , m_offset(std::numeric_limits<uint64_t>::max())
112 : m_readOffset(readOffset)
117 stream_size_type read_offset()
const {
130 void advance_items(memory_size_type
offset) {
134 void advance_item() {
140 return m_readOffset == other.m_readOffset
141 && m_offset == other.m_offset;
145 return !(*
this == other);
154 return (m_offset != other.m_offset)
155 ? (m_offset < other.m_offset)
156 : (m_readOffset < other.m_readOffset);
159 friend std::ostream & operator<<(std::ostream & s,
const stream_position & p) {
160 return s <<
"(" << p.read_offset() <<
"," << p.
offset() <<
")";
166 #endif // TPIE_COMPRESSED_STREAM_POSITION_H