Examples of IExportedPreferences


Examples of org.eclipse.core.runtime.preferences.IExportedPreferences

                WorkbenchPlugin.log(e.getMessage(), e);
                return new PreferenceTransferElement[0];
            }
            IPreferencesService service = Platform.getPreferencesService();
            try {
                IExportedPreferences prefs;
                prefs = service.readPreferences(fis);
                PreferenceTransferElement[] transfers = super.getTransfers();
                IPreferenceFilter[] filters = new IPreferenceFilter[transfers.length];
                for (int i = 0; i < transfers.length; i++) {
                    PreferenceTransferElement transfer = transfers[i];
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.IExportedPreferences

                    MessageDialog.openError(getControl().getShell(), new String(), e.getLocalizedMessage());
                    return false;
                }
                IPreferencesService service = Platform.getPreferencesService();
                try {
                    IExportedPreferences prefs = service.readPreferences(fis);
                   
                    service.applyPreferences(prefs, filters);
                } catch (CoreException e) {
                    WorkbenchPlugin.log(e.getMessage(), e);
                    MessageDialog.openError(getControl().getShell(), new String(), e.getLocalizedMessage());
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.IExportedPreferences

        }

        ByteArrayInputStream input = new ByteArrayInputStream(decoded.getBytes());
        try {
            IPreferencesService preferencesService = Platform.getPreferencesService();
            IExportedPreferences paramsNode = preferencesService.readPreferences(input);

            ServiceParameterPersister persister = new LayerCatalogRefPersister(connectionParams,
                    null);

            persister.restore(findParameterNode(paramsNode));
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.IExportedPreferences

    public void loadFromFile( File catalogLocation, IServiceFactory factory ) {
        try {
            FileInputStream input = new FileInputStream(catalogLocation);
            IPreferencesService preferencesService = Platform.getPreferencesService();
            IExportedPreferences paramsNode = preferencesService.readPreferences(input);

            ServiceParameterPersister persister = new ServiceParameterPersister(this, factory, catalogLocation);
            Preferences parameterNode = findParameterNode(paramsNode);
           
            persister.restore(parameterNode);
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.IExportedPreferences

    Properties fromDisk = loadProperties(file);
    // no work to do
    if (fromDisk.isEmpty())
      return;
    // create a new node to store the preferences in.
    IExportedPreferences myNode = (IExportedPreferences) ExportedPreferences.newRoot().node(node.absolutePath());
    convertFromProperties((EclipsePreferences) myNode, fromDisk, false);
    //flag that we are currently reading, to avoid unnecessary writing
    boolean oldIsReading = node.isReading;
    node.isReading = true;
    try {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.