diff options
author | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2011-02-05 13:18:52 +0100 |
---|---|---|
committer | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2011-02-05 13:18:52 +0100 |
commit | bb564bec137f76dfa099a1cdda3cf39367a6fe50 (patch) | |
tree | e444279823cc1fc9dd07196ea8008720db49248a /framework/source/uiconfiguration | |
parent | 5ace73b0896ce36a1ea86fb1c3cb9040f12a3e17 (diff) |
migrate to use boost unordered containers
Diffstat (limited to 'framework/source/uiconfiguration')
8 files changed, 18 insertions, 18 deletions
diff --git a/framework/source/uiconfiguration/imagemanagerimpl.hxx b/framework/source/uiconfiguration/imagemanagerimpl.hxx index aa10b763ad3b..46582fbf19c6 100644 --- a/framework/source/uiconfiguration/imagemanagerimpl.hxx +++ b/framework/source/uiconfiguration/imagemanagerimpl.hxx @@ -35,7 +35,7 @@ */ #include <vector> #include <list> -#include <hash_map> +#include <boost/unordered_map.hpp> //_________________________________________________________________________________________________________________ // my own includes @@ -162,7 +162,7 @@ namespace framework void clear(); - typedef std::hash_map< rtl::OUString, + typedef boost::unordered_map< rtl::OUString, sal_Bool, OUStringHashCode, ::std::equal_to< ::rtl::OUString > > ImageNameMap; diff --git a/framework/source/uiconfiguration/moduleuicfgsupplier.cxx b/framework/source/uiconfiguration/moduleuicfgsupplier.cxx index 608214d1d656..59cb3b531e2b 100644 --- a/framework/source/uiconfiguration/moduleuicfgsupplier.cxx +++ b/framework/source/uiconfiguration/moduleuicfgsupplier.cxx @@ -122,7 +122,7 @@ ModuleUIConfigurationManagerSupplier::ModuleUIConfigurationManagerSupplier( cons , m_aListenerContainer( m_aLock.getShareableOslMutex() ) { RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "framework", "Ocke.Janssen@sun.com", "ModuleUIConfigurationManagerSupplier::ModuleUIConfigurationManagerSupplier" ); - // Retrieve known modules and insert them into our hash_map to speed-up access time. + // Retrieve known modules and insert them into our boost::unordered_map to speed-up access time. Reference< XNameAccess > xNameAccess( m_xModuleMgr, UNO_QUERY ); const Sequence< ::rtl::OUString > aNameSeq = xNameAccess->getElementNames(); const ::rtl::OUString* pNameSeq = aNameSeq.getConstArray(); diff --git a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx index 817eb969a16a..64756c1cf298 100644 --- a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx +++ b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx @@ -287,7 +287,7 @@ void ModuleUIConfigurationManager::impl_preloadUIElementTypeList( Layer eLayer, aUIElementData.bDefaultNode = false; } - // Create hash_map entries for all user interface elements inside the storage. We don't load the + // Create boost::unordered_map entries for all user interface elements inside the storage. We don't load the // settings to speed up the process. rHashMap.insert( UIElementDataHashMap::value_type( aUIElementData.aResourceURL, aUIElementData )); } @@ -408,7 +408,7 @@ ModuleUIConfigurationManager::UIElementData* ModuleUIConfigurationManager::impl impl_preloadUIElementTypeList( LAYER_USERDEFINED, nElementType ); impl_preloadUIElementTypeList( LAYER_DEFAULT, nElementType ); - // first try to look into our user-defined vector/hash_map combination + // first try to look into our user-defined vector/boost::unordered_map combination UIElementDataHashMap& rUserHashMap = m_aUIElements[LAYER_USERDEFINED][nElementType].aElementsHashMap; UIElementDataHashMap::iterator pIter = rUserHashMap.find( aResourceURL ); if ( pIter != rUserHashMap.end() ) @@ -422,7 +422,7 @@ ModuleUIConfigurationManager::UIElementData* ModuleUIConfigurationManager::impl } } - // Not successfull, we have to look into our default vector/hash_map combination + // Not successfull, we have to look into our default vector/boost::unordered_map combination UIElementDataHashMap& rDefaultHashMap = m_aUIElements[LAYER_DEFAULT][nElementType].aElementsHashMap; pIter = rDefaultHashMap.find( aResourceURL ); if ( pIter != rDefaultHashMap.end() ) @@ -1446,7 +1446,7 @@ throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::la // preload list of element types on demand impl_preloadUIElementTypeList( LAYER_DEFAULT, nElementType ); - // Look into our default vector/hash_map combination + // Look into our default vector/boost::unordered_map combination UIElementDataHashMap& rDefaultHashMap = m_aUIElements[LAYER_DEFAULT][nElementType].aElementsHashMap; UIElementDataHashMap::iterator pIter = rDefaultHashMap.find( ResourceURL ); if ( pIter != rDefaultHashMap.end() ) diff --git a/framework/source/uiconfiguration/uicategorydescription.cxx b/framework/source/uiconfiguration/uicategorydescription.cxx index ec60d680475f..49d415b7655f 100644 --- a/framework/source/uiconfiguration/uicategorydescription.cxx +++ b/framework/source/uiconfiguration/uicategorydescription.cxx @@ -137,7 +137,7 @@ class ConfigurationAccess_UICategory : // Order is neccessary for right initiali sal_Bool fillCache(); private: - typedef ::std::hash_map< ::rtl::OUString, + typedef ::boost::unordered_map< ::rtl::OUString, ::rtl::OUString, OUStringHashCode, ::std::equal_to< ::rtl::OUString > > IdToInfoCache; diff --git a/framework/source/uiconfiguration/uiconfigurationmanager.cxx b/framework/source/uiconfiguration/uiconfigurationmanager.cxx index 06bec8c814f3..df7505460265 100644 --- a/framework/source/uiconfiguration/uiconfigurationmanager.cxx +++ b/framework/source/uiconfiguration/uiconfigurationmanager.cxx @@ -225,7 +225,7 @@ void UIConfigurationManager::impl_preloadUIElementTypeList( sal_Int16 nElementTy aUIElementData.bModified = false; aUIElementData.bDefault = false; - // Create hash_map entries for all user interface elements inside the storage. We don't load the + // Create boost::unordered_map entries for all user interface elements inside the storage. We don't load the // settings to speed up the process. rHashMap.insert( UIElementDataHashMap::value_type( aUIElementData.aResourceURL, aUIElementData )); } @@ -344,7 +344,7 @@ UIConfigurationManager::UIElementData* UIConfigurationManager::impl_findUIElemen // preload list of element types on demand impl_preloadUIElementTypeList( nElementType ); - // try to look into our document vector/hash_map combination + // try to look into our document vector/boost::unordered_map combination UIElementDataHashMap& rUserHashMap = m_aUIElements[nElementType].aElementsHashMap; UIElementDataHashMap::iterator pIter = rUserHashMap.find( aResourceURL ); if ( pIter != rUserHashMap.end() ) diff --git a/framework/source/uiconfiguration/uiconfigurationmanagerimpl.cxx b/framework/source/uiconfiguration/uiconfigurationmanagerimpl.cxx index f9926f5635d1..313d07734995 100644 --- a/framework/source/uiconfiguration/uiconfigurationmanagerimpl.cxx +++ b/framework/source/uiconfiguration/uiconfigurationmanagerimpl.cxx @@ -257,7 +257,7 @@ void UIConfigurationManagerImpl::impl_preloadUIElementTypeList( Layer eLayer, sa aUIElementData.bDefaultNode = false; } - // Create hash_map entries for all user interface elements inside the storage. We don't load the + // Create boost::unordered_map entries for all user interface elements inside the storage. We don't load the // settings to speed up the process. rHashMap.insert( UIElementDataHashMap::value_type( aUIElementData.aResourceURL, aUIElementData )); } @@ -378,7 +378,7 @@ UIConfigurationManagerImpl::UIElementData* UIConfigurationManagerImpl::impl_fin if ( m_bUseDefault ) impl_preloadUIElementTypeList( LAYER_DEFAULT, nElementType ); - // first try to look into our user-defined vector/hash_map combination + // first try to look into our user-defined vector/boost::unordered_map combination UIElementDataHashMap& rUserHashMap = m_aUIElements[LAYER_USERDEFINED][nElementType].aElementsHashMap; UIElementDataHashMap::iterator pIter = rUserHashMap.find( aResourceURL ); if ( pIter != rUserHashMap.end() ) @@ -394,7 +394,7 @@ UIConfigurationManagerImpl::UIElementData* UIConfigurationManagerImpl::impl_fin if ( m_bUseDefault ) { - // Not successfull, we have to look into our default vector/hash_map combination + // Not successfull, we have to look into our default vector/boost::unordered_map combination UIElementDataHashMap& rDefaultHashMap = m_aUIElements[LAYER_DEFAULT][nElementType].aElementsHashMap; pIter = rDefaultHashMap.find( aResourceURL ); if ( pIter != rDefaultHashMap.end() ) @@ -1536,7 +1536,7 @@ throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::la // preload list of element types on demand impl_preloadUIElementTypeList( LAYER_DEFAULT, nElementType ); - // Look into our default vector/hash_map combination + // Look into our default vector/boost::unordered_map combination UIElementDataHashMap& rDefaultHashMap = m_aUIElements[LAYER_DEFAULT][nElementType].aElementsHashMap; UIElementDataHashMap::iterator pIter = rDefaultHashMap.find( ResourceURL ); if ( pIter != rDefaultHashMap.end() ) diff --git a/framework/source/uiconfiguration/uiconfigurationmanagerimpl.hxx b/framework/source/uiconfiguration/uiconfigurationmanagerimpl.hxx index 4483693804bf..a2be907122d0 100644 --- a/framework/source/uiconfiguration/uiconfigurationmanagerimpl.hxx +++ b/framework/source/uiconfiguration/uiconfigurationmanagerimpl.hxx @@ -35,7 +35,7 @@ */ #include <vector> #include <list> -#include <hash_map> +#include <boost/unordered_map.hpp> //_________________________________________________________________________________________________________________ // my own includes @@ -159,7 +159,7 @@ namespace framework struct UIElementType; friend struct UIElementType; - typedef ::std::hash_map< rtl::OUString, UIElementData, OUStringHashCode, ::std::equal_to< rtl::OUString > > UIElementDataHashMap; + typedef ::boost::unordered_map< rtl::OUString, UIElementData, OUStringHashCode, ::std::equal_to< rtl::OUString > > UIElementDataHashMap; struct UIElementType { @@ -179,7 +179,7 @@ namespace framework typedef ::std::vector< UIElementType > UIElementTypesVector; typedef ::std::vector< ::com::sun::star::ui::ConfigurationEvent > ConfigEventNotifyContainer; - typedef ::std::hash_map< rtl::OUString, UIElementInfo, OUStringHashCode, ::std::equal_to< rtl::OUString > > UIElementInfoHashMap; + typedef ::boost::unordered_map< rtl::OUString, UIElementInfo, OUStringHashCode, ::std::equal_to< rtl::OUString > > UIElementInfoHashMap; // private methods void impl_Initialize(); diff --git a/framework/source/uiconfiguration/windowstateconfiguration.cxx b/framework/source/uiconfiguration/windowstateconfiguration.cxx index 8936f88ce9f6..7b081b335bde 100644 --- a/framework/source/uiconfiguration/windowstateconfiguration.cxx +++ b/framework/source/uiconfiguration/windowstateconfiguration.cxx @@ -257,7 +257,7 @@ class ConfigurationAccess_WindowState : // interfaces sal_Bool impl_initializeConfigAccess(); private: - typedef ::std::hash_map< ::rtl::OUString, + typedef ::boost::unordered_map< ::rtl::OUString, WindowStateInfo, OUStringHashCode, ::std::equal_to< ::rtl::OUString > > ResourceURLToInfoCache; |