- Timestamp:
- Dec 25, 2009, 1:18:03 PM (15 years ago)
- Location:
- code/branches/pickup2
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/pickup2
- Property svn:mergeinfo changed
-
code/branches/pickup2/src/libraries/core/DynLibManager.cc
r5738 r6412 41 41 42 42 //----------------------------------------------------------------------- 43 44 45 46 43 DynLibManager::DynLibManager() 44 { 45 } 46 //----------------------------------------------------------------------- 47 47 DynLib* DynLibManager::load( const std::string& filename) 48 48 { 49 50 51 52 53 54 55 56 57 58 59 60 49 DynLibList::iterator i = mLibList.find(filename); 50 if (i != mLibList.end()) 51 { 52 return i->second; 53 } 54 else 55 { 56 DynLib* pLib = new DynLib(filename); 57 pLib->load(); 58 mLibList[filename] = pLib; 59 return pLib; 60 } 61 61 } 62 63 64 65 66 67 68 69 70 71 72 73 62 //----------------------------------------------------------------------- 63 void DynLibManager::unload(DynLib* lib) 64 { 65 DynLibList::iterator i = mLibList.find(lib->getName()); 66 if (i != mLibList.end()) 67 { 68 mLibList.erase(i); 69 } 70 lib->unload(); 71 delete lib; 72 } 73 //----------------------------------------------------------------------- 74 74 DynLibManager::~DynLibManager() 75 75 {
Note: See TracChangeset
for help on using the changeset viewer.