summaryrefslogtreecommitdiff
path: root/Source/cmDocumentation.h
diff options
context:
space:
mode:
authorKitware Robot <kwrobot@kitware.com>2016-05-16 10:34:04 -0400
committerBrad King <brad.king@kitware.com>2016-05-16 16:05:19 -0400
commitd9fd2f5402eeaa345691313658e02b51038f570b (patch)
treedca71b9a7e267f4c6300da3eb770415381726785 /Source/cmDocumentation.h
parent82df6deaafb36cbbfd450202bb20b320f637751a (diff)
downloadcmake-d9fd2f5402eeaa345691313658e02b51038f570b.tar.gz
Revise C++ coding style using clang-format
Run the `Utilities/Scripts/clang-format.bash` script to update all our C++ code to a new style defined by `.clang-format`. Use `clang-format` version 3.8. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
Diffstat (limited to 'Source/cmDocumentation.h')
-rw-r--r--Source/cmDocumentation.h50
1 files changed, 22 insertions, 28 deletions
diff --git a/Source/cmDocumentation.h b/Source/cmDocumentation.h
index a1d73f5a64..dd99ca89f2 100644
--- a/Source/cmDocumentation.h
+++ b/Source/cmDocumentation.h
@@ -18,13 +18,12 @@
#include "cmDocumentationSection.h"
#include "cmake.h"
-namespace cmsys
-{
- class Directory;
+namespace cmsys {
+class Directory;
}
/** Class to generate documentation. */
-class cmDocumentation: public cmDocumentationEnums
+class cmDocumentation : public cmDocumentationEnums
{
public:
cmDocumentation();
@@ -40,7 +39,7 @@ public:
* help arguments.
*/
bool CheckOptions(int argc, const char* const* argv,
- const char* exitOpt =0);
+ const char* exitOpt = 0);
/**
* Print help requested on the command line. Call after
@@ -60,28 +59,21 @@ public:
/** Set a section of the documentation. Typical sections include Name,
Usage, Description, Options */
- void SetSection(const char *sectionName,
- cmDocumentationSection *section);
- void SetSection(const char *sectionName,
- std::vector<cmDocumentationEntry> &docs);
- void SetSection(const char *sectionName,
- const char *docs[][2]);
- void SetSections(std::map<std::string,cmDocumentationSection *>
- &sections);
+ void SetSection(const char* sectionName, cmDocumentationSection* section);
+ void SetSection(const char* sectionName,
+ std::vector<cmDocumentationEntry>& docs);
+ void SetSection(const char* sectionName, const char* docs[][2]);
+ void SetSections(std::map<std::string, cmDocumentationSection*>& sections);
/** Add the documentation to the beginning/end of the section */
- void PrependSection(const char *sectionName,
- const char *docs[][2]);
- void PrependSection(const char *sectionName,
- std::vector<cmDocumentationEntry> &docs);
- void PrependSection(const char *sectionName,
- cmDocumentationEntry &docs);
- void AppendSection(const char *sectionName,
- const char *docs[][2]);
- void AppendSection(const char *sectionName,
- std::vector<cmDocumentationEntry> &docs);
- void AppendSection(const char *sectionName,
- cmDocumentationEntry &docs);
+ void PrependSection(const char* sectionName, const char* docs[][2]);
+ void PrependSection(const char* sectionName,
+ std::vector<cmDocumentationEntry>& docs);
+ void PrependSection(const char* sectionName, cmDocumentationEntry& docs);
+ void AppendSection(const char* sectionName, const char* docs[][2]);
+ void AppendSection(const char* sectionName,
+ std::vector<cmDocumentationEntry>& docs);
+ void AppendSection(const char* sectionName, cmDocumentationEntry& docs);
/** Add common (to all tools) documentation section(s) */
void addCommonStandardDocSections();
@@ -96,7 +88,6 @@ public:
void addCPackStandardDocSections();
private:
-
void GlobHelp(std::vector<std::string>& files, std::string const& pattern);
void PrintNames(std::ostream& os, std::string const& pattern);
bool PrintFiles(std::ostream& os, std::string const& pattern);
@@ -126,13 +117,16 @@ private:
bool ShowGenerators;
std::string NameString;
- std::map<std::string,cmDocumentationSection*> AllSections;
+ std::map<std::string, cmDocumentationSection*> AllSections;
std::string CurrentArgument;
struct RequestedHelpItem
{
- RequestedHelpItem(): HelpType(None) {}
+ RequestedHelpItem()
+ : HelpType(None)
+ {
+ }
cmDocumentationEnums::Type HelpType;
std::string Filename;
std::string Argument;