creadur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rdon...@apache.org
Subject svn commit: r1549284 - in /creadur/rat/branches/gsoc/apache-rat-core/src: main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java
Date Sun, 08 Dec 2013 21:23:49 GMT
Author: rdonkin
Date: Sun Dec  8 21:23:49 2013
New Revision: 1549284

URL: http://svn.apache.org/r1549284
Log:
Apply PMD change.

Modified:
    creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java
    creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java

Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java
URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java?rev=1549284&r1=1549283&r2=1549284&view=diff
==============================================================================
--- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java
(original)
+++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/writer/XmlWriterUtils.java
Sun Dec  8 21:23:49 2013
@@ -23,7 +23,14 @@ import java.io.IOException;
 /**
  * The Class XmlWriterUtils.
  */
-public class XmlWriterUtils {
+public final class XmlWriterUtils {
+
+	/**
+	 * Instantiates a new xml writer utils.
+	 */
+	public XmlWriterUtils() {
+		super();
+	}
 
 	/**
 	 * Write attribute.
@@ -37,7 +44,7 @@ public class XmlWriterUtils {
 	 * @throws IOException
 	 *             Signals that an I/O exception has occurred.
 	 */
-	public static final void writeAttribute(final IXmlWriter writer,
+	public void writeAttribute(final IXmlWriter writer,
 			final String name, final boolean booleanValue) throws IOException {
 		final String value = Boolean.toString(booleanValue);
 		writer.attribute(name, value);

Modified: creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java
URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java?rev=1549284&r1=1549283&r2=1549284&view=diff
==============================================================================
--- creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java
(original)
+++ creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/writer/XmlWriterUtilsTest.java
Sun Dec  8 21:23:49 2013
@@ -18,13 +18,13 @@
  */ 
 package org.apache.rat.report.xml.writer;
 
-import org.apache.rat.report.xml.writer.impl.base.XmlWriter;
-import org.junit.Before;
-import org.junit.Test;
+import static org.junit.Assert.assertEquals;
 
 import java.io.StringWriter;
 
-import static org.junit.Assert.assertEquals;
+import org.apache.rat.report.xml.writer.impl.base.XmlWriter;
+import org.junit.Before;
+import org.junit.Test;
 
 public class XmlWriterUtilsTest {
 
@@ -40,13 +40,13 @@ public class XmlWriterUtilsTest {
 
     @Test
     public void writeTrue() throws Exception {
-        XmlWriterUtils.writeAttribute(writer, "name", true);
+		new XmlWriterUtils().writeAttribute(writer, "name", true);
         assertEquals("Attribute written as True", "<alpha name='true'", out.toString());
     }
 
     @Test
     public void writeFalse() throws Exception {
-        XmlWriterUtils.writeAttribute(writer, "name", false);
+		new XmlWriterUtils().writeAttribute(writer, "name", false);
         assertEquals("Attribute written as False", "<alpha name='false'", out.toString());
     }
 }



Mime
View raw message