diff options
author | Brad King <brad.king@kitware.com> | 2003-07-08 02:44:18 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2003-07-08 02:44:18 (GMT) |
commit | 1cecf7b5aaa4a74a1a2a4545a9effda7cdc61879 (patch) | |
tree | aaf5f7056b1e8554dcc0006e64fabb95be0faae5 /Source/cmDocumentation.h | |
parent | b85f000e26fd7d00fee2073581f2c2ce8098fa2d (diff) | |
download | CMake-1cecf7b5aaa4a74a1a2a4545a9effda7cdc61879.zip CMake-1cecf7b5aaa4a74a1a2a4545a9effda7cdc61879.tar.gz CMake-1cecf7b5aaa4a74a1a2a4545a9effda7cdc61879.tar.bz2 |
ENH: Added support to write multiple help options with one command line. Output files can now also be specified for the help options.
Diffstat (limited to 'Source/cmDocumentation.h')
-rw-r--r-- | Source/cmDocumentation.h | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/Source/cmDocumentation.h b/Source/cmDocumentation.h index b5cf85c..598b1d3 100644 --- a/Source/cmDocumentation.h +++ b/Source/cmDocumentation.h @@ -32,11 +32,19 @@ public: /** * Check command line arguments for documentation options. Returns - * the type of help to be provided. If non-zero, the result should - * be passed to PrintDocumentation to produce the desired - * documentation. + * true if documentation options are found, and false otherwise. + * When true is returned, PrintRequestedDocumentation should be + * called. */ - Type CheckOptions(int argc, char** argv); + bool CheckOptions(int argc, char** argv); + + /** + * Print help requested on the command line. Call after + * CheckOptions returns true. Returns true on success, and false + * otherwise. Failure can occur when output files specified on the + * command line cannot be written. + */ + bool PrintRequestedDocumentation(std::ostream& os); /** Print help of the given type. */ void PrintDocumentation(Type ht, std::ostream& os); @@ -134,6 +142,9 @@ private: Form CurrentForm; const char* TextIndent; int TextWidth; + + typedef std::map<Type, cmStdString> RequestedMapType; + RequestedMapType RequestedMap; }; #endif |