Changeset 7739 for trunk/gli/src/org/greenstone/gatherer/cdm
- Timestamp:
- 2004-07-16T13:48:18+12:00 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/cdm/CollectionDesignManager.java
r7601 r7739 44 44 import org.greenstone.gatherer.cdm.TranslationView; 45 45 import org.greenstone.gatherer.util.GSDLSiteConfig; 46 import org.greenstone.gatherer.util.Utility; 46 47 47 48 /** This manager provides access to submanagers, which in turn provide tools for the designing of Greenstone collections via the information stored in etc/collect.cfg. This class acts as a hub for the managers that handle specific parts of the configuration such as classifiers, format strings and language settings. … … 211 212 ///ystem.err.println("Would have released collection if necessary."); 212 213 boolean collection_released = false; 213 if(format_manager.formatsChanged() && Gatherer.c_man.built() && Gatherer.config.exec_file != null) { 214 String col_name = Gatherer.c_man.getCollection().getName(); 215 boolean formats_changed = format_manager.formatsChanged(); 216 217 if(formats_changed && Gatherer.c_man.built() && Gatherer.config.exec_file != null) { 214 218 // Release the collection 215 Gatherer.self.configServer(GSDLSiteConfig.RELEASE_COMMAND + Gatherer.c_man.getCollection().getName());219 Gatherer.self.configServer(GSDLSiteConfig.RELEASE_COMMAND + col_name); 216 220 // This is very important -- it ensures that the above command has finished 217 221 Gatherer.self.configServer(""); … … 222 226 collect_config.save(); 223 227 228 if (Gatherer.isGsdlRemote) { 229 if(formats_changed && Gatherer.c_man.built()) { 230 // upload etc/collect.cfg to server to reflect changes 231 Utility.zipup(col_name,Utility.CONFIG_FILE); 232 Utility.upload_url_zip(col_name,"etc"); 233 } 234 } 235 224 236 // Readd collection 225 237 ///ystem.err.println("Would have added collection if it had been released."); 226 238 if(collection_released) { 227 // Then re-add itto force format commands to be processed228 Gatherer.self.configServer(GSDLSiteConfig.ADD_COMMAND + Gatherer.c_man.getCollection().getName());239 // Now re-add collection to server to force format commands to be processed 240 Gatherer.self.configServer(GSDLSiteConfig.ADD_COMMAND + col_name); 229 241 // This is very important -- it ensures that the above command has finished 230 242 Gatherer.self.configServer(""); 231 // Unset formats changed 232 format_manager.setFormatsChanged(false); 233 } 234 } 243 } 244 245 if (formats_changed) { 246 // Unset formats changed 247 format_manager.setFormatsChanged(false); 248 } 249 } 235 250 236 251 // /** Ensures that the collection is now public. Useful for collections that are based on another, or that are about to be exported */
Note:
See TracChangeset
for help on using the changeset viewer.