diff options
author | Simon Brandhof <simon.brandhof@gmail.com> | 2014-04-04 17:31:31 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@gmail.com> | 2014-04-04 17:31:31 +0200 |
commit | 1335109eb1fd4a1df2b9d2043dd1a0a511a2bd61 (patch) | |
tree | 13600cd3711f97790a1d85343692e97736851111 /sonar-plugin-api/src/main/java/org/sonar/api/utils/text | |
parent | 3bfcfa0de67e7f00d7cd0dc74649fef7e5772298 (diff) | |
download | sonarqube-1335109eb1fd4a1df2b9d2043dd1a0a511a2bd61.tar.gz sonarqube-1335109eb1fd4a1df2b9d2043dd1a0a511a2bd61.zip |
Fix some quality flaws
Diffstat (limited to 'sonar-plugin-api/src/main/java/org/sonar/api/utils/text')
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/utils/text/JsonWriter.java | 8 | ||||
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/utils/text/XmlWriter.java | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/JsonWriter.java b/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/JsonWriter.java index 48b04d938e9..6d929a28daa 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/JsonWriter.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/JsonWriter.java @@ -51,10 +51,6 @@ import java.util.Date; */ public class JsonWriter { - public static JsonWriter of(Writer writer) { - return new JsonWriter(writer); - } - private final com.google.gson.stream.JsonWriter stream; private JsonWriter(Writer writer) { @@ -68,6 +64,10 @@ public class JsonWriter { this.stream = stream; } + public static JsonWriter of(Writer writer) { + return new JsonWriter(writer); + } + /** * Begins encoding a new array. Each call to this method must be paired with * a call to {@link #endArray}. Output is <code>[</code>. diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/XmlWriter.java b/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/XmlWriter.java index fbd5d552960..e9b53712bda 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/XmlWriter.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/utils/text/XmlWriter.java @@ -30,10 +30,6 @@ import java.io.Writer; */ public class XmlWriter { - public static XmlWriter of(Writer writer) { - return new XmlWriter(writer); - } - private final XMLStreamWriter stream; private XmlWriter(Writer writer) { @@ -45,6 +41,10 @@ public class XmlWriter { } } + public static XmlWriter of(Writer writer) { + return new XmlWriter(writer); + } + public XmlWriter declaration() { try { stream.writeStartDocument(); |