< 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,102 **** ActiveModeOptions amo = new ActiveModeOptions(); PassiveModeOptions pmo = new PassiveModeOptions(); ModeOptions smo = null; try { ! 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"); } --- 92,102 ---- ActiveModeOptions amo = new ActiveModeOptions(); PassiveModeOptions pmo = new PassiveModeOptions(); ModeOptions smo = null; try { ! 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,216 **** final AgentFrame sf = new AgentFrame(modeOptions); if (observerClassName != null) { try { ! 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 " + --- 206,216 ---- final AgentFrame sf = new AgentFrame(modeOptions); if (observerClassName != null) { try { ! 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,269 **** if (start) sp.start(); try { ! Method invokeLater = EventQueue.class.getMethod("invokeLater", new Class[] { Runnable.class }); invokeLater.invoke(null, new Object[] { new Runnable() { public void run() { sf.showCentered(); } } }); --- 259,269 ---- if (start) sp.start(); try { ! 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 >