Mass whitespace changes (Style Warnings)
[aaf/authz.git] / misc / xgen / src / main / java / org / onap / aaf / misc / xgen / XGen.java
index 7b0a426..b68ad6e 100644 (file)
@@ -61,7 +61,7 @@ public class XGen<RT extends XGen<RT>> {
     }\r
 \r
     protected void prettyln(PrintWriter pw) {\r
-        if(pretty)pw.println();\r
+        if (pretty)pw.println();\r
     }\r
 \r
     public RT leaf(Mark mark, String tag, String ... args) {\r
@@ -110,10 +110,10 @@ public class XGen<RT extends XGen<RT>> {
         back.append(tag);\r
         back.append('>');\r
     \r
-        if(pretty) {\r
-            if(mark!=null && mark.comment!=null) {\r
+        if (pretty) {\r
+            if (mark!=null && mark.comment!=null) {\r
                 int fi = forward.getIndent()*IndentPrintWriter.INDENT_MULTIPLIER;\r
-                for(int i = fi+backSB.length();i<=COMMENT_COLUMN;++i) {\r
+                for (int i = fi+backSB.length();i<=COMMENT_COLUMN;++i) {\r
                     back.append(' ');\r
                 }\r
                 back.append("<!-- end ");\r
@@ -126,12 +126,12 @@ public class XGen<RT extends XGen<RT>> {
                 forward.append(" -->");\r
             }\r
             forward.inc();\r
-            if(!oneLine) {\r
+            if (!oneLine) {\r
                 forward.println();\r
             }\r
             back.println();\r
         }\r
-        if(mark!=null)mark.spot = backStack.size();\r
+        if (mark!=null)mark.spot = backStack.size();\r
         backStack.push(new Back(backSB.toString(),true, false));\r
         backSB.setLength(0);\r
         return (RT)this;\r
@@ -143,7 +143,7 @@ public class XGen<RT extends XGen<RT>> {
         forward.append(tag);\r
         addAttrs(attrs);\r
         forward.append(" />");\r
-        if(pretty) {\r
+        if (pretty) {\r
             forward.println();\r
         }\r
         return (RT)this;\r
@@ -157,7 +157,7 @@ public class XGen<RT extends XGen<RT>> {
     \r
     @SuppressWarnings("unchecked")\r
     public RT xml(String txt) {\r
-        for(int i=0; i<txt.length();++i) {\r
+        for (int i=0; i<txt.length();++i) {\r
             char c = txt.charAt(i);\r
             switch(c) {\r
                 case '<':\r
@@ -179,11 +179,11 @@ public class XGen<RT extends XGen<RT>> {
 \r
     @SuppressWarnings("unchecked")\r
     public RT textCR(int tabs, String txt) {\r
-        for(int i=0;i<tabs;++i) {\r
+        for (int i=0;i<tabs;++i) {\r
             forward.append("  ");\r
         }\r
         forward.append(txt);\r
-        if(pretty)forward.println();\r
+        if (pretty)forward.println();\r
         return (RT)this;\r
     }\r
 \r
@@ -218,13 +218,13 @@ public class XGen<RT extends XGen<RT>> {
         int size = backStack.size();\r
         Back c;\r
         boolean println = false;\r
-        for(int i=mark==null?0:mark.spot;i<size;++i) {\r
+        for (int i=mark==null?0:mark.spot;i<size;++i) {\r
             c = backStack.pop();\r
-            if(c.dec)forward.dec();\r
+            if (c.dec)forward.dec();\r
             forward.append(c.str);\r
             println = c.cr;\r
         }\r
-        if(pretty && println) {\r
+        if (pretty && println) {\r
             forward.println();\r
         }\r
         return (RT)this;\r
@@ -233,14 +233,14 @@ public class XGen<RT extends XGen<RT>> {
     public RT end() {\r
         Mark mark = new Mark();\r
         mark.spot=backStack.size()-1;\r
-        if(mark.spot<0)mark.spot=0;\r
+        if (mark.spot<0)mark.spot=0;\r
         return end(mark);\r
     }\r
 \r
     public RT end(int i) {\r
         Mark mark = new Mark();\r
         mark.spot=backStack.size()-i;\r
-        if(mark.spot<0)mark.spot=0;\r
+        if (mark.spot<0)mark.spot=0;\r
         return end(mark);\r
     }\r
 \r
@@ -250,9 +250,9 @@ public class XGen<RT extends XGen<RT>> {
     }\r
 \r
     protected void addAttrs(String[] attrs) {\r
-        if(attrs!=null) {\r
-            for(String attr : attrs) {\r
-                if(attr!=null && attr.length()>0) {\r
+        if (attrs!=null) {\r
+            for (String attr : attrs) {\r
+                if (attr!=null && attr.length()>0) {\r
                     forward.append(' ');\r
                     String[] split = attr.split("=",2);\r
                     switch(split.length) {\r
@@ -276,7 +276,7 @@ public class XGen<RT extends XGen<RT>> {
 \r
     @SuppressWarnings("unchecked")\r
     public RT comment(String string) {\r
-        if(pretty) {\r
+        if (pretty) {\r
             forward.print("<!--  ");\r
             forward.print(string);\r
             forward.println("  -->");\r