aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkStream.h
diff options
context:
space:
mode:
authorGravatar Ben Wagner <bungeman@google.com>2016-12-16 16:51:41 +0000
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2016-12-16 19:02:53 +0000
commit884300dca5531f60535501424bbd86b30e20450a (patch)
treebd55d2a075890c222fc70dda7043ddfc08967491 /include/core/SkStream.h
parent9f67f044dd8765184669af6fd38e7feeff8777f9 (diff)
Remove SkDynamicMemoryWStream::getOffset.
This method does the same thing as ::bytesWritten but has a confusing name. It appears there are no external users, so remove it. Change-Id: I06aed269200c34c2dda36605092f8ea37fcec693 Reviewed-on: https://skia-review.googlesource.com/6188 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
Diffstat (limited to 'include/core/SkStream.h')
-rw-r--r--include/core/SkStream.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/include/core/SkStream.h b/include/core/SkStream.h
index e6df9eabde..83eee4708b 100644
--- a/include/core/SkStream.h
+++ b/include/core/SkStream.h
@@ -385,16 +385,14 @@ public:
bool write(const void* buffer, size_t size) override;
size_t bytesWritten() const override;
- bool read(void* buffer, size_t offset, size_t size);
- // Why do we have this as a separate method???
- size_t getOffset() const { return this->bytesWritten(); }
+ bool read(void* buffer, size_t offset, size_t size);
- // copy what has been written to the stream into dst
+ /** More efficient version of read(dst, 0, bytesWritten()). */
void copyTo(void* dst) const;
void writeToStream(SkWStream* dst) const;
- // Return the contents as SkData, and then reset the stream.
+ /** Return the contents as SkData, and then reset the stream. */
sk_sp<SkData> detachAsData();
/** Reset, returning a reader stream with the current content. */