1 | package de.uka.ipd.sdq.scheduler; |
2 | |
3 | import org.apache.log4j.Level; |
4 | import org.apache.log4j.Logger; |
5 | |
6 | import de.uka.ipd.sdq.probfunction.math.util.MathTools; |
7 | import de.uka.ipd.sdq.scheduler.factory.SchedulingFactory; |
8 | |
9 | public class LoggingWrapper { |
10 | |
11 | public static Logger logger = Logger.getLogger("Scheduler"); |
12 | |
13 | public static void activate(){ |
14 | logger.setLevel(Level.ALL); |
15 | } |
16 | |
17 | public static void deactivate(){ |
18 | logger.setLevel(Level.OFF); |
19 | } |
20 | |
21 | public static void log(String string) { |
22 | // logger.info(MathTools.round(SchedulingFactory.getUsedSimulator().time(), 0.01) + " " + string); |
23 | // System.out.println(MathTools.round(SchedulingFactory.getUsedSimulator().time(), 0.01) + " " + string); |
24 | } |
25 | |
26 | static{ |
27 | activate(); |
28 | } |
29 | |
30 | } |