1 18 19 package org.apache.jmeter.samplers; 20 21 import java.io.Serializable ; 22 23 import org.apache.jmeter.engine.event.LoopIterationEvent; 24 import org.apache.jmeter.engine.util.NoThreadClone; 25 import org.apache.jmeter.testelement.AbstractTestElement; 26 import org.apache.jmeter.testelement.TestListener; 27 import org.apache.jorphan.logging.LoggingManager; 28 import org.apache.log.Logger; 29 30 34 public class RemoteTestListenerWrapper 35 extends AbstractTestElement 36 implements TestListener, Serializable , NoThreadClone 37 { 38 transient private static Logger log = LoggingManager.getLoggerForClass(); 39 RemoteSampleListener listener; 40 41 public RemoteTestListenerWrapper() 42 { 43 } 44 45 public RemoteTestListenerWrapper(RemoteSampleListener l) 46 { 47 listener = l; 48 } 49 public void testStarted() 50 { 51 try 52 { 53 listener.testStarted(); 54 } 55 catch (Exception ex) 56 { 57 log.error("", ex); 58 } 59 60 } 61 public void testEnded() 62 { 63 try 64 { 65 listener.testEnded(); 66 } 67 catch (Exception ex) 68 { 69 log.error("", ex); 70 } 71 } 72 public void testStarted(String host) 73 { 74 try 75 { 76 listener.testStarted(host); 77 } 78 catch (Exception ex) 79 { 80 log.error("", ex); 81 } 82 } 83 public void testEnded(String host) 84 { 85 try 86 { 87 listener.testEnded(host); 88 } 89 catch (Exception ex) 90 { 91 log.error("", ex); 92 } 93 } 94 97 public void testIterationStart(LoopIterationEvent event) 98 { 99 } 100 101 } | Popular Tags |