public void saveToFile( File catalogLocation, IServiceFactory factory, IProgressMonitor monitor ) {
try {
Preferences toSave = Platform.getPreferencesService().getRootNode().node(
CatalogPlugin.ID).node("LOCAL_CATALOG_SERVICES"); //$NON-NLS-1$
if (services != null) {
ServiceParameterPersister persister = new ServiceParameterPersister(this, factory,
catalogLocation.getParentFile());
persister.store(monitor, toSave, services);
}
FileOutputStream out = new FileOutputStream(catalogLocation);
Platform.getPreferencesService().exportPreferences((IEclipsePreferences) toSave, out,
null);