< prev index next >
src/com/sun/javatest/agent/AgentFrame.java
Print this page
rev 145 : 7902237: Fixing raw use of parameterized class
Reviewed-by: jjg
@@ -92,11 +92,11 @@
ActiveModeOptions amo = new ActiveModeOptions();
PassiveModeOptions pmo = new PassiveModeOptions();
ModeOptions smo = null;
try {
- Class serial = Class.forName("com.sun.javatest.agent.SerialPortModeOptions");
+ Class<?> serial = Class.forName("com.sun.javatest.agent.SerialPortModeOptions");
smo = (ModeOptions)serial.newInstance();
} catch (Exception e) {
System.err.println("There is no support for serial port");
}
@@ -206,11 +206,11 @@
final AgentFrame sf = new AgentFrame(modeOptions);
if (observerClassName != null) {
try {
- Class observerClass = Class.forName(observerClassName);
+ Class<?> observerClass = Class.forName(observerClassName);
Agent.Observer observer = (Agent.Observer)(observerClass.newInstance());
sf.panel.addObserver(observer);
}
catch (ClassCastException e) {
System.err.println("observer is not of type " +
@@ -259,11 +259,11 @@
if (start)
sp.start();
try {
- Method invokeLater = EventQueue.class.getMethod("invokeLater", new Class[] { Runnable.class });
+ Method invokeLater = EventQueue.class.getMethod("invokeLater", new Class<?>[] { Runnable.class });
invokeLater.invoke(null, new Object[] { new Runnable() {
public void run() {
sf.showCentered();
}
} });
< prev index next >