Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^4: Thread implementation for Win32::GUI

by ckant8 (Acolyte)
on Mar 28, 2013 at 03:41 UTC ( #1025842=note: print w/replies, xml ) Need Help??


in reply to Re^3: Thread implementation for Win32::GUI
in thread Thread implementation for Win32::GUI

Thanks for the reply. Could you post some examples...plz
  • Comment on Re^4: Thread implementation for Win32::GUI

Replies are listed 'Best First'.
Re^5: Thread implementation for Win32::GUI
by Corion (Pope) on Mar 28, 2013 at 08:25 UTC

    I recommend the following setup:

    use strict; use threads; use Thread::Queue; my $remote_commands= Thread::Queue->new; my $status= Thread::Queue->new; # responses sub worker { $status->enqueue('Connecting to host'); require Net::Telnet; ... connect to host while (defined(my $cmd= $remote_commands->dequeue)) { $status->enqueue("Running [$cmd]"); $telnet->print($cmd); }; }; my $worker= threads->new( \&worker ); ... sub btQuery_Click { # ... send commands to queue $remote_commands->enqueue("cd /"); $remote_commands->enqueue("echo 'Hello World'"); ... };

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1025842]
help
Chatterbox?
[LanX]: ehm ... I woke up my *boobs* ?
LanX where is the camera?
Tux => $HOME
[Eily]: you wrote boos instead of boss, and jedikaiti read that as boobs :)
[LanX]: Win claims only 8 MB left on C: how do I find out where the problem happens?
[Eily]: by Tux. And going home sounds like a good idea
[Eily]: LanX pretty much everywhere except in 8MB ?
[Eily]: s/by/bye/ someone hacked my keyboard I'm sure
[LanX]: good point! :)
[Eily]: LanX I don't understand the question though, you want to know what is taking so much space?

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (12)
As of 2017-09-20 16:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (237 votes). Check out past polls.

    Notices?