diff --git a/include/shell.hpp b/include/shell.hpp index 37ce167..042bb8b 100644 --- a/include/shell.hpp +++ b/include/shell.hpp @@ -52,27 +52,41 @@ namespace ztd */ int pclose2(FILE* fp, pid_t pid); + + //! @brief Shell call class class shc { public: + //! @brief constructor shc(std::string const& cmd="", bool const cout=false); virtual ~shc(); + //! @brief Start the command void run(); + //! @brief Kill the command (SIGINT) int kill_int(); + //! @brief Wait until the command gives output void wait_output(); + //! @brief Retrieve a line from the command's output std::string get_output(); + //! @brief Wait for the command to finish void wait_finish(); + //! @brief Command to execute std::string command; + //! @brief Output the command result to console bool to_console; + //! @brief Run status of the command bool running; + //! @brief PID of the command (only during execution) pid_t pid; + //! @brief Output lines of the command std::queue output; + //! @brief Return value on the command (only after execution) int return_value; ztd::wait_pool wp_output; diff --git a/md/filedat.md b/md/filedat.md index 60681a9..d777537 100644 --- a/md/filedat.md +++ b/md/filedat.md @@ -14,7 +14,7 @@ Everything is a string, there are no number or boolean types ### Map Chunk A map chunk consists of pairs of keys and values. -Key separators are \n and ; +Key separators are \\n and ; Format is as follows: ``` @@ -161,5 +161,5 @@ catch (ztd::format_error& fe) printFormatException(fe); } ``` -If origin is known, printFormatException will print only the relevant line with location
+If origin is known, printFormatException will print only the relevant line with location \n If origin is unknown, printFormatException will print the whole data until the discriminating line