Command Execution


class CommandRunner

#include "CommandRunner.h"

The CommandRunner class can be used to execute shell commands from a C++ program.

Methods

static void Run(const string & commandText);

Executes the passed-in command string. If the command fails (i.e., returns a non-zero value from main), a CS240Exception is thrown.

Example:

	CommandRunner::Run("g++ -o hello HelloWorld.cpp");


Ken Rodham