summaryrefslogtreecommitdiffstats
path: root/Source/cmGetPropertyCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGetPropertyCommand.cxx')
-rw-r--r--Source/cmGetPropertyCommand.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/cmGetPropertyCommand.cxx b/Source/cmGetPropertyCommand.cxx
index f0b2686..3e1d08e 100644
--- a/Source/cmGetPropertyCommand.cxx
+++ b/Source/cmGetPropertyCommand.cxx
@@ -12,6 +12,7 @@
#include "cmGetPropertyCommand.h"
#include "cmake.h"
+#include "cmState.h"
#include "cmTest.h"
#include "cmGlobalGenerator.h"
#include "cmLocalGenerator.h"
@@ -142,7 +143,7 @@ bool cmGetPropertyCommand
// Lookup brief documentation.
std::string output;
if(cmPropertyDefinition* def =
- this->Makefile->GetCMakeInstance()->
+ this->Makefile->GetState()->
GetPropertyDefinition(this->PropertyName, scope))
{
output = def->GetShortDescription();
@@ -158,7 +159,7 @@ bool cmGetPropertyCommand
// Lookup full documentation.
std::string output;
if(cmPropertyDefinition* def =
- this->Makefile->GetCMakeInstance()->
+ this->Makefile->GetState()->
GetPropertyDefinition(this->PropertyName, scope))
{
output = def->GetFullDescription();
@@ -172,7 +173,7 @@ bool cmGetPropertyCommand
else if(this->InfoType == OutDefined)
{
// Lookup if the property is defined
- if(this->Makefile->GetCMakeInstance()->
+ if(this->Makefile->GetState()->
GetPropertyDefinition(this->PropertyName, scope))
{
this->Makefile->AddDefinition(this->Variable, "1");
@@ -236,7 +237,8 @@ bool cmGetPropertyCommand::HandleGlobalMode()
// Get the property.
cmake* cm = this->Makefile->GetCMakeInstance();
- return this->StoreResult(cm->GetProperty(this->PropertyName));
+ return this->StoreResult(cm->GetState()
+ ->GetGlobalProperty(this->PropertyName));
}
//----------------------------------------------------------------------------
@@ -391,11 +393,10 @@ bool cmGetPropertyCommand::HandleCacheMode()
}
const char* value = 0;
- cmCacheManager::CacheIterator it =
- this->Makefile->GetCacheManager()->GetCacheIterator(this->Name.c_str());
- if(!it.IsAtEnd())
+ if(this->Makefile->GetState()->GetCacheEntryValue(this->Name))
{
- value = it.GetProperty(this->PropertyName);
+ value = this->Makefile->GetState()
+ ->GetCacheEntryProperty(this->Name, this->PropertyName);
}
this->StoreResult(value);
return true;