summaryrefslogtreecommitdiff
path: root/cpp/sbuffer.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/sbuffer.hpp')
-rw-r--r--cpp/sbuffer.hpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/cpp/sbuffer.hpp b/cpp/sbuffer.hpp
index 37ede49..2651b58 100644
--- a/cpp/sbuffer.hpp
+++ b/cpp/sbuffer.hpp
@@ -62,6 +62,12 @@ public:
return sbuf->data;
}
+ const char* data() const
+ {
+ const msgpack_sbuffer* sbuf = static_cast<const msgpack_sbuffer*>(this);
+ return sbuf->data;
+ }
+
size_t size() const
{
const msgpack_sbuffer* sbuf = static_cast<const msgpack_sbuffer*>(this);