/** * Make the SamplePackage the running version, or make it no longer the * running version. This tells to each element of the SamplePackage that it's current state must * be retrievable by a call to recoverRunningVersion(). * @param running boolean * @see TestElement#setRunningVersion(boolean) */ public void setRunningVersion(boolean running) { setRunningVersion(configs, running); setRunningVersion(sampleListeners, running); setRunningVersion(assertions, running); setRunningVersion(timers, running); setRunningVersion(postProcessors, running); setRunningVersion(preProcessors, running); setRunningVersion(controllers, running); sampler.setRunningVersion(running); }
private void saveTransactionControllerConfigs(TransactionController tc) { List<ConfigTestElement> configs = new LinkedList<>(); List<Controller> controllers = new LinkedList<>(); List<SampleListener> listeners = new LinkedList<>(); List<Timer> timers = new LinkedList<>(); List<Assertion> assertions = new LinkedList<>(); LinkedList<PostProcessor> posts = new LinkedList<>(); LinkedList<PreProcessor> pres = new LinkedList<>(); for (int i = stack.size(); i > 0; i--) { addDirectParentControllers(controllers, stack.get(i - 1)); for (Object item : testTree.list(stack.subList(0, i))) { if (item instanceof SampleListener) { listeners.add((SampleListener) item); } if (item instanceof Assertion) { assertions.add((Assertion) item); } } } SamplePackage pack = new SamplePackage(configs, listeners, timers, assertions, posts, pres, controllers); pack.setSampler(new TransactionSampler(tc, tc.getName())); pack.setRunningVersion(true); transactionControllerConfigMap.put(tc, pack); }
posts, pres, controllers); pack.setSampler(sam); pack.setRunningVersion(true); samplerConfigMap.put(sam, pack);