commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bay...@apache.org
Subject svn commit: r591559 - /commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java
Date Sat, 03 Nov 2007 08:03:35 GMT
Author: bayard
Date: Sat Nov  3 01:03:33 2007
New Revision: 591559

URL: http://svn.apache.org/viewvc?rev=591559&view=rev
Log:
Applying Scott Bassin's patch from LANG-371 - improving the documentation for ToStringStyle
as per Paul's report

Modified:
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java?rev=591559&r1=591558&r2=591559&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java
(original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/ToStringStyle.java
Sat Nov  3 01:03:33 2007
@@ -71,28 +71,59 @@
 public abstract class ToStringStyle implements Serializable {
 
     /**
-     * The default toString style.
+     * The default toString style. Using the Using the <code>Person</code>
+     * example from {@link ToStringBuilder}, the output would look like this:
+     * 
+     * <pre>
+     * Person@182f0db[name=John Doe,age=33,smoker=false]
+     * </pre>
      */
     public static final ToStringStyle DEFAULT_STYLE = new DefaultToStringStyle();
     
     /**
-     * The multi line toString style.
+     * The multi line toString style. Using the Using the <code>Person</code>
+     * example from {@link ToStringBuilder}, the output would look like this:
+     * 
+     * <pre>
+     * Person@182f0db[
+     *   name=John Doe
+     *   age=33
+     *   smoker=false
+     * ]
+     * </pre>
      */
     public static final ToStringStyle MULTI_LINE_STYLE = new MultiLineToStringStyle();
     
     /**
-     * The no field names toString style.
+     * The no field names toString style. Using the Using the
+     * <code>Person</code> example from {@link ToStringBuilder}, the output
+     * would look like this:
+     * 
+     * <pre>
+     * Person@182f0db[John Doe,33,false]
+     * </pre>
      */
     public static final ToStringStyle NO_FIELD_NAMES_STYLE = new NoFieldNameToStringStyle();
     
     /**
-     * The short prefix toString style.
+     * The short prefix toString style. Using the <code>Person</code> example
+     * from {@link ToStringBuilder}, the output would look like this:
+     * 
+     * <pre>
+     * Person[name=John Doe,age=33,smoker=false]
+     * </pre>
+     * 
      * @since 2.1
      */
     public static final ToStringStyle SHORT_PREFIX_STYLE = new ShortPrefixToStringStyle();
 
     /**
-     * The simple toString style.
+     * The simple toString style. Using the Using the <code>Person</code>
+     * example from {@link ToStringBuilder}, the output would look like this:
+     * 
+     * <pre>
+     * John Doe,33,false
+     * </pre>
      */
     public static final ToStringStyle SIMPLE_STYLE = new SimpleToStringStyle();
     



Mime
View raw message