From: <jom...@us...> - 2014-08-25 21:21:18
|
Revision: 1797 http://sourceforge.net/p/jason/svn/1797 Author: jomifred Date: 2014-08-25 21:21:16 +0000 (Mon, 25 Aug 2014) Log Message: ----------- fix a typp in the name of a method Modified Paths: -------------- trunk/src/jason/infra/centralised/RunCentralisedMAS.java Modified: trunk/src/jason/infra/centralised/RunCentralisedMAS.java =================================================================== --- trunk/src/jason/infra/centralised/RunCentralisedMAS.java 2014-08-21 23:41:49 UTC (rev 1796) +++ trunk/src/jason/infra/centralised/RunCentralisedMAS.java 2014-08-25 21:21:16 UTC (rev 1797) @@ -43,6 +43,7 @@ import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; +import java.io.IOException; import java.io.InputStream; import java.net.MalformedURLException; import java.net.URL; @@ -233,7 +234,11 @@ } } else { try { - LogManager.getLogManager().readConfiguration(RunCentralisedMAS.class.getResource("/templates/" + logPropFile).openStream()); + if (runner != null) { + LogManager.getLogManager().readConfiguration(runner.getDefaultLogProperties()); + } else { + LogManager.getLogManager().readConfiguration(RunCentralisedMAS.class.getResource("/templates/" + logPropFile).openStream()); + } } catch (Exception e) { System.err.println("Error setting up logger:" + e); e.printStackTrace(); @@ -242,6 +247,10 @@ } } + protected InputStream getDefaultLogProperties() throws IOException { + return RunCentralisedMAS.class.getResource("/templates/" + logPropFile).openStream(); + } + public static void setupDefaultConsoleLogger() { Handler[] hs = Logger.getLogger("").getHandlers(); for (int i = 0; i < hs.length; i++) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |