diff --git a/releng/org.eclipse.rse.build/maps/rse.map b/releng/org.eclipse.rse.build/maps/rse.map index 72489b758e7..63895c9b8bc 100644 --- a/releng/org.eclipse.rse.build/maps/rse.map +++ b/releng/org.eclipse.rse.build/maps/rse.map @@ -12,7 +12,7 @@ feature@org.eclipse.rse.ssh=v20080505,:pserver:anonymous:none@dev.eclipse.org:/c feature@org.eclipse.rse.telnet=v20080411,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/features/org.eclipse.rse.telnet-feature feature@org.eclipse.rse.terminals=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/features/org.eclipse.rse.terminals-feature feature@org.eclipse.rse.tests=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/tests/org.eclipse.rse.tests-feature -feature@org.eclipse.rse.useractions=v20080409,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/features/org.eclipse.rse.useractions-feature +feature@org.eclipse.rse.useractions=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/features/org.eclipse.rse.useractions-feature plugin@org.eclipse.dstore.core=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/plugins/org.eclipse.dstore.core plugin@org.eclipse.dstore.doc.isv=v20080411,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/doc/org.eclipse.dstore.doc.isv plugin@org.eclipse.dstore.extra=v20080406,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/plugins/org.eclipse.dstore.extra @@ -61,4 +61,4 @@ plugin@org.eclipse.rse.terminals.ui=v20080505,:pserver:anonymous:none@dev.eclips plugin@org.eclipse.rse.tests=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/tests/org.eclipse.rse.tests plugin@org.eclipse.rse.tests.framework=v20080331,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/tests/org.eclipse.rse.tests.framework plugin@org.eclipse.rse.ui=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/plugins/org.eclipse.rse.ui -plugin@org.eclipse.rse.useractions=v20080409,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/plugins/org.eclipse.rse.useractions \ No newline at end of file +plugin@org.eclipse.rse.useractions=v20080505,:pserver:anonymous:none@dev.eclipse.org:/cvsroot/dsdp,,org.eclipse.tm.rse/plugins/org.eclipse.rse.useractions \ No newline at end of file diff --git a/rse/plugins/org.eclipse.rse.useractions/META-INF/MANIFEST.MF b/rse/plugins/org.eclipse.rse.useractions/META-INF/MANIFEST.MF index 6681c8b2baf..a1f4468a7b1 100644 --- a/rse/plugins/org.eclipse.rse.useractions/META-INF/MANIFEST.MF +++ b/rse/plugins/org.eclipse.rse.useractions/META-INF/MANIFEST.MF @@ -21,6 +21,10 @@ Require-Bundle: org.eclipse.core.resources, Bundle-ActivationPolicy: lazy Eclipse-LazyStart: true Export-Package: org.eclipse.rse.internal.useractions;x-internal:=true, + org.eclipse.rse.internal.useractions.api.files.compile;x-internal:=true, + org.eclipse.rse.internal.useractions.api.files.uda;x-internal:=true, + org.eclipse.rse.internal.useractions.api.ui.compile;x-internal:=true, + org.eclipse.rse.internal.useractions.api.ui.uda;x-internal:=true, org.eclipse.rse.internal.useractions.files.compile;x-internal:=true, org.eclipse.rse.internal.useractions.files.uda;x-internal:=true, org.eclipse.rse.internal.useractions.ui;x-internal:=true, @@ -28,10 +32,6 @@ Export-Package: org.eclipse.rse.internal.useractions;x-internal:=true, org.eclipse.rse.internal.useractions.ui.uda;x-internal:=true, org.eclipse.rse.internal.useractions.ui.uda.actions;x-internal:=true, org.eclipse.rse.internal.useractions.ui.uda.util;x-internal:=true, - org.eclipse.rse.internal.useractions.ui.validators;x-internal:=true, - org.eclipse.rse.useractions.files.compile, - org.eclipse.rse.useractions.files.uda, - org.eclipse.rse.useractions.ui.compile, - org.eclipse.rse.useractions.ui.uda + org.eclipse.rse.internal.useractions.ui.validators;x-internal:=true Bundle-Vendor: %providerName Bundle-RequiredExecutionEnvironment: J2SE-1.4 diff --git a/rse/plugins/org.eclipse.rse.useractions/plugin.xml b/rse/plugins/org.eclipse.rse.useractions/plugin.xml index 162f5d7a38f..dc4ddc199cd 100644 --- a/rse/plugins/org.eclipse.rse.useractions/plugin.xml +++ b/rse/plugins/org.eclipse.rse.useractions/plugin.xml @@ -7,7 +7,7 @@ - @@ -24,7 +24,7 @@ - diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/ISystemCompileManagerAdapter.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/ISystemCompileManagerAdapter.java similarity index 62% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/ISystemCompileManagerAdapter.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/ISystemCompileManagerAdapter.java index a2d9ffac6bf..c67f6a270bf 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/ISystemCompileManagerAdapter.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/ISystemCompileManagerAdapter.java @@ -1,18 +1,26 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.files.compile; +package org.eclipse.rse.internal.useractions.api.files.compile; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileManager; - +/** + * Compile Manager Adapter Interface. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ public interface ISystemCompileManagerAdapter { public SystemCompileManager getSystemCompileManager(ISubSystemConfiguration ssc); diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/UniversalCompileManagerAdapter.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/UniversalCompileManagerAdapter.java similarity index 74% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/UniversalCompileManagerAdapter.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/UniversalCompileManagerAdapter.java index fe3e8b5652d..b99e453ba82 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/compile/UniversalCompileManagerAdapter.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/compile/UniversalCompileManagerAdapter.java @@ -1,13 +1,13 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.files.compile; +package org.eclipse.rse.internal.useractions.api.files.compile; import java.util.HashMap; @@ -15,13 +15,22 @@ import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.files.compile.UniversalCompileManager; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileManager; +/** + * Universal Compile Manager Adapter. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ public class UniversalCompileManagerAdapter implements ISystemCompileManagerAdapter { private HashMap compileManagers = new HashMap(); - + public SystemCompileManager getSystemCompileManager(ISubSystemConfiguration ssc) { String configID = ssc.getId(); - + SystemCompileManager thisCompileManager = (SystemCompileManager)compileManagers.get(configID); if (thisCompileManager == null) { @@ -29,7 +38,7 @@ public class UniversalCompileManagerAdapter implements thisCompileManager.setSubSystemFactory(ssc); compileManagers.put(configID, thisCompileManager); } - + return thisCompileManager; } diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/ISystemUDActionSubsystemAdapter.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/ISystemUDActionSubsystemAdapter.java similarity index 62% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/ISystemUDActionSubsystemAdapter.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/ISystemUDActionSubsystemAdapter.java index 0fe0b65be71..9cc1d36ca3f 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/ISystemUDActionSubsystemAdapter.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/ISystemUDActionSubsystemAdapter.java @@ -1,18 +1,27 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.files.uda; +package org.eclipse.rse.internal.useractions.api.files.uda; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.ui.uda.SystemUDActionSubsystem; +/** + * User-defined Action Subsystem Adapter Interface. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ public interface ISystemUDActionSubsystemAdapter { public SystemUDActionSubsystem getSystemUDActionSubsystem(ISubSystemConfiguration ssc); diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/UniversalSystemUDActionSubsystemAdapter.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/UniversalSystemUDActionSubsystemAdapter.java similarity index 74% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/UniversalSystemUDActionSubsystemAdapter.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/UniversalSystemUDActionSubsystemAdapter.java index ab4706a4750..12247ee1ab9 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/files/uda/UniversalSystemUDActionSubsystemAdapter.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/files/uda/UniversalSystemUDActionSubsystemAdapter.java @@ -1,13 +1,13 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.files.uda; +package org.eclipse.rse.internal.useractions.api.files.uda; import java.util.HashMap; @@ -15,12 +15,21 @@ import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.files.uda.UDActionSubsystemUniversalFiles; import org.eclipse.rse.internal.useractions.ui.uda.SystemUDActionSubsystem; +/** + * Universal User-defined Action Subsystem Adapter. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ public class UniversalSystemUDActionSubsystemAdapter implements ISystemUDActionSubsystemAdapter { private HashMap uDActionSubsystems = new HashMap(); - + public SystemUDActionSubsystem getSystemUDActionSubsystem(ISubSystemConfiguration ssc) { String configID = ssc.getId(); - + SystemUDActionSubsystem thisuDActionSubsystem = (SystemUDActionSubsystem)uDActionSubsystems.get(configID); if (thisuDActionSubsystem == null) { @@ -28,7 +37,7 @@ public class UniversalSystemUDActionSubsystemAdapter implements ISystemUDActionS thisuDActionSubsystem.setSubSystemFactory(ssc); uDActionSubsystems.put(configID, thisuDActionSubsystem); } - + return thisuDActionSubsystem; } diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCascadingCompileAction.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCascadingCompileAction.java similarity index 91% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCascadingCompileAction.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCascadingCompileAction.java index 26368e67c5b..5503bde0dc6 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCascadingCompileAction.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCascadingCompileAction.java @@ -9,7 +9,7 @@ * IBM Corporation - initial API and implementation * Martin Oberhuber (Wind River) - [186773] split ISystemRegistryUI from ISystemRegistry *******************************************************************************/ -package org.eclipse.rse.useractions.ui.compile; +package org.eclipse.rse.internal.useractions.api.ui.compile; import org.eclipse.jface.action.IMenuListener; import org.eclipse.jface.action.IMenuManager; @@ -28,6 +28,12 @@ import org.eclipse.swt.widgets.Shell; /** * Cascading Compile-> menu for remote compilable resources. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

*/ public class SystemCascadingCompileAction extends SystemBaseSubMenuAction implements IMenuListener { private boolean isPrompt; diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCompileAction.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCompileAction.java similarity index 93% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCompileAction.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCompileAction.java index 0769c5b62c9..85563fdf3ec 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemCompileAction.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemCompileAction.java @@ -8,10 +8,10 @@ * Contributors: * IBM Corporation - initial API and implementation * Martin Oberhuber (Wind River) - [168870] refactor org.eclipse.rse.core package of the UI plugin - * David Dykstal (IBM) - [186589] move user actions API out of org.eclipse.rse.ui + * David Dykstal (IBM) - [186589] move user actions API out of org.eclipse.rse.ui * David McKnight (IBM) - [225506] [api][breaking] RSE UI leaks non-API types *******************************************************************************/ -package org.eclipse.rse.useractions.ui.compile; +package org.eclipse.rse.internal.useractions.api.ui.compile; import java.util.ArrayList; import java.util.List; @@ -38,15 +38,22 @@ import org.eclipse.ui.model.AdaptableList; import org.eclipse.ui.model.WorkbenchContentProvider; /** - * This is the action for an individual compile command, either prompted or not prompted. - * The label for the action is simply the compile command's label. If promptable, then "..." is appended. + * This is the action for an individual compile command, either prompted or not + * prompted. The label for the action is simply the compile command's label. If + * promptable, then "..." is appended. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

*/ public class SystemCompileAction extends SystemBaseAction { private SystemCompileCommand compileCmd; private boolean isPrompt; /** - * Constructor + * Constructor */ public SystemCompileAction(Shell shell, SystemCompileCommand compileCommand, boolean isPrompt) { super( diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemDynamicCompileMenu.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemDynamicCompileMenu.java similarity index 88% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemDynamicCompileMenu.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemDynamicCompileMenu.java index 4cf34ac3a0d..a8561429cc8 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemDynamicCompileMenu.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemDynamicCompileMenu.java @@ -1,13 +1,13 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.ui.compile; +package org.eclipse.rse.internal.useractions.api.ui.compile; import java.util.ArrayList; @@ -22,6 +22,7 @@ import org.eclipse.rse.core.RSECorePlugin; import org.eclipse.rse.core.model.ISystemProfile; import org.eclipse.rse.core.subsystems.ISubSystem; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; +import org.eclipse.rse.internal.useractions.api.files.compile.ISystemCompileManagerAdapter; import org.eclipse.rse.internal.useractions.files.compile.UniversalCompileManager; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileCommand; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileManager; @@ -31,25 +32,33 @@ import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile; import org.eclipse.rse.ui.SystemBasePlugin; import org.eclipse.rse.ui.view.ISystemRemoteElementAdapter; import org.eclipse.rse.ui.view.SystemAdapterHelpers; -import org.eclipse.rse.useractions.files.compile.ISystemCompileManagerAdapter; import org.eclipse.swt.widgets.Shell; import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.ui.PlatformUI; import org.eclipse.ui.actions.CompoundContributionItem; -public class SystemDynamicCompileMenu extends CompoundContributionItem +/** + * Dynamic Compile Menu. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ +public class SystemDynamicCompileMenu extends CompoundContributionItem { private class TestContribution extends ActionContributionItem { - + public TestContribution(Action action) { super(action); } - + /* - public void fill(Menu menu, int index) + public void fill(Menu menu, int index) { - + MenuItem menuItem = new MenuItem(menu, SWT.RADIO); menuItem.setText("My First Contribution"); } @@ -57,9 +66,9 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem } protected IContributionItem[] getContributionItems() { - + ArrayList returnedItemList = new ArrayList(); - + ISystemProfile[] activeProfiles = RSECorePlugin.getTheSystemRegistry().getActiveSystemProfiles(); IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow(); ISelection selection = window.getSelectionService().getSelection(); @@ -69,13 +78,13 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem return new IContributionItem[0]; } Shell shell = SystemBasePlugin.getActiveWorkbenchShell(); - + ISystemRemoteElementAdapter rmtAdapter = SystemAdapterHelpers.getRemoteAdapter(firstSelection); ISubSystem subsystem = rmtAdapter.getSubSystem(firstSelection); ISubSystemConfiguration ssc = subsystem.getSubSystemConfiguration(); - + SystemCompileManager compileManager = null; - + if (firstSelection instanceof IAdaptable) { ISystemCompileManagerAdapter adapter = (ISystemCompileManagerAdapter)((IAdaptable)firstSelection).getAdapter(ISystemCompileManagerAdapter.class); if (null != adapter) @@ -83,13 +92,13 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem compileManager = adapter.getSystemCompileManager(ssc); } } - + if (null == compileManager) { compileManager = new UniversalCompileManager(); compileManager.setSubSystemFactory(ssc); } - + for (int idx = 0; idx < activeProfiles.length; idx++) { String srcType = null; @@ -99,15 +108,15 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem srcType = "null"; //$NON-NLS-1$ else if (srcType.equals("")) //$NON-NLS-1$ srcType = "blank"; //$NON-NLS-1$ - } - + } + if (null != compileManager) { SystemCompileManager thisCompileManager = compileManager; SystemCompileProfile compileProfile = thisCompileManager.getCompileProfile(activeProfiles[idx]); // compileProfile.addContributions(firstSelection); SystemCompileType compileType = compileProfile.getCompileType(srcType); - + if (compileType != null) { SystemCompileCommand[] cmds = compileType.getCompileCommandsArray(); @@ -121,15 +130,15 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem } } } - + } - + // add a separator before Work With Compile Commands... menu item //ourSubMenu.add(new Separator()); // add Work With Commands... action - if (returnedItemList.size() > 0) - returnedItemList.add(new Separator()); - + if (returnedItemList.size() > 0) + returnedItemList.add(new Separator()); + // Here's where you would dynamically generate your list SystemWorkWithCompileCommandsAction workWithCompileCommandAction = new SystemWorkWithCompileCommandsAction(shell, true, subsystem, compileManager); workWithCompileCommandAction.setSelection(selection); @@ -143,4 +152,4 @@ public class SystemDynamicCompileMenu extends CompoundContributionItem return list; } -} \ No newline at end of file +} diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemWorkWithCompileCommandsAction.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemWorkWithCompileCommandsAction.java similarity index 92% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemWorkWithCompileCommandsAction.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemWorkWithCompileCommandsAction.java index 954db0d1eb2..e728a885a59 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/compile/SystemWorkWithCompileCommandsAction.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/compile/SystemWorkWithCompileCommandsAction.java @@ -12,7 +12,7 @@ * API to the user actions plugin * Xuan Chen (IBM) - [225617] [useraction][api] Remove Team view support inside user action. *******************************************************************************/ -package org.eclipse.rse.useractions.ui.compile; +package org.eclipse.rse.internal.useractions.api.ui.compile; import org.eclipse.core.runtime.IAdaptable; import org.eclipse.jface.dialogs.Dialog; @@ -21,6 +21,7 @@ import org.eclipse.rse.core.model.ISystemProfile; import org.eclipse.rse.core.subsystems.ISubSystem; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.IUserActionsImageIds; +import org.eclipse.rse.internal.useractions.api.files.compile.ISystemCompileManagerAdapter; import org.eclipse.rse.internal.useractions.files.compile.UniversalCompileManager; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileManager; import org.eclipse.rse.internal.useractions.ui.compile.SystemCompileProfile; @@ -31,19 +32,24 @@ import org.eclipse.rse.ui.RSEUIPlugin; import org.eclipse.rse.ui.actions.SystemBaseDialogAction; import org.eclipse.rse.ui.view.ISystemRemoteElementAdapter; import org.eclipse.rse.ui.view.SystemAdapterHelpers; -import org.eclipse.rse.useractions.files.compile.ISystemCompileManagerAdapter; import org.eclipse.swt.widgets.Shell; /** * The action that displays the Work With -> Compile Commands menu item + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

*/ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction { - + private ISubSystem subsystem = null; private ISubSystemConfiguration subsystemFactory = null; private ISystemProfile profile = null; private SystemCompileManager compileManager = null; - + /** * Constructor * @param shell The Shell of the parent UI for this dialog @@ -61,7 +67,7 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction setHelp(RSEUIPlugin.HELPPREFIX + "actnwwcc"); //$NON-NLS-1$ setAvailableOffline(true); } - + public SystemWorkWithCompileCommandsAction(Shell shell, boolean fromCascadingCompileAction, ISubSystem subSystem, SystemCompileManager compileManager) { this(shell, fromCascadingCompileAction); @@ -72,7 +78,7 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction subsystemFactory = subsystem.getSubSystemConfiguration(); profile = subSystem.getSystemProfile(); } - + } /** @@ -117,7 +123,7 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction subsystemFactory = ((SystemTeamViewSubSystemConfigurationNode) inputObject).getSubSystemConfiguration(); profile = ((SystemTeamViewSubSystemConfigurationNode) inputObject).getProfile(); } - */ + */ else { ISystemRemoteElementAdapter rmtAdapter = SystemAdapterHelpers.getRemoteAdapter(inputObject); if (rmtAdapter != null) subsystem = rmtAdapter.getSubSystem(inputObject); @@ -130,9 +136,9 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction if (subsystemFactory == null) subsystemFactory = subsystem.getSubSystemConfiguration(); if (profile == null) profile = subsystem.getSystemProfile(); } - - if (null == compileManager) - { + + if (null == compileManager) + { if (inputObject instanceof IAdaptable) { ISystemCompileManagerAdapter adapter = (ISystemCompileManagerAdapter)((IAdaptable)inputObject).getAdapter(ISystemCompileManagerAdapter.class); if (null != adapter) @@ -141,13 +147,13 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction } } } - + if (null == compileManager) { compileManager = new UniversalCompileManager(); compileManager.setSubSystemFactory(subsystemFactory); } - + if (null != compileManager) { if (profile != null) @@ -155,9 +161,9 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction currProfile = compileManager.getCompileProfile(profile); currProfiles = compileManager.getAllCompileProfiles(); } - + caseSensitive = subsystemFactory.isCaseSensitive(); - + SystemWorkWithCompileCommandsDialog dlg = new SystemWorkWithCompileCommandsDialog(shell, compileManager, currProfile); /* FIXME - currProfiles cannot be null since above stuff was commented out if (currProfiles != null) { @@ -166,7 +172,7 @@ public class SystemWorkWithCompileCommandsAction extends SystemBaseDialogAction */ dlg.setProfiles(currProfiles); dlg.setCaseSensitive(caseSensitive); - + return dlg; } return null; diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/uda/SystemDynamicUserActionMenu.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/uda/SystemDynamicUserActionMenu.java similarity index 88% rename from rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/uda/SystemDynamicUserActionMenu.java rename to rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/uda/SystemDynamicUserActionMenu.java index e4231737a24..a46fbb98db2 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/useractions/ui/uda/SystemDynamicUserActionMenu.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/api/ui/uda/SystemDynamicUserActionMenu.java @@ -1,13 +1,13 @@ /********************************************************************************* * Copyright (c) 2008 IBM Corporation. All rights reserved. * This program and the accompanying materials are made available under the terms - * of the Eclipse Public License v1.0 which accompanies this distribution, and is + * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Xuan Chen (IBM) - [222470] initial contribution. *********************************************************************************/ -package org.eclipse.rse.useractions.ui.uda; +package org.eclipse.rse.internal.useractions.api.ui.uda; import java.util.ArrayList; @@ -22,6 +22,7 @@ import org.eclipse.rse.core.RSECorePlugin; import org.eclipse.rse.core.model.ISystemProfile; import org.eclipse.rse.core.subsystems.ISubSystem; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; +import org.eclipse.rse.internal.useractions.api.files.uda.ISystemUDActionSubsystemAdapter; import org.eclipse.rse.internal.useractions.files.uda.UDActionSubsystemUniversalFiles; import org.eclipse.rse.internal.useractions.ui.uda.SystemUDAResources; import org.eclipse.rse.internal.useractions.ui.uda.SystemUDActionSubsystem; @@ -30,25 +31,33 @@ import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile; import org.eclipse.rse.ui.SystemBasePlugin; import org.eclipse.rse.ui.view.ISystemRemoteElementAdapter; import org.eclipse.rse.ui.view.SystemAdapterHelpers; -import org.eclipse.rse.useractions.files.uda.ISystemUDActionSubsystemAdapter; import org.eclipse.swt.widgets.Shell; import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.ui.PlatformUI; import org.eclipse.ui.actions.CompoundContributionItem; -public class SystemDynamicUserActionMenu extends CompoundContributionItem +/** + * Dynamic User-defined Action Menu. + *

+ * EXPERIMENTAL. This class or interface has been added as part + * of a work in progress. There is no guarantee that this API will work or that + * it will remain the same. Please do not use this API without consulting with + * the Target Management team. + *

+ */ +public class SystemDynamicUserActionMenu extends CompoundContributionItem { private class UserActionContribution extends ActionContributionItem { - + public UserActionContribution(Action action) { super(action); } - + /* - public void fill(Menu menu, int index) + public void fill(Menu menu, int index) { - + MenuItem menuItem = new MenuItem(menu, SWT.RADIO); menuItem.setText("My First Contribution"); } @@ -56,9 +65,9 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem } protected IContributionItem[] getContributionItems() { - + ArrayList returnedItemList = new ArrayList(); - + ISystemProfile[] activeProfiles = RSECorePlugin.getTheSystemRegistry().getActiveSystemProfiles(); IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow(); ISelection selection = window.getSelectionService().getSelection(); @@ -68,12 +77,12 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem return new IContributionItem[0]; } ISystemRemoteElementAdapter rmtAdapter = SystemAdapterHelpers.getRemoteAdapter(firstSelection); - + ISubSystem subsystem = rmtAdapter.getSubSystem(firstSelection); ISubSystemConfiguration ssc = subsystem.getSubSystemConfiguration(); - + SystemUDActionSubsystem systemUDActionSubsystem = null; - + if (firstSelection instanceof IAdaptable) { ISystemUDActionSubsystemAdapter adapter = (ISystemUDActionSubsystemAdapter)((IAdaptable)firstSelection).getAdapter(ISystemUDActionSubsystemAdapter.class); if (null != adapter) @@ -82,14 +91,14 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem systemUDActionSubsystem.setSubsystem(subsystem); } } - + if (null == systemUDActionSubsystem) { systemUDActionSubsystem = new UDActionSubsystemUniversalFiles(); systemUDActionSubsystem.setSubSystemFactory(ssc); systemUDActionSubsystem.setSubsystem(subsystem); } - + Shell shell = SystemBasePlugin.getActiveWorkbenchShell(); for (int idx = 0; idx < activeProfiles.length; idx++) { @@ -98,7 +107,7 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem if (null != systemUDActionSubsystem) { Action[] list = systemUDActionSubsystem.addUserActions(null, (IStructuredSelection)selection, activeProfiles[idx], shell); - + for (int i = 0; i < list.length; i++) { UserActionContribution testContribution = new UserActionContribution(list[i]); @@ -106,13 +115,13 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem } } } - + // add a separator before Work With Compile Commands... menu item //ourSubMenu.add(new Separator()); // add Work With Commands... action if (returnedItemList.size() > 0) - returnedItemList.add(new Separator()); - + returnedItemList.add(new Separator()); + SystemWorkWithUDAsAction wwAction; wwAction = new SystemWorkWithUDAsAction(shell, systemUDActionSubsystem.getSubsystem(), systemUDActionSubsystem); wwAction.setText(SystemUDAResources.RESID_WORKWITH_UDAS_ACTION_LABEL); @@ -121,9 +130,9 @@ public class SystemDynamicUserActionMenu extends CompoundContributionItem wwAction.setSelection(selection); UserActionContribution userActionContribution = new UserActionContribution(wwAction); returnedItemList.add(userActionContribution); - + IContributionItem[] list = (IContributionItem[])returnedItemList.toArray(new IContributionItem[]{}); return list; } -} \ No newline at end of file +} diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileCascadeByProfileAction.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileCascadeByProfileAction.java index a14ffa36ce5..a2742d3874b 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileCascadeByProfileAction.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileCascadeByProfileAction.java @@ -20,6 +20,8 @@ import org.eclipse.rse.core.model.ISystemProfile; import org.eclipse.rse.core.subsystems.ISubSystem; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.ui.view.SystemViewMenuListener; +import org.eclipse.rse.internal.useractions.api.files.compile.ISystemCompileManagerAdapter; +import org.eclipse.rse.internal.useractions.api.ui.compile.SystemCompileAction; import org.eclipse.rse.ui.ISystemIconConstants; import org.eclipse.rse.ui.RSEUIPlugin; import org.eclipse.rse.ui.actions.ISystemViewMenuListener; @@ -27,8 +29,6 @@ import org.eclipse.rse.ui.actions.SystemBaseDummyAction; import org.eclipse.rse.ui.actions.SystemBaseSubMenuAction; import org.eclipse.rse.ui.view.ISystemRemoteElementAdapter; import org.eclipse.rse.ui.view.SystemAdapterHelpers; -import org.eclipse.rse.useractions.files.compile.ISystemCompileManagerAdapter; -import org.eclipse.rse.useractions.ui.compile.SystemCompileAction; import org.eclipse.swt.widgets.Shell; /** diff --git a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileManager.java b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileManager.java index 4d7bac6a7c7..3f81d6bb7cf 100644 --- a/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileManager.java +++ b/rse/plugins/org.eclipse.rse.useractions/src/org/eclipse/rse/internal/useractions/ui/compile/SystemCompileManager.java @@ -25,6 +25,7 @@ import org.eclipse.rse.core.model.IHost; import org.eclipse.rse.core.model.ISystemProfile; import org.eclipse.rse.core.subsystems.ISubSystemConfiguration; import org.eclipse.rse.internal.useractions.UserActionsPersistenceUtil; +import org.eclipse.rse.internal.useractions.api.ui.compile.SystemCascadingCompileAction; import org.eclipse.rse.internal.useractions.ui.SystemCmdSubstVarList; import org.eclipse.rse.internal.useractions.ui.uda.SystemUDAResources; import org.eclipse.rse.services.clientserver.messages.SystemMessage; @@ -36,7 +37,6 @@ import org.eclipse.rse.ui.SystemMenuManager; import org.eclipse.rse.ui.messages.SystemMessageDialog; import org.eclipse.rse.ui.view.ISystemRemoteElementAdapter; import org.eclipse.rse.ui.view.SystemAdapterHelpers; -import org.eclipse.rse.useractions.ui.compile.SystemCascadingCompileAction; import org.eclipse.swt.widgets.Shell; /**