1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

cosmetics: PLUGIN_ID made public, enhanced loops and other warnings

This commit is contained in:
Andrew Gvozdev 2010-01-18 21:50:22 +00:00
parent cddcfe7160
commit 72c4ef20af

View file

@ -35,7 +35,7 @@ import org.osgi.framework.BundleContext;
public class ManagedBuilderCorePlugin extends Plugin { public class ManagedBuilderCorePlugin extends Plugin {
private static final String PLUGIN_ID = "org.eclipse.cdt.managedbuilder.core"; //$NON-NLS-1$ public static final String PLUGIN_ID = "org.eclipse.cdt.managedbuilder.core"; //$NON-NLS-1$
// The shared instance // The shared instance
private static ManagedBuilderCorePlugin plugin; private static ManagedBuilderCorePlugin plugin;
// The attribute name for the makefile generator // The attribute name for the makefile generator
@ -51,9 +51,6 @@ public class ManagedBuilderCorePlugin extends Plugin {
// private DiscoveredPathManager fDiscoveryPathManager; // private DiscoveredPathManager fDiscoveryPathManager;
/**
* @param descriptor
*/
public ManagedBuilderCorePlugin() { public ManagedBuilderCorePlugin() {
super(); super();
plugin = this; plugin = this;
@ -70,7 +67,7 @@ public class ManagedBuilderCorePlugin extends Plugin {
} }
/** /**
* Returns the shared instance. * @return the shared instance.
*/ */
public static ManagedBuilderCorePlugin getDefault() { public static ManagedBuilderCorePlugin getDefault() {
return plugin; return plugin;
@ -79,6 +76,7 @@ public class ManagedBuilderCorePlugin extends Plugin {
/* (non-Javadoc) /* (non-Javadoc)
* @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext)
*/ */
@Override
public void start(BundleContext context) throws Exception { public void start(BundleContext context) throws Exception {
// Turn on logging for plugin when debugging // Turn on logging for plugin when debugging
super.start(context); super.start(context);
@ -168,6 +166,7 @@ public class ManagedBuilderCorePlugin extends Plugin {
/* (non-Javadoc) /* (non-Javadoc)
* @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext)
*/ */
@Override
public void stop(BundleContext context) throws Exception { public void stop(BundleContext context) throws Exception {
BuildStateManager.getInstance().shutdown(); BuildStateManager.getInstance().shutdown();
@ -184,8 +183,8 @@ public class ManagedBuilderCorePlugin extends Plugin {
// elements // elements
ResourcesPlugin.getWorkspace().removeResourceChangeListener(listener); ResourcesPlugin.getWorkspace().removeResourceChangeListener(listener);
IProject projects[] = ResourcesPlugin.getWorkspace().getRoot().getProjects(); IProject projects[] = ResourcesPlugin.getWorkspace().getRoot().getProjects();
for(int i = 0; i < projects.length; i++){ for (IProject project : projects) {
listener.sendClose(projects[i]); listener.sendClose(project);
} }
listener = null; listener = null;
super.stop(context); super.stop(context);
@ -253,7 +252,7 @@ public class ManagedBuilderCorePlugin extends Plugin {
} }
} }
public static IBuilder[] createBuilders(IProject project, Map args){ public static IBuilder[] createBuilders(IProject project, Map<String, String> args){
return BuilderFactory.createBuilders(project, args); return BuilderFactory.createBuilders(project, args);
} }