1 22 package org.jboss.test.aop.stress; 23 24 29 public class ScenarioLoggingDecorator implements Scenario 30 { 31 Scenario delegate; 32 33 public ScenarioLoggingDecorator(Scenario delegate) 34 { 35 this.delegate = delegate; 36 } 37 38 public void execute(int thread, int loop) throws Exception  39 { 40 String id = (thread + "-" + loop + " " + delegate.getClass()); 41 System.out.println(id + " starting"); 42 delegate.execute(thread, loop); 43 System.out.println(id + " end"); 44 } 45 } 46 | Popular Tags |