… | |
… | |
46 | in a tutorial or some gentle introduction, have a look at the |
46 | in a tutorial or some gentle introduction, have a look at the |
47 | L<AnyEvent::Intro> manpage. |
47 | L<AnyEvent::Intro> manpage. |
48 | |
48 | |
49 | =head1 SUPPORT |
49 | =head1 SUPPORT |
50 | |
50 | |
|
|
51 | An FAQ document is available as L<AnyEvent::FAQ>. |
|
|
52 | |
51 | There is a mailinglist for discussing all things AnyEvent, and an IRC |
53 | There also is a mailinglist for discussing all things AnyEvent, and an IRC |
52 | channel, too. |
54 | channel, too. |
53 | |
55 | |
54 | See the AnyEvent project page at the B<Schmorpforge Ta-Sa Software |
56 | See the AnyEvent project page at the B<Schmorpforge Ta-Sa Software |
55 | Repository>, at L<http://anyevent.schmorp.de>, for more info. |
57 | Repository>, at L<http://anyevent.schmorp.de>, for more info. |
56 | |
58 | |
… | |
… | |
1165 | |
1167 | |
1166 | BEGIN { AnyEvent::common_sense } |
1168 | BEGIN { AnyEvent::common_sense } |
1167 | |
1169 | |
1168 | use Carp (); |
1170 | use Carp (); |
1169 | |
1171 | |
1170 | our $VERSION = '5.271'; |
1172 | our $VERSION = '5.29'; |
1171 | our $MODEL; |
1173 | our $MODEL; |
1172 | |
1174 | |
1173 | our $AUTOLOAD; |
1175 | our $AUTOLOAD; |
1174 | our @ISA; |
1176 | our @ISA; |
1175 | |
1177 | |
… | |
… | |
1289 | last; |
1291 | last; |
1290 | } |
1292 | } |
1291 | } |
1293 | } |
1292 | |
1294 | |
1293 | $MODEL |
1295 | $MODEL |
1294 | or die "No event module selected for AnyEvent and autodetect failed. Install any one of these modules: EV, Event or Glib.\n"; |
1296 | or die "AnyEvent: backend autodetection failed - did you properly install AnyEvent?\n"; |
1295 | } |
1297 | } |
1296 | } |
1298 | } |
1297 | |
1299 | |
1298 | @models = (); # free probe data |
1300 | @models = (); # free probe data |
1299 | |
1301 | |
1300 | push @{"$MODEL\::ISA"}, "AnyEvent::Base"; |
1302 | push @{"$MODEL\::ISA"}, "AnyEvent::Base"; |
1301 | unshift @ISA, $MODEL; |
1303 | unshift @ISA, $MODEL; |
1302 | |
1304 | |
1303 | # now nuke some methods that are overriden by the backend. |
1305 | # now nuke some methods that are overridden by the backend. |
1304 | # SUPER is not allowed. |
1306 | # SUPER is not allowed. |
1305 | for (qw(time signal child idle)) { |
1307 | for (qw(time signal child idle)) { |
1306 | undef &{"AnyEvent::Base::$_"} |
1308 | undef &{"AnyEvent::Base::$_"} |
1307 | if defined &{"$MODEL\::$_"}; |
1309 | if defined &{"$MODEL\::$_"}; |
1308 | } |
1310 | } |
1309 | |
1311 | |
1310 | require AnyEvent::Strict if $ENV{PERL_ANYEVENT_STRICT}; |
1312 | if ($ENV{PERL_ANYEVENT_STRICT}) { |
|
|
1313 | eval { require AnyEvent::Strict }; |
|
|
1314 | warn "AnyEvent: cannot load AnyEvent::Strict: $@" |
|
|
1315 | if $@ && $VERBOSE; |
|
|
1316 | } |
1311 | |
1317 | |
1312 | (shift @post_detect)->() while @post_detect; |
1318 | (shift @post_detect)->() while @post_detect; |
1313 | |
1319 | |
1314 | *post_detect = sub(&) { |
1320 | *post_detect = sub(&) { |
1315 | shift->(); |
1321 | shift->(); |
… | |
… | |
1724 | } |
1730 | } |
1725 | |
1731 | |
1726 | package AnyEvent::CondVar; |
1732 | package AnyEvent::CondVar; |
1727 | |
1733 | |
1728 | our @ISA = AnyEvent::CondVar::Base::; |
1734 | our @ISA = AnyEvent::CondVar::Base::; |
|
|
1735 | |
|
|
1736 | # only to be used for subclassing |
|
|
1737 | sub new { |
|
|
1738 | my $class = shift; |
|
|
1739 | bless AnyEvent->condvar (@_), $class |
|
|
1740 | } |
1729 | |
1741 | |
1730 | package AnyEvent::CondVar::Base; |
1742 | package AnyEvent::CondVar::Base; |
1731 | |
1743 | |
1732 | #use overload |
1744 | #use overload |
1733 | # '&{}' => sub { my $self = shift; sub { $self->send (@_) } }, |
1745 | # '&{}' => sub { my $self = shift; sub { $self->send (@_) } }, |
… | |
… | |
2652 | pronounced). |
2664 | pronounced). |
2653 | |
2665 | |
2654 | |
2666 | |
2655 | =head1 SEE ALSO |
2667 | =head1 SEE ALSO |
2656 | |
2668 | |
|
|
2669 | Tutorial/Introduction: L<AnyEvent::Intro>. |
|
|
2670 | |
|
|
2671 | FAQ: L<AnyEvent::FAQ>. |
|
|
2672 | |
2657 | Utility functions: L<AnyEvent::Util>. |
2673 | Utility functions: L<AnyEvent::Util>. |
2658 | |
2674 | |
2659 | Event modules: L<EV>, L<EV::Glib>, L<Glib::EV>, L<Event>, L<Glib::Event>, |
2675 | Event modules: L<EV>, L<EV::Glib>, L<Glib::EV>, L<Event>, L<Glib::Event>, |
2660 | L<Glib>, L<Tk>, L<Event::Lib>, L<Qt>, L<POE>. |
2676 | L<Glib>, L<Tk>, L<Event::Lib>, L<Qt>, L<POE>. |
2661 | |
2677 | |
… | |
… | |
2667 | Non-blocking file handles, sockets, TCP clients and |
2683 | Non-blocking file handles, sockets, TCP clients and |
2668 | servers: L<AnyEvent::Handle>, L<AnyEvent::Socket>, L<AnyEvent::TLS>. |
2684 | servers: L<AnyEvent::Handle>, L<AnyEvent::Socket>, L<AnyEvent::TLS>. |
2669 | |
2685 | |
2670 | Asynchronous DNS: L<AnyEvent::DNS>. |
2686 | Asynchronous DNS: L<AnyEvent::DNS>. |
2671 | |
2687 | |
2672 | Coroutine support: L<Coro>, L<Coro::AnyEvent>, L<Coro::EV>, |
2688 | Thread support: L<Coro>, L<Coro::AnyEvent>, L<Coro::EV>, L<Coro::Event>. |
2673 | L<Coro::Event>, |
|
|
2674 | |
2689 | |
2675 | Nontrivial usage examples: L<AnyEvent::GPSD>, L<AnyEvent::XMPP>, |
2690 | Nontrivial usage examples: L<AnyEvent::GPSD>, L<AnyEvent::IRC>, |
2676 | L<AnyEvent::HTTP>. |
2691 | L<AnyEvent::HTTP>. |
2677 | |
2692 | |
2678 | |
2693 | |
2679 | =head1 AUTHOR |
2694 | =head1 AUTHOR |
2680 | |
2695 | |