@@ -49,7 +49,7 @@ public class Main { | |||
} | |||
if (numConfigFiles != args.length) { | |||
try { | |||
Class ajc = Class.forName("org.aspectj.tools.ajc.Main"); | |||
Class<?> ajc = Class.forName("org.aspectj.tools.ajc.Main"); | |||
Method main = ajc.getMethod("main", new Class[] { String[].class }); | |||
main.invoke(null, new Object[] { args }); | |||
return true; |
@@ -42,8 +42,8 @@ public class BrowserCompilerConfiguration implements ICompilerConfiguration { | |||
if (userPath != null && userPath.trim().length() != 0) { | |||
classpath.append(userPath); | |||
} | |||
List outputDirs = getOutputLocationManager().getAllOutputLocations(); | |||
for (Iterator iterator = outputDirs.iterator(); iterator.hasNext();) { | |||
List<File> outputDirs = getOutputLocationManager().getAllOutputLocations(); | |||
for (Iterator<File> iterator = outputDirs.iterator(); iterator.hasNext();) { | |||
File dir = (File) iterator.next(); | |||
classpath.append(File.pathSeparator + dir.getAbsolutePath() + File.pathSeparator); | |||
} | |||
@@ -67,7 +67,7 @@ public class BrowserCompilerConfiguration implements ICompilerConfiguration { | |||
return locationManager; | |||
} | |||
public List getProjectSourceFiles() { | |||
public List<String> getProjectSourceFiles() { | |||
// unimplemented in AjBrowser (uses BuildConfigManager instead) | |||
return null; | |||
} | |||
@@ -87,7 +87,7 @@ public class BrowserCompilerConfiguration implements ICompilerConfiguration { | |||
return null; | |||
} | |||
public Set getInpath() { | |||
public Set<File> getInpath() { | |||
// unimplemented in AjBrowser | |||
return null; | |||
} | |||
@@ -108,8 +108,8 @@ public class BrowserCompilerConfiguration implements ICompilerConfiguration { | |||
return null; | |||
} | |||
public List getProjectXmlConfigFiles() { | |||
return Collections.EMPTY_LIST; | |||
public List<String> getProjectXmlConfigFiles() { | |||
return Collections.emptyList(); | |||
} | |||
public String getProjectEncoding() { |
@@ -46,8 +46,8 @@ public class BrowserOutputLocationManager implements IOutputLocationManager { | |||
return outputPath; | |||
} | |||
public List getAllOutputLocations() { | |||
List outputDirs = new ArrayList(); | |||
public List<File> getAllOutputLocations() { | |||
List<File> outputDirs = new ArrayList<File>(); | |||
outputDirs.add(new File(getCommonOutputDir())); | |||
return outputDirs; | |||
} | |||
@@ -67,12 +67,11 @@ public class BrowserOutputLocationManager implements IOutputLocationManager { | |||
} | |||
public int discoverChangesSince(File dir, long buildtime) { | |||
// TODO Auto-generated method stub | |||
return 0; | |||
} | |||
public Map getInpathMap() { | |||
return Collections.EMPTY_MAP; | |||
public Map<File, String> getInpathMap() { | |||
return Collections.emptyMap(); | |||
} | |||
} |
@@ -17,7 +17,6 @@ import java.awt.BorderLayout; | |||
import java.awt.event.KeyEvent; | |||
import java.io.IOException; | |||
import java.util.ArrayList; | |||
import java.util.Iterator; | |||
import java.util.Vector; | |||
import javax.swing.Box; | |||
@@ -71,8 +70,8 @@ public class EditorManager { | |||
} | |||
public void notifyCurrentFileChanged(String filePath) { | |||
for (Iterator it = editorListeners.iterator(); it.hasNext();) { | |||
((EditorListener) it.next()).currentFileChanged(filePath); | |||
for (EditorListener editorListener : editorListeners) { | |||
editorListener.currentFileChanged(filePath); | |||
} | |||
} | |||
@@ -149,8 +148,8 @@ public class EditorManager { | |||
public void saveContents() { | |||
try { | |||
for (Iterator it = editors.iterator(); it.hasNext();) { | |||
((EditorAdapter) it.next()).saveContents(); | |||
for (EditorAdapter editorAdapter : editors) { | |||
editorAdapter.saveContents(); | |||
} | |||
} catch (IOException ioe) { | |||
BrowserErrorHandler.handleError("Editor could not save the current file.", ioe); |