You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@axis.apache.org by bi...@apache.org on 2020/04/14 20:02:48 UTC

[axis-axis2-java-core] 36/38: AXIS2-5360 - Merged r1358508 to 1.5 branch.

This is an automated email from the ASF dual-hosted git repository.

billblough pushed a commit to branch 1_5
in repository https://gitbox.apache.org/repos/asf/axis-axis2-java-core.git

commit 3a1d4bddabfeefd71fa4619c337e26bc0f48caf4
Author: Sagara Gunathunga <sa...@apache.org>
AuthorDate: Sat Jul 7 06:17:13 2012 +0000

    AXIS2-5360 - Merged r1358508 to 1.5 branch.
---
 modules/kernel/src/org/apache/axis2/util/PrettyPrinter.java | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/modules/kernel/src/org/apache/axis2/util/PrettyPrinter.java b/modules/kernel/src/org/apache/axis2/util/PrettyPrinter.java
index 440e000..d3004e3 100644
--- a/modules/kernel/src/org/apache/axis2/util/PrettyPrinter.java
+++ b/modules/kernel/src/org/apache/axis2/util/PrettyPrinter.java
@@ -47,7 +47,7 @@ public class PrettyPrinter {
         // If the user has set "axis2.jalopy=false" on the system property,
         // then just return back to caller
         String property = System.getProperty("axis2.jalopy");
-        if((property == null) || !JavaUtils.isTrueExplicitly(property)){
+        if((property != null) && !JavaUtils.isTrueExplicitly(property)){
             return;
         }
         PrintStream backupOutputStream = System.out;
@@ -55,7 +55,7 @@ public class PrettyPrinter {
         System.setOut(new PrintStream(new ByteArrayOutputStream()));
         System.setErr(new PrintStream(new ByteArrayOutputStream()));
         try {
-            Class clazzConfigurator = Loader.loadClass("org.apache.log4j.PropertyConfigurator");
+            Class<?> clazzConfigurator = Loader.loadClass("org.apache.log4j.PropertyConfigurator");
             Method configure = clazzConfigurator.getMethod("configure", new Class[]{Properties.class});
             Properties properties = new Properties();
             properties.setProperty("log4j.logger.de.hunsicker.jalopy.io",
@@ -63,7 +63,7 @@ public class PrettyPrinter {
             configure.invoke(null, new Object[]{properties});
 
             // Create an instance of the Jalopy bean
-            Class clazz = Loader.loadClass("de.hunsicker.jalopy.Jalopy");
+            Class<?> clazz = Loader.loadClass("de.hunsicker.jalopy.Jalopy");
             Object prettifier = clazz.newInstance();
 
             // Set the input file
@@ -74,11 +74,11 @@ public class PrettyPrinter {
             Method output = clazz.getMethod("setOutput", new Class[]{File.class});
             output.invoke(prettifier, new Object[]{file});
 
-            Class clazz2 = Loader.loadClass("de.hunsicker.jalopy.storage.Convention");
+            Class<?> clazz2 = Loader.loadClass("de.hunsicker.jalopy.storage.Convention");
             Method instance = clazz2.getMethod("getInstance", new Class[]{});
             Object settings = instance.invoke(null, new Object[]{});
 
-            Class clazz3 = Loader.loadClass("de.hunsicker.jalopy.storage.ConventionKeys");
+            Class<?> clazz3 = Loader.loadClass("de.hunsicker.jalopy.storage.ConventionKeys");
             Field field = clazz3.getField("COMMENT_FORMAT_MULTI_LINE");
             Object key = field.get(null);
             Method put = clazz2.getMethod("put", new Class[]{key.getClass(), String.class});