aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/buffer_event.h21
-rw-r--r--include/utility.h13
2 files changed, 34 insertions, 0 deletions
diff --git a/include/buffer_event.h b/include/buffer_event.h
new file mode 100644
index 0000000..960b576
--- /dev/null
+++ b/include/buffer_event.h
@@ -0,0 +1,21 @@
+/* LuaEvent - Copyright (C) 2007 Thomas Harning <harningt@gmail.com>
+ * Licensed as LGPL - See doc/COPYING for details */
+ #ifndef BUFFER_EVENT_H
+ #define BUFFER_EVENT_H
+
+#include "luaevent.h"
+#include <lua.h>
+#include <sys/types.h>
+#include <sys/time.h>
+#include <event.h>
+
+typedef struct {
+ struct bufferevent* ev;
+ le_base* base;
+} le_bufferevent;
+
+int buffer_event_register(lua_State* L);
+int is_buffer_event(lua_State* L, int idx);
+le_bufferevent* buffer_event_check(lua_State* L, int idx);
+
+#endif
diff --git a/include/utility.h b/include/utility.h
new file mode 100644
index 0000000..f5afcfc
--- /dev/null
+++ b/include/utility.h
@@ -0,0 +1,13 @@
+/* LuaEvent - Copyright (C) 2007 Thomas Harning <harningt@gmail.com>
+ * Licensed as LGPL - See doc/COPYING for details */
+#ifndef UTILITY_H
+#define UTILITY_H
+
+#include <lua.h>
+
+void le_weak_ref(lua_State* L, void* ptr, int idx);
+void le_weak_unref(lua_State* L, void* ptr);
+void le_weak_get(lua_State* L, void* ptr);
+
+void le_register_utility(lua_State* L);
+#endif