On Thu, Dec 15, 2011 at 6:14 PM, Littlefield, Tyler <ty...@tysdomain.com> wrote:
> Hello all:
> I have a quick question--I am working on a project where a system will
> connect to me to get commands. The idea is to make the server the "client,"
> used for dispatching commands, so  I'm trying to find a way that I can set
> it up to listen, but poll stdin somehow for input. Is this a possibility?

One easy way to do that is to use separate threads, one to watch stdin
(preferably the main thread) and one to listen on the socket or
whatever the other end uses. Another option is to use async calls and
callbacks. But to answer your simplest question, yes, it most
definitely is.

ChrisA
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to