Main Page | Class List | File List | Class Members

command_line_program.cpp File Reference

implementation for sven_ui::CommandLineProgram. More...

#include <windows.h>
#include <atlbase.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sven/fs_addons.h>
#include <stdexcept>
#include <iostream>
#include <string>
#include <sstream>
#include <Winuser.h>
#include <sven_ui/commands.h>
#include <sven/except_macros.h>
#include <sven/string_addons.h>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
#include <boost/thread/xtime.hpp>
#include <boost/thread/condition.hpp>
#include <sven_ui/command_line_program.h>
#include <sven/message_boxes.h>
#include <sven/timer.h>
#include <com_helpers.h>

Go to the source code of this file.

Namespaces

namespace  sven_ui
namespace  sven_ui::cmdline_prog_imp
namespace  std
namespace  sven

Functions

bool pipe_read (HANDLE pipe, const int BUFSIZE, TCHAR chBuf[])
 This is a helper function that we use to read set of characters out of a pipe without hanging.


Detailed Description

implementation for sven_ui::CommandLineProgram.

Definition in file command_line_program.cpp.


Function Documentation

bool pipe_read HANDLE  pipe,
const int  BUFSIZE,
TCHAR  chBuf[]
 

This is a helper function that we use to read set of characters out of a pipe without hanging.

It returns true if any data was succesfully read, false otherwise. It does not distinguish between different reasons for an unsucessful read (which might include a broken pipe, system error, or simple EOF).

Inspired by: http://groups.google.com/group/microsoft.public.vb.winapi/browse_thread/thread/c00169542711772f/71435388f1b0922b?lnk=st&q=ReadFile+hang+pipe&rnum=1&hl=en#71435388f1b0922b

Definition at line 109 of file command_line_program.cpp.


Generated on Mon Mar 17 12:13:59 2008 for Command Line Demo by  doxygen 1.3.9.1