01: /*******************************************************************************
02: * Copyright (c) 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: ******************************************************************************/package org.eclipse.ui.preferences;
11:
12: import org.eclipse.core.runtime.IConfigurationElement;
13: import org.eclipse.core.runtime.IPath;
14: import org.eclipse.core.runtime.IStatus;
15: import org.eclipse.ui.internal.preferences.SettingsTransferRegistryReader;
16:
17: /**
18: * The SettingsTransfer is the abstract superclass of settings transfers
19: * used when switching workspaces.
20: * @since 3.3
21: *
22: */
23: public abstract class SettingsTransfer {
24:
25: /**
26: * Return the configuration elements for all of the settings
27: * transfers.
28: * @return IConfigurationElement[]
29: */
30: public static IConfigurationElement[] getSettingsTransfers() {
31: return (new SettingsTransferRegistryReader())
32: .getSettingTransfers();
33: }
34:
35: /**
36: * Transfer the settings to a workspace rooted at newWorkspacwe
37: * @param newWorkspaceRoot
38: * @return {@link IStatus} the status of the transfer.
39: */
40: public abstract IStatus transferSettings(IPath newWorkspaceRoot);
41:
42: /**
43: * Return the name for the receiver.
44: * @return String
45: */
46: public abstract String getName();
47:
48: }
|