summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.h
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2007-06-15 14:10:24 (GMT)
committerAlexander Neundorf <neundorf@kde.org>2007-06-15 14:10:24 (GMT)
commit9d4f3a06864b3b5fe96073ddc256ef39ab24ddad (patch)
treee55df81497545d678b13be3c5ccdcd34ae62af5a /Source/cmGlobalGenerator.h
parentc2f7a3c02730759d6bde6b6b50daa1f23cc5fe24 (diff)
downloadCMake-9d4f3a06864b3b5fe96073ddc256ef39ab24ddad.zip
CMake-9d4f3a06864b3b5fe96073ddc256ef39ab24ddad.tar.gz
CMake-9d4f3a06864b3b5fe96073ddc256ef39ab24ddad.tar.bz2
STYLE: remove duplicate non-const accessors GetLocalGenerator(int) and
GetLocaGenerators(cmLocalGenerators) from cmGlobalGenerator(). Now there is one const accessor which is even faster since it returns a reference (instead of copying a vector) -more const to ensure that this the returned local generators don't actually get modified -removed duplicated code in GetCTestCommand() and GetCPackCommand() -added some const accessors Alex
Diffstat (limited to 'Source/cmGlobalGenerator.h')
-rw-r--r--Source/cmGlobalGenerator.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/Source/cmGlobalGenerator.h b/Source/cmGlobalGenerator.h
index eb49883..3ab18bc 100644
--- a/Source/cmGlobalGenerator.h
+++ b/Source/cmGlobalGenerator.h
@@ -117,10 +117,8 @@ public:
cmake *GetCMakeInstance() { return this->CMakeInstance; };
void SetConfiguredFilesPath(const char* s){this->ConfiguredFilesPath = s;}
- cmLocalGenerator* GetLocalGenerator(int p) {
- return this->LocalGenerators[p];}
- void GetLocalGenerators(std::vector<cmLocalGenerator *>&g) {
- g = this->LocalGenerators;}
+ const std::vector<cmLocalGenerator *>& GetLocalGenerators() const {
+ return this->LocalGenerators;}
void AddLocalGenerator(cmLocalGenerator *lg);