added endOffset()

This commit is contained in:
Martchus 2015-11-21 01:07:52 +01:00
parent d68a324275
commit 5a15d956e8
1 changed files with 10 additions and 0 deletions

View File

@ -161,6 +161,7 @@ public:
uint32 sizeLength() const;
uint64 dataOffset() const;
uint64 totalSize() const;
uint64 endOffset() const;
uint64 maxTotalSize() const;
implementationType* parent();
const implementationType* parent() const;
@ -410,6 +411,15 @@ inline uint64 GenericFileElement<ImplementationType>::totalSize() const
return headerSize() + dataSize();
}
/*!
* \brief Returns the offset of the first byte which doesn't belong to this element anymore.
*/
template <class ImplementationType>
inline uint64 GenericFileElement<ImplementationType>::endOffset() const
{
return startOffset() + totalSize();
}
/*!
* \brief Returns maximum total size.
*