Cleanup warning in o.e.dltk.ruby.launching.
* Add missing @Override annotations.
* Remove useless cast.
Change-Id: Ifd366bfe2a4784e32b923d37d3f7053c99ba6ac9
Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/JRubyInstallType.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/JRubyInstallType.java
index cc021d4..3947374 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/JRubyInstallType.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/JRubyInstallType.java
@@ -23,27 +23,33 @@
return INSTALL_TYPE_NAME;
}
+ @Override
protected String getPluginId() {
return RubyLaunchingPlugin.PLUGIN_ID;
}
+ @Override
protected String[] getPossibleInterpreterNames() {
return INTERPRETER_NAMES;
}
+ @Override
protected IInterpreterInstall doCreateInterpreterInstall(String id) {
return new RubyGenericInstall(this, id);
}
+ @Override
protected IPath createPathFile(IDeployment deployment) throws IOException {
return deployment.add(RubyLaunchingPlugin.getDefault().getBundle(),
"scripts/path.rb"); //$NON-NLS-1$
}
+ @Override
protected String getBuildPathDelimeter() {
return ";:"; //$NON-NLS-1$
}
+ @Override
protected ILog getLog() {
return RubyLaunchingPlugin.getDefault().getLog();
}
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstall.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstall.java
index d536c40..8177714 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstall.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstall.java
@@ -1,11 +1,10 @@
/*******************************************************************************
- * Copyright (c) 2005, 2007 IBM Corporation and others.
+ * Copyright (c) 2005, 2016 IBM Corporation and others.
* 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 available at
* http://www.eclipse.org/legal/epl-v10.html
*
-
*******************************************************************************/
package org.eclipse.dltk.ruby.internal.launching;
@@ -172,8 +171,7 @@
if (lines != null) {
parseLines(lines);
if (content != null) {
- content = (InterpreterGeneratedContent) EcoreUtil
- .copy(content);
+ content = EcoreUtil.copy(content);
content.setFetchedAt(new Date());
if (!lines.equals(content.getValue())) {
content.getValue().clear();
@@ -213,6 +211,7 @@
super(type, id);
}
+ @Override
public IInterpreterRunner getInterpreterRunner(String mode) {
final IInterpreterRunner runner = super.getInterpreterRunner(mode);
@@ -227,21 +226,25 @@
return null;
}
+ @Override
public String getNatureId() {
return RubyNature.NATURE_ID;
}
// Builtins
+ @Override
public String getBuiltinModuleContent(String name) {
final Map<String, String> sources = helper.getSources();
return sources.get(name);
}
+ @Override
public long lastModified() {
helper.getSources();
return helper.lastModified;
}
+ @Override
public String[] getBuiltinModules() {
final Map<String, String> sources = helper.getSources();
return sources.keySet().toArray(new String[sources.size()]);
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstallType.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstallType.java
index de10aff..71b765d 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstallType.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyGenericInstallType.java
@@ -1,11 +1,10 @@
/*******************************************************************************
- * Copyright (c) 2005, 2007 IBM Corporation and others.
+ * Copyright (c) 2005, 2016 IBM Corporation and others.
* 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 available at
* http://www.eclipse.org/legal/epl-v10.html
*
-
*******************************************************************************/
package org.eclipse.dltk.ruby.internal.launching;
@@ -42,23 +41,28 @@
return INSTALL_TYPE_NAME;
}
+ @Override
protected String getPluginId() {
return RubyLaunchingPlugin.PLUGIN_ID;
}
+ @Override
protected String[] getPossibleInterpreterNames() {
return INTERPRETER_NAMES;
}
+ @Override
protected IInterpreterInstall doCreateInterpreterInstall(String id) {
return new RubyGenericInstall(this, id);
}
+ @Override
protected IPath createPathFile(IDeployment deployment) throws IOException {
return deployment.add(RubyLaunchingPlugin.getDefault().getBundle(),
"scripts/path.rb"); //$NON-NLS-1$
}
+ @Override
public IStatus validateInstallLocation(IFileHandle installLocation) {
if (!installLocation.exists() || !installLocation.isFile()) {
return createStatus(IStatus.ERROR,
@@ -89,10 +93,12 @@
}
}
+ @Override
protected String getBuildPathDelimeter() {
return ";:"; //$NON-NLS-1$
}
+ @Override
protected ILog getLog() {
return RubyLaunchingPlugin.getDefault().getLog();
}
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyInterpreterRunner.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyInterpreterRunner.java
index 90b2dd9..c527316 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyInterpreterRunner.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyInterpreterRunner.java
@@ -1,11 +1,10 @@
/*******************************************************************************
- * Copyright (c) 2000, 2007 IBM Corporation and others.
+ * Copyright (c) 2000, 2016 IBM Corporation and others.
* 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 available at
* http://www.eclipse.org/legal/epl-v10.html
*
-
*******************************************************************************/
package org.eclipse.dltk.ruby.internal.launching;
@@ -18,6 +17,7 @@
super(install);
}
+ @Override
protected String getProcessType() {
return RubyLaunchConfigurationConstants.ID_RUBY_PROCESS_TYPE;
}
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyRemoteDebuggerRunner.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyRemoteDebuggerRunner.java
index 419d02b..b8afd9d 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyRemoteDebuggerRunner.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/internal/launching/RubyRemoteDebuggerRunner.java
@@ -13,6 +13,7 @@
/*
* @see org.eclipse.dltk.launching.DebuggingEngineRunner#getDebugPreferenceQualifier()
*/
+ @Override
protected String getDebugPreferenceQualifier() {
return RubyDebugPlugin.PLUGIN_ID;
}
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyDebuggingEngineSelector.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyDebuggingEngineSelector.java
index af85eb9..bf1f19c 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyDebuggingEngineSelector.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyDebuggingEngineSelector.java
@@ -13,6 +13,7 @@
/*
* @see org.eclipse.dltk.core.DLTKIdContributionSelector#getSavedContributionId(org.eclipse.dltk.core.PreferencesLookupDelegate)
*/
+ @Override
protected String getSavedContributionId(PreferencesLookupDelegate delegate) {
return delegate.getString(RubyDebugPlugin.PLUGIN_ID,
RubyDebugConstants.DEBUGGING_ENGINE_ID_KEY);
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPlugin.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPlugin.java
index d8d882a..1e180c2 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPlugin.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPlugin.java
@@ -1,11 +1,10 @@
/*******************************************************************************
- * Copyright (c) 2005, 2007 IBM Corporation and others.
+ * Copyright (c) 2005, 2016 IBM Corporation and others.
* 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 available at
* http://www.eclipse.org/legal/epl-v10.html
*
-
*******************************************************************************/
package org.eclipse.dltk.ruby.launching;
@@ -27,10 +26,12 @@
plugin = this;
}
+ @Override
public void start(BundleContext context) throws Exception {
super.start(context);
}
+ @Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPluginPreferenceInitializer.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPluginPreferenceInitializer.java
index f2fd5f2..09e5db6 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPluginPreferenceInitializer.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyLaunchingPluginPreferenceInitializer.java
@@ -10,6 +10,7 @@
super();
}
+ @Override
public void initializeDefaultPreferences() {
final Preferences prefs = RubyLaunchingPlugin.getDefault()
.getPluginPreferences();
diff --git a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyRemoteLaunchConfigurationDelegate.java b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyRemoteLaunchConfigurationDelegate.java
index 0a8972d..cce051c 100644
--- a/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyRemoteLaunchConfigurationDelegate.java
+++ b/plugins/org.eclipse.dltk.ruby.launching/src/org/eclipse/dltk/ruby/launching/RubyRemoteLaunchConfigurationDelegate.java
@@ -9,17 +9,13 @@
public class RubyRemoteLaunchConfigurationDelegate extends
AbstractRemoteLaunchConfigurationDelegate {
- /*
- * @see org.eclipse.dltk.launching.AbstractRemoteLaunchConfigurationDelegate#getDebuggingRunner(org.eclipse.dltk.launching.IInterpreterInstall)
- */
+ @Override
protected RemoteDebuggingEngineRunner getDebuggingRunner(
IInterpreterInstall install) {
return new RubyRemoteDebuggerRunner(install);
}
- /*
- * @see org.eclipse.dltk.launching.AbstractScriptLaunchConfigurationDelegate#getLanguageId()
- */
+ @Override
public String getLanguageId() {
return RubyNature.NATURE_ID;
}