Friday, May 22, 2009

File I/O

In attempting to create a file object to act as a helper class, I ran into the issue of blocking I/O. I was initially going to implement the file helper class before implementing the versions of asynchronous I/O with Popen before doing so but then I realized I would run into issues of blocking when the file.write function was called; since we are treating it like a file object, the output isn't immediately important to us so blocking doesn't make sense for this. I have been looking into a specific piece of code on activestate with an async I/O implementation for Popen and one of the comments contained information on non-blocking I/O but for Posix systems only. I need to figure out how to keep the I/O from blocking on Windows as well since cross platform compatibility is one of my overall goals.

1 comment:

  1. hey
    i have had a online that project i had to send a command to cl.exe but before that i had to run that batch file in on ,i had to send some commands to cmd.i finally found can easily command a child process with it.