tinylog-org / tinylog

@@ -89,7 +89,8 @@
Loading
89 89
	 * @return {@code true} if writing thread is explicitly enabled, otherwise {@code false}
90 90
	 */
91 91
	public static boolean isWritingThreadEnabled() {
92 -
		return "true".equalsIgnoreCase(Configuration.get("writingthread"));
92 +
		String enabled = Configuration.get("writingthread");
93 +
		return enabled != null && Boolean.parseBoolean(enabled.trim());
93 94
	}
94 95
95 96
	/**
@@ -98,7 +99,8 @@
Loading
98 99
	 * @return {@code false} if auto shutdown is explicitly disabled, otherwise {@code true}
99 100
	 */
100 101
	public static boolean isAutoShutdownEnabled() {
101 -
		return !"false".equalsIgnoreCase(Configuration.get("autoshutdown"));
102 +
		String enabled = Configuration.get("autoshutdown");
103 +
		return enabled == null || Boolean.parseBoolean(enabled.trim());
102 104
	}
103 105
104 106
	/**

@@ -101,7 +101,7 @@
Loading
101 101
		} else if (NOP_PROVIDER_NAME.equalsIgnoreCase(name)) {
102 102
			return new NopLoggingProvider();
103 103
		} else {
104 -
			String[] nameItems = name.split(",");
104 +
			String[] nameItems = name.trim().split(",");
105 105
			Collection<LoggingProvider> providers = new ArrayList<LoggingProvider>(nameItems.length);
106 106
			for (String nameItem : nameItems) {
107 107
				nameItem = nameItem.trim();

@@ -154,7 +154,7 @@
Loading
154 154
		if (tag == null) {
155 155
			return Locale.ROOT;
156 156
		} else {
157 -
			String[] splitTag = tag.split("_", MAX_LOCALE_ARGUMENTS);
157 +
			String[] splitTag = tag.trim().split("_", MAX_LOCALE_ARGUMENTS);
158 158
			if (splitTag.length == 1) {
159 159
				return new Locale(splitTag[0]);
160 160
			} else if (splitTag.length == 2) {
@@ -171,7 +171,8 @@
Loading
171 171
	 * @return {@code true} if escaping is enabled, otherwise {@code false}
172 172
	 */
173 173
	public static boolean isEscapingEnabled() {
174 -
		return Boolean.parseBoolean(get(ESCAPING_ENABLED_KEY));
174 +
		String enabled = get(ESCAPING_ENABLED_KEY);
175 +
		return enabled != null && Boolean.parseBoolean(enabled.trim());
175 176
	}
176 177
177 178
	/**
Files Complexity Coverage
jboss-tinylog/src/main/java/org/tinylog/jboss 98.47% 98.84%
jcl-tinylog/src/main/java/org/tinylog/jcl 88.52% 89.55%
jul-tinylog/src/main/java/org/tinylog/jul 89.47% 91.18%
log4j1.2-api/src/main/java/org/apache/log4j 72.78% 70.50%
slf4j-tinylog/src/main/java/org 93.33% 94.96%
tinylog-api-kotlin/src/main/kotlin/org/tinylog/kotlin 96.08% 95.70%
tinylog-api-scala/src/main/scala/org/tinylog/scala 100.00% 90.00%
tinylog-api/src/main/java/org/tinylog 94.39% 94.07%
tinylog-impl/src/main/java/org/tinylog 93.97% 96.04%
tinylog-jboss/src/main/java/org/tinylog/adapter/jboss 89.66% 91.84%
tinylog1.3-api/src/main/java/org/pmw/tinylog 99.16% 98.91%
...ylog-jul/src/main/java/org/tinylog/adapter/jul/JavaUtilLoggingProvider.java 85.00% 88.24%
Project Totals (132 files) 93.49% 94.38%
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading