summaryrefslogtreecommitdiff
path: root/src/node_buffer.h
diff options
context:
space:
mode:
authorRyan Dahl <ry@tinyclouds.org>2010-10-26 13:43:58 -0700
committerRyan Dahl <ry@tinyclouds.org>2010-10-26 13:43:58 -0700
commitdcc4fffe4dc7ccec3db2d1b55ab3a42a492a0c98 (patch)
treebc4b95bc193f5f7943c5689c4ee90123ba29af8b /src/node_buffer.h
parentd1e5fbdde4d08efa6656a0df3bd9546030b80f1e (diff)
downloadandroid-node-v8-dcc4fffe4dc7ccec3db2d1b55ab3a42a492a0c98.tar.gz
android-node-v8-dcc4fffe4dc7ccec3db2d1b55ab3a42a492a0c98.tar.bz2
android-node-v8-dcc4fffe4dc7ccec3db2d1b55ab3a42a492a0c98.zip
Add C++ API for constructing fast buffer from string
Diffstat (limited to 'src/node_buffer.h')
-rw-r--r--src/node_buffer.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/node_buffer.h b/src/node_buffer.h
index 3221417f2f..47b9961e45 100644
--- a/src/node_buffer.h
+++ b/src/node_buffer.h
@@ -24,6 +24,9 @@ class Buffer : public ObjectWrap {
typedef void (*free_callback)(char *data, void *hint);
+ // C++ API for constructing fast buffer
+ static v8::Handle<v8::Object> New(v8::Handle<v8::String> string);
+
static void Initialize(v8::Handle<v8::Object> target);
static Buffer* New(size_t length); // public constructor
static Buffer* New(char *data, size_t len); // public constructor