diff options
Diffstat (limited to 'framework/Data/SqlMap/Configuration')
-rw-r--r-- | framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php b/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php index 5854b21a..462b356f 100644 --- a/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php +++ b/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php @@ -349,6 +349,15 @@ class TSqlMapXmlMappingConfiguration extends TSqlMapXmlConfigBuilder $document = $this->loadXmlDocument($filename,$this->_xmlConfig);
$this->_document=$document;
+ static $bCacheDependencies;
+ if($bCacheDependencies === null)
+ $bCacheDependencies = Prado::getApplication()->getMode() !== TApplicationMode::Performance;
+
+ if($bCacheDependencies)
+ $this->_manager->getCacheDependencies()
+ ->getDependencies()
+ ->add(new TFileCacheDependency($filename));
+
foreach($document->xpath('//resultMap') as $node)
$this->loadResultMap($node);
|