Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
9847b8bf
Commit
9847b8bf
authored
Jan 07, 2012
by
Denis Bilenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core.async: add send() method and 'sent' property
parent
24b559f8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
0 deletions
+9
-0
gevent/core.ppyx
gevent/core.ppyx
+7
-0
gevent/libev.pxd
gevent/libev.pxd
+2
-0
No files found.
gevent/core.ppyx
View file @
9847b8bf
...
@@ -747,6 +747,13 @@ cdef public class async(watcher) [object PyGeventAsyncObject, type PyGeventAsync
...
@@ -747,6 +747,13 @@ cdef public class async(watcher) [object PyGeventAsyncObject, type PyGeventAsync
INIT(async,,)
INIT(async,,)
def send(self):
libev.ev_async_send(self.loop._ptr, &self._watcher)
@property
def sent(self):
return libev.ev_async_pending(&self._watcher)
#cdef public class child(watcher) [object PyGeventChildObject, type PyGeventChild_Type]:
#cdef public class child(watcher) [object PyGeventChildObject, type PyGeventChild_Type]:
#
#
...
...
gevent/libev.pxd
View file @
9847b8bf
...
@@ -131,6 +131,8 @@ cdef extern from "libev.h":
...
@@ -131,6 +131,8 @@ cdef extern from "libev.h":
void
ev_async_init
(
ev_async
*
,
void
*
callback
)
void
ev_async_init
(
ev_async
*
,
void
*
callback
)
void
ev_async_start
(
ev_loop
*
,
ev_async
*
)
void
ev_async_start
(
ev_loop
*
,
ev_async
*
)
void
ev_async_stop
(
ev_loop
*
,
ev_async
*
)
void
ev_async_stop
(
ev_loop
*
,
ev_async
*
)
void
ev_async_send
(
ev_loop
*
,
ev_async
*
)
int
ev_async_pending
(
ev_async
*
)
void
ev_child_init
(
ev_child
*
,
void
*
callback
,
int
,
int
)
void
ev_child_init
(
ev_child
*
,
void
*
callback
,
int
,
int
)
void
ev_child_start
(
ev_loop
*
,
ev_child
*
)
void
ev_child_start
(
ev_loop
*
,
ev_child
*
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment