smarthacker67 has asked for the wisdom of the Perl Monks concerning the following question:
package MyPackage; while(1) { fetch_data(); send_to_poe(); <<< this how & where I want to send to POE. so th +at while loop can process it should not wait for reply as it don't ne +ed reply so can say an async call }
POE::Session->create( inline_states => { _start => sub { $_[KERNEL]->yield("next") }, next => sub { print "listening...\n"; $_[KERNEL]->delay(next => 1); }, }, ); POE::Kernel->run(); # exit
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Need help in getting started with POE
by Fletch (Bishop) on Jun 17, 2020 at 04:30 UTC | |
by smarthacker67 (Beadle) on Jun 17, 2020 at 15:23 UTC |