ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/EV/EV.xs
(Generate patch)

Comparing EV/EV.xs (file contents):
Revision 1.144 by root, Sun Oct 24 17:58:41 2010 UTC vs.
Revision 1.146 by root, Sun Oct 24 20:05:43 2010 UTC

120 *stash_idle, 120 *stash_idle,
121 *stash_prepare, 121 *stash_prepare,
122 *stash_check, 122 *stash_check,
123 *stash_embed, 123 *stash_embed,
124 *stash_fork, 124 *stash_fork,
125 *stash_cleanup,
125 *stash_async; 126 *stash_async;
126 127
127///////////////////////////////////////////////////////////////////////////// 128/////////////////////////////////////////////////////////////////////////////
128// Event 129// Event
129 130
374 const_iv (EV_, IDLE) 375 const_iv (EV_, IDLE)
375 const_iv (EV_, PREPARE) 376 const_iv (EV_, PREPARE)
376 const_iv (EV_, CHECK) 377 const_iv (EV_, CHECK)
377 const_iv (EV_, EMBED) 378 const_iv (EV_, EMBED)
378 const_iv (EV_, FORK) 379 const_iv (EV_, FORK)
380 const_iv (EV_, CLEANUP)
379 const_iv (EV_, ASYNC) 381 const_iv (EV_, ASYNC)
380 const_iv (EV_, CUSTOM) 382 const_iv (EV_, CUSTOM)
381 const_iv (EV_, ERROR) 383 const_iv (EV_, ERROR)
382 384
383 const_iv (EV, RUN_NOWAIT) 385 const_iv (EV, RUN_NOWAIT)
428 stash_check = gv_stashpv ("EV::Check" , 1); 430 stash_check = gv_stashpv ("EV::Check" , 1);
429 stash_child = gv_stashpv ("EV::Child" , 1); 431 stash_child = gv_stashpv ("EV::Child" , 1);
430 stash_embed = gv_stashpv ("EV::Embed" , 1); 432 stash_embed = gv_stashpv ("EV::Embed" , 1);
431 stash_stat = gv_stashpv ("EV::Stat" , 1); 433 stash_stat = gv_stashpv ("EV::Stat" , 1);
432 stash_fork = gv_stashpv ("EV::Fork" , 1); 434 stash_fork = gv_stashpv ("EV::Fork" , 1);
435 stash_cleanup = gv_stashpv ("EV::Cleanup" , 1);
433 stash_async = gv_stashpv ("EV::Async" , 1); 436 stash_async = gv_stashpv ("EV::Async" , 1);
434 437
435 { 438 {
436 SV *sv = perl_get_sv ("EV::API", TRUE); 439 SV *sv = perl_get_sv ("EV::API", TRUE);
437 perl_get_sv ("EV::API", TRUE); /* silence 5.10 warning */ 440 perl_get_sv ("EV::API", TRUE); /* silence 5.10 warning */
494 evapi.embed_start = ev_embed_start; 497 evapi.embed_start = ev_embed_start;
495 evapi.embed_stop = ev_embed_stop; 498 evapi.embed_stop = ev_embed_stop;
496 evapi.embed_sweep = ev_embed_sweep; 499 evapi.embed_sweep = ev_embed_sweep;
497 evapi.fork_start = ev_fork_start; 500 evapi.fork_start = ev_fork_start;
498 evapi.fork_stop = ev_fork_stop; 501 evapi.fork_stop = ev_fork_stop;
502 evapi.cleanup_start = ev_cleanup_start;
503 evapi.cleanup_stop = ev_cleanup_stop;
499 evapi.async_start = ev_async_start; 504 evapi.async_start = ev_async_start;
500 evapi.async_stop = ev_async_stop; 505 evapi.async_stop = ev_async_stop;
501 evapi.async_send = ev_async_send; 506 evapi.async_send = ev_async_send;
502 evapi.clear_pending = ev_clear_pending; 507 evapi.clear_pending = ev_clear_pending;
503 evapi.invoke = ev_invoke; 508 evapi.invoke = ev_invoke;
713 ev_fork_set (RETVAL); 718 ev_fork_set (RETVAL);
714 if (!ix) START (fork, RETVAL); 719 if (!ix) START (fork, RETVAL);
715 OUTPUT: 720 OUTPUT:
716 RETVAL 721 RETVAL
717 722
723ev_cleanup *cleanup (SV *cb)
724 ALIAS:
725 cleanup_ns = 1
726 CODE:
727 RETVAL = e_new (sizeof (ev_cleanup), cb, default_loop_sv);
728 ev_cleanup_set (RETVAL);
729 if (!ix) START (cleanup, RETVAL);
730 OUTPUT:
731 RETVAL
718 732
719ev_child *child (int pid, int trace, SV *cb) 733ev_child *child (int pid, int trace, SV *cb)
720 ALIAS: 734 ALIAS:
721 child_ns = 1 735 child_ns = 1
722 CODE: 736 CODE:
1102 1116
1103void DESTROY (ev_fork *w) 1117void DESTROY (ev_fork *w)
1104 CODE: 1118 CODE:
1105 STOP (fork, w); 1119 STOP (fork, w);
1106 e_destroy (w); 1120 e_destroy (w);
1121
1122MODULE = EV PACKAGE = EV::Cleanup PREFIX = ev_cleanup_
1123
1124void ev_cleanup_start (ev_cleanup *w)
1125 CODE:
1126 START (cleanup, w);
1127
1128void ev_cleanup_stop (ev_cleanup *w)
1129 CODE:
1130 STOP (cleanup, w);
1131
1132void DESTROY (ev_cleanup *w)
1133 CODE:
1134 STOP (cleanup, w);
1135 e_destroy (w);
1136
1137int keepalive (ev_watcher *w, int new_value = 0)
1138 CODE:
1139 RETVAL = 0;
1140 OUTPUT:
1141 RETVAL
1107 1142
1108MODULE = EV PACKAGE = EV::Child PREFIX = ev_child_ 1143MODULE = EV PACKAGE = EV::Child PREFIX = ev_child_
1109 1144
1110#if EV_CHILD_ENABLE 1145#if EV_CHILD_ENABLE
1111 1146
1463 ev_fork_set (RETVAL); 1498 ev_fork_set (RETVAL);
1464 if (!ix) START (fork, RETVAL); 1499 if (!ix) START (fork, RETVAL);
1465 OUTPUT: 1500 OUTPUT:
1466 RETVAL 1501 RETVAL
1467 1502
1503ev_cleanup *cleanup (struct ev_loop *loop, SV *cb)
1504 ALIAS:
1505 cleanup_ns = 1
1506 CODE:
1507 RETVAL = e_new (sizeof (ev_cleanup), cb, ST (0));
1508 ev_cleanup_set (RETVAL);
1509 if (!ix) START (cleanup, RETVAL);
1510 OUTPUT:
1511 RETVAL
1468 1512
1469ev_child *child (struct ev_loop *loop, int pid, int trace, SV *cb) 1513ev_child *child (struct ev_loop *loop, int pid, int trace, SV *cb)
1470 ALIAS: 1514 ALIAS:
1471 child_ns = 1 1515 child_ns = 1
1472 CODE: 1516 CODE:

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines