1 package org.simantics.modeling.tests.commands;
3 import java.io.ByteArrayOutputStream;
4 import java.io.PrintStream;
6 import org.simantics.db.debug.ListenerReport;
7 import org.simantics.db.service.DebugSupport;
8 import org.simantics.db.testing.common.CommandSequenceEnvironment;
9 import org.simantics.db.testing.common.WriteCommand;
11 public class PrintListeners extends WriteCommand<CommandSequenceEnvironment> {
14 public void run(CommandSequenceEnvironment environment) throws Exception {
16 DebugSupport ds = environment.getSession().getService(DebugSupport.class);
17 ListenerReport report = ds.query(environment.getSession(), "get listeners");
19 ByteArrayOutputStream bo = new ByteArrayOutputStream();
20 PrintStream ps = new PrintStream(bo);
22 System.err.println("listeners: " + bo.toString());