From 2c4691482fa446ecb444996680cc3e0a86e480a4 Mon Sep 17 00:00:00 2001 From: Brett Delle Grazie Date: Tue, 22 Apr 2014 22:53:59 +0100 Subject: [PATCH] Minor documentation fixes for JSON layout --- .../logging/log4j/core/layout/JSONLayout.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/layout/JSONLayout.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/layout/JSONLayout.java index 9b2bd7c9755..e24abe26f7b 100644 --- a/log4j-core/src/main/java/org/apache/logging/log4j/core/layout/JSONLayout.java +++ b/log4j-core/src/main/java/org/apache/logging/log4j/core/layout/JSONLayout.java @@ -42,7 +42,7 @@ *

* If you configure {@code complete="true"}, the appender outputs a well-formed JSON document. * By default, with {@code complete="false"}, you should include the - * output as an external file in a separate file to form a well-formed JSON document. + * output in an external file to form a well-formed JSON document. *

*

* A well-formed JSON document follows this pattern: @@ -77,7 +77,7 @@ * Appenders using this layout should have their {@code charset} set to {@code UTF-8} or {@code UTF-16}, otherwise * events containing non ASCII characters could result in corrupted log files. *

- *

Pretty vs. compact XML

+ *

Pretty vs. compact JSON

*

* By default, the JSON layout is not compact (a.k.a. not "pretty") with {@code compact="false"}, which means the * appender uses end-of-line characters and indents lines to format the text. If {@code compact="true"}, then no @@ -125,7 +125,7 @@ protected JSONLayout(final boolean locationInfo, final boolean properties, final * * @param event * The LogEvent. - * @return The XML representation of the LogEvent. + * @return The JSON representation of the LogEvent. */ @Override public String toSerializable(final LogEvent event) { @@ -320,13 +320,13 @@ public byte[] getFooter() { } /** - * XMLLayout's content format is specified by: + * JSONLayout's content format is specified by: *

* Key: "dtd" Value: "log4j-events.dtd" *

* Key: "version" Value: "2.0" * - * @return Map of content format keys supporting XMLLayout + * @return Map of content format keys supporting JSONLayout */ @Override public Map getContentFormat() { @@ -344,7 +344,7 @@ public String getContentType() { } /** - * Creates an XML Layout. + * Creates an JSON Layout. * * @param locationInfo * If "true", includes the location information in the generated JSON. @@ -356,7 +356,7 @@ public String getContentType() { * If "true", does not use end-of-lines and indentation, defaults to "false". * @param charsetName * The character set to use, if {@code null}, uses "UTF-8". - * @return An XML Layout. + * @return An JSON Layout. */ @PluginFactory public static JSONLayout createLayout(