diff options
Diffstat (limited to 'src/uk/ac/ox/cs/pagoda/util')
| -rw-r--r-- | src/uk/ac/ox/cs/pagoda/util/PagodaProperties.java | 4 | ||||
| -rw-r--r-- | src/uk/ac/ox/cs/pagoda/util/Utility.java | 6 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/uk/ac/ox/cs/pagoda/util/PagodaProperties.java b/src/uk/ac/ox/cs/pagoda/util/PagodaProperties.java index be6627a..7b7d48d 100644 --- a/src/uk/ac/ox/cs/pagoda/util/PagodaProperties.java +++ b/src/uk/ac/ox/cs/pagoda/util/PagodaProperties.java | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | package uk.ac.ox.cs.pagoda.util; | 1 | package uk.ac.ox.cs.pagoda.util; |
| 2 | 2 | ||
| 3 | import org.apache.log4j.Logger; | ||
| 4 | |||
| 3 | import java.io.FileInputStream; | 5 | import java.io.FileInputStream; |
| 4 | import java.io.IOException; | 6 | import java.io.IOException; |
| 5 | import java.io.InputStream; | 7 | import java.io.InputStream; |
| @@ -20,6 +22,8 @@ public class PagodaProperties { | |||
| 20 | in.close(); | 22 | in.close(); |
| 21 | if(config.containsKey("debug")) { | 23 | if(config.containsKey("debug")) { |
| 22 | debug = Boolean.parseBoolean(config.getProperty("debug")); | 24 | debug = Boolean.parseBoolean(config.getProperty("debug")); |
| 25 | Logger.getLogger("PagodaProperties") | ||
| 26 | .info("Debugging mode is enabled (you can disable it from file \"pagoda.properties\")"); | ||
| 23 | } | 27 | } |
| 24 | } catch(IOException e) { | 28 | } catch(IOException e) { |
| 25 | e.printStackTrace(); | 29 | e.printStackTrace(); |
diff --git a/src/uk/ac/ox/cs/pagoda/util/Utility.java b/src/uk/ac/ox/cs/pagoda/util/Utility.java index e98cc81..cef4abd 100644 --- a/src/uk/ac/ox/cs/pagoda/util/Utility.java +++ b/src/uk/ac/ox/cs/pagoda/util/Utility.java | |||
| @@ -29,7 +29,7 @@ public class Utility { | |||
| 29 | private static StringBuilder logMessage = new StringBuilder(); | 29 | private static StringBuilder logMessage = new StringBuilder(); |
| 30 | 30 | ||
| 31 | static { | 31 | static { |
| 32 | LOGS = Logger.getLogger("PAGOdA"); | 32 | LOGS = Logger.getLogger("Pagoda"); |
| 33 | LOGS.setLevel(Level.DEBUG); | 33 | LOGS.setLevel(Level.DEBUG); |
| 34 | } | 34 | } |
| 35 | 35 | ||
| @@ -37,6 +37,10 @@ public class Utility { | |||
| 37 | outs.push(System.out); | 37 | outs.push(System.out); |
| 38 | } | 38 | } |
| 39 | 39 | ||
| 40 | static { | ||
| 41 | |||
| 42 | } | ||
| 43 | |||
| 40 | public static String getGlobalTempDirAbsolutePath() { | 44 | public static String getGlobalTempDirAbsolutePath() { |
| 41 | if(tempDir == null) { | 45 | if(tempDir == null) { |
| 42 | try { | 46 | try { |
