From cb8f2362ca522fc04b71eaf4d61cb30ad0e73ddf Mon Sep 17 00:00:00 2001 From: "godzilla80@gmx.net" <> Date: Sun, 7 Jun 2009 08:13:34 +0000 Subject: Fixed Issue #168 - TSqlMapXmlConfiguration: CacheModel properties are not set --- .../Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'framework/Data/SqlMap') diff --git a/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php b/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php index 462b356f..f6e0acd5 100644 --- a/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php +++ b/framework/Data/SqlMap/Configuration/TSqlMapXmlConfiguration.php @@ -712,6 +712,20 @@ class TSqlMapXmlMappingConfiguration extends TSqlMapXmlConfigBuilder } $cache = Prado::createComponent($cacheModel->getImplementationClass()); $this->setObjectPropFromNode($cache,$node,$properties); + + foreach($node->xpath('property') as $propertyNode) + { + $name = $propertyNode->attributes()->name; + if($name===null || $name==='') continue; + + $value = $propertyNode->attributes()->value; + if($value===null || $value==='') continue; + + if( !TPropertyAccess::has($cache, $name) ) continue; + + TPropertyAccess::set($cache, $name, $value); + } + $this->loadFlushInterval($cacheModel,$node); $cacheModel->initialize($cache); -- cgit v1.2.3