Hello!

I'm developing plugin for Apache JMeter(java tool for performance testing)
Per official userguide I've extended AbstractVisualizer. This class already has functionality that I need.
After building and running JMeter with my plugin I receive ClassCastException:
Java Code:
2012/12/24 14:08:11 WARN  - jmeter.gui.action.Load: Unexpected error java.lang.ClassCastException: com.blazemeter.jmeter.testexecutor.RemoteTestRunner cannot be cast to org.apache.jmeter.reporters.ResultCollector
	at org.apache.jmeter.visualizers.gui.AbstractVisualizer.configure(AbstractVisualizer.java:281)
	at com.blazemeter.jmeter.testexecutor.RemoteTestRunnerGui.configure(RemoteTestRunnerGui.java:104)
	at org.apache.jmeter.gui.tree.JMeterTreeModel.addComponent(JMeterTreeModel.java:128)
	at org.apache.jmeter.gui.tree.JMeterTreeModel.addSubTree(JMeterTreeModel.java:112)
	at org.apache.jmeter.gui.tree.JMeterTreeModel.addSubTree(JMeterTreeModel.java:112)
	at org.apache.jmeter.gui.tree.JMeterTreeModel.addSubTree(JMeterTreeModel.java:112)
	at org.apache.jmeter.gui.tree.JMeterTreeModel.addSubTree(JMeterTreeModel.java:104)
	at org.apache.jmeter.gui.GuiPackage.addSubTree(GuiPackage.java:467)
	at org.apache.jmeter.gui.action.Load.insertLoadedTree(Load.java:178)
	at org.apache.jmeter.gui.action.Load.loadProjectFile(Load.java:111)
	at org.apache.jmeter.gui.action.LoadRecentProject.doAction(LoadRecentProject.java:68)
	at org.apache.jmeter.gui.action.ActionRouter.performAction(ActionRouter.java:79)
	at org.apache.jmeter.gui.action.ActionRouter.access$000(ActionRouter.java:40)
	at org.apache.jmeter.gui.action.ActionRouter$1.run(ActionRouter.java:61)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:641)
	at java.awt.EventQueue.access$000(EventQueue.java:84)
	at java.awt.EventQueue$1.run(EventQueue.java:602)
	at java.awt.EventQueue$1.run(EventQueue.java:600)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:611)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Exception occures in the following code:

AbstractVisualizer.java
Java Code:
/* Overrides AbstractJMeterGuiComponent.configure(TestElement) */
    @Override
    public void configure(TestElement el) {
        super.configure(el);
        setFile(el.getPropertyAsString(ResultCollector.FILENAME));
        ResultCollector rc = (ResultCollector) el;
        errorLogging.setSelected(rc.isErrorLogging());
        successOnlyLogging.setSelected(rc.isSuccessOnlyLogging());
        if (collector == null) {
            collector = new ResultCollector();
        }
        collector.setSaveConfig((SampleSaveConfiguration) rc.getSaveConfig().clone());
    }
GUI shows JOptionPane with error-message:
"com.blazemeter.jmeter.testexecutor.RemoteTestRunn er cannot be cast to org.apache.jmeter.reporter.ResultCollector"

ResultCollector has the following hierarchy:
java.lang.Object
org.apache.jmeter.testelement.AbstractTestElement
org.apache.jmeter.reporters.AbstractListenerElemen t
org.apache.jmeter.reporters.ResultCollector


AbstractVisualizer:
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.apache.jmeter.gui.AbstractJMeterGuiComponent
org.apache.jmeter.visualizers.gui.AbstractListener Gui
org.apache.jmeter.visualizers.gui.AbstractVisualiz er


If I extend AbstractListenerGUI - everything is working, and I cannot understand this. AFAIK, if it work with extending parent class, it should work with child class. Or am I missing something? Please, lead me in my attempts to resolve it. Thanks in advance.