… | |
… | |
1220 | |
1220 | |
1221 | The current reschedule callback, or C<0>, if this functionality is |
1221 | The current reschedule callback, or C<0>, if this functionality is |
1222 | switched off. Can be changed any time, but changes only take effect when |
1222 | switched off. Can be changed any time, but changes only take effect when |
1223 | the periodic timer fires or C<ev_periodic_again> is being called. |
1223 | the periodic timer fires or C<ev_periodic_again> is being called. |
1224 | |
1224 | |
|
|
1225 | =item ev_tstamp at [read-only] |
|
|
1226 | |
|
|
1227 | When active, contains the absolute time that the watcher is supposed to |
|
|
1228 | trigger next. |
|
|
1229 | |
1225 | =back |
1230 | =back |
1226 | |
1231 | |
1227 | Example: Call a callback every hour, or, more precisely, whenever the |
1232 | Example: Call a callback every hour, or, more precisely, whenever the |
1228 | system clock is divisible by 3600. The callback invocation times have |
1233 | system clock is divisible by 3600. The callback invocation times have |
1229 | potentially a lot of jittering, but good long-term stability. |
1234 | potentially a lot of jittering, but good long-term stability. |
… | |
… | |
2019 | |
2024 | |
2020 | =item w->stop () |
2025 | =item w->stop () |
2021 | |
2026 | |
2022 | Stops the watcher if it is active. Again, no C<loop> argument. |
2027 | Stops the watcher if it is active. Again, no C<loop> argument. |
2023 | |
2028 | |
2024 | =item w->again () C<ev::timer>, C<ev::periodic> only |
2029 | =item w->again () (C<ev::timer>, C<ev::periodic> only) |
2025 | |
2030 | |
2026 | For C<ev::timer> and C<ev::periodic>, this invokes the corresponding |
2031 | For C<ev::timer> and C<ev::periodic>, this invokes the corresponding |
2027 | C<ev_TYPE_again> function. |
2032 | C<ev_TYPE_again> function. |
2028 | |
2033 | |
2029 | =item w->sweep () C<ev::embed> only |
2034 | =item w->sweep () (C<ev::embed> only) |
2030 | |
2035 | |
2031 | Invokes C<ev_embed_sweep>. |
2036 | Invokes C<ev_embed_sweep>. |
2032 | |
2037 | |
2033 | =item w->update () C<ev::stat> only |
2038 | =item w->update () (C<ev::stat> only) |
2034 | |
2039 | |
2035 | Invokes C<ev_stat_stat>. |
2040 | Invokes C<ev_stat_stat>. |
2036 | |
2041 | |
2037 | =back |
2042 | =back |
2038 | |
2043 | |
… | |
… | |
2058 | } |
2063 | } |
2059 | |
2064 | |
2060 | |
2065 | |
2061 | =head1 MACRO MAGIC |
2066 | =head1 MACRO MAGIC |
2062 | |
2067 | |
2063 | Libev can be compiled with a variety of options, the most fundemantal is |
2068 | Libev can be compiled with a variety of options, the most fundamantal |
2064 | C<EV_MULTIPLICITY>. This option determines whether (most) functions and |
2069 | of which is C<EV_MULTIPLICITY>. This option determines whether (most) |
2065 | callbacks have an initial C<struct ev_loop *> argument. |
2070 | functions and callbacks have an initial C<struct ev_loop *> argument. |
2066 | |
2071 | |
2067 | To make it easier to write programs that cope with either variant, the |
2072 | To make it easier to write programs that cope with either variant, the |
2068 | following macros are defined: |
2073 | following macros are defined: |
2069 | |
2074 | |
2070 | =over 4 |
2075 | =over 4 |