diff --git a/main/src/com/metaweb/gridworks/expr/functions/arrays/Sort.java b/main/src/com/metaweb/gridworks/expr/functions/arrays/Sort.java index c67cb7e79..145234435 100644 --- a/main/src/com/metaweb/gridworks/expr/functions/arrays/Sort.java +++ b/main/src/com/metaweb/gridworks/expr/functions/arrays/Sort.java @@ -28,7 +28,7 @@ public class Sort implements Function { return r; } else if (v instanceof List) { - List a = (List) v; + List> a = (List>) v; Collections.sort(a); return a; diff --git a/main/src/com/metaweb/gridworks/util/JSObject.java b/main/src/com/metaweb/gridworks/util/JSObject.java index 3920877aa..48d93e147 100644 --- a/main/src/com/metaweb/gridworks/util/JSObject.java +++ b/main/src/com/metaweb/gridworks/util/JSObject.java @@ -20,12 +20,11 @@ import org.json.JSONObject; public class JSObject extends Properties { private static final long serialVersionUID = 5864375136126385719L; - @SuppressWarnings("unchecked") static public void writeJSObject(IndentWriter writer, JSObject jso) throws IOException, JSONException { writer.println("{"); writer.indent(); { - Enumeration e = jso.propertyNames(); + Enumeration e = jso.propertyNames(); while (e.hasMoreElements()) { String name = (String) e.nextElement(); Object value = jso.get(name); @@ -45,12 +44,11 @@ public class JSObject extends Properties { writer.print("}"); } - @SuppressWarnings("unchecked") - static public void writeCollection(IndentWriter writer, Collection c) throws IOException, JSONException { + static public void writeCollection(IndentWriter writer, Collection c) throws IOException, JSONException { writer.println("["); writer.indent(); { - Iterator i = c.iterator(); + Iterator i = c.iterator(); while (i.hasNext()) { writeObject(writer, i.next()); if (i.hasNext()) { @@ -108,7 +106,6 @@ public class JSObject extends Properties { writer.print("]"); } - @SuppressWarnings("unchecked") static public void writeObject(IndentWriter writer, Object o) throws IOException, JSONException { if (o == null) { writer.print("null"); @@ -118,7 +115,7 @@ public class JSObject extends Properties { writer.print(((Number) o).toString()); } else if (o instanceof Collection) { - writeCollection(writer, (Collection) o); + writeCollection(writer, (Collection) o); } else if (o instanceof JSONArray) { writeJSONArray(writer, (JSONArray) o); } else if (o instanceof JSObject) { diff --git a/server/src/com/metaweb/gridworks/Gridworks.java b/server/src/com/metaweb/gridworks/Gridworks.java index 09de902e0..8aef5886a 100644 --- a/server/src/com/metaweb/gridworks/Gridworks.java +++ b/server/src/com/metaweb/gridworks/Gridworks.java @@ -201,8 +201,7 @@ class GridworksServer extends Server { scanner.setReportExistingFilesOnStartup(false); scanner.addListener(new Scanner.BulkListener() { - @SuppressWarnings("unchecked") - public void filesChanged(List changedFiles) { + public void filesChanged(@SuppressWarnings("rawtypes") List changedFiles) { try { logger.info("Stopping context: " + contextRoot.getAbsolutePath()); context.stop(); @@ -362,7 +361,6 @@ class GridworksClient extends JFrame implements ActionListener { private URI uri; - @SuppressWarnings("unchecked") public void init(String host, int port) throws Exception { uri = new URI("http://" + host + ":" + port + "/"); @@ -380,7 +378,7 @@ class GridworksClient extends JFrame implements ActionListener { m.add(mi); mb.add(m); - Class applicationClass = Class.forName("com.apple.eawt.Application"); + Class applicationClass = Class.forName("com.apple.eawt.Application"); Object macOSXApplication = applicationClass.getConstructor((Class[]) null).newInstance((Object[]) null); Method setDefaultMenuBar = applicationClass.getDeclaredMethod("setDefaultMenuBar", new Class[] { JMenuBar.class }); setDefaultMenuBar.invoke(macOSXApplication, new Object[] { mb });