diff options
author | crupest <crupest@outlook.com> | 2022-02-03 14:55:17 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2022-02-03 14:55:17 +0800 |
commit | d15172cfe1ac8558567c1b1c10c2e671b0d1f033 (patch) | |
tree | 44eb3f6c760bc4a30786c4716a3c70d2b4b4c28e /src/common/io/Stream.cpp | |
parent | 2cf2f297c00ad262ddcbe56d38fdd45dffb7e342 (diff) | |
download | cru-d15172cfe1ac8558567c1b1c10c2e671b0d1f033.tar.gz cru-d15172cfe1ac8558567c1b1c10c2e671b0d1f033.tar.bz2 cru-d15172cfe1ac8558567c1b1c10c2e671b0d1f033.zip |
...
Diffstat (limited to 'src/common/io/Stream.cpp')
-rw-r--r-- | src/common/io/Stream.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/common/io/Stream.cpp b/src/common/io/Stream.cpp index 4f2953f9..ad1dbd0e 100644 --- a/src/common/io/Stream.cpp +++ b/src/common/io/Stream.cpp @@ -1,7 +1,9 @@ #include "cru/common/io/Stream.hpp" namespace cru::io { -void Stream::Rewind() { Seek(0); } +Index Stream::Tell() { return Seek(0, SeekOrigin::Current); } + +void Stream::Rewind() { Seek(0, SeekOrigin::Begin); } Index Stream::GetSize() { Index current_position = Tell(); |