Phoxonics  1.0
Object Oriented FDTD Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | List of all members
phoxonics::common::Command Class Reference
Inheritance diagram for phoxonics::common::Command:
Inheritance graph
[legend]
Collaboration diagram for phoxonics::common::Command:
Collaboration graph
[legend]

Public Member Functions

 Command ()
 
virtual ~Command ()
 
std::string execute_command (char *cmd)
 Executes a shell command. More...
 

Additional Inherited Members

- Protected Types inherited from phoxonics::common::CommonBase
typedef Formatter fmt_
 
- Protected Member Functions inherited from phoxonics::common::CommonBase
 CommonBase ()
 
virtual ~CommonBase ()
 
- Protected Attributes inherited from phoxonics::common::CommonBase
Logger log_
 

Constructor & Destructor Documentation

phoxonics::common::Command::Command ( )
phoxonics::common::Command::~Command ( )
virtual

Member Function Documentation

std::string phoxonics::common::Command::execute_command ( char *  cmd)

Executes a shell command.

Parameters
cmdThe command to execute
Returns
The result of the execution

This method executes a bash command using a pipe and a buffer to capture the result of the execution, then return the execution to client code.

References phoxonics::common::CommonBase::log_, and phoxonics::common::Logger::log_trac().

Referenced by phoxonics::common::Utilities::get_new_unique_id().