From e92fd5abac039cfc1f47a030dc0f084e9f018b8b Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Fri, 28 Aug 2009 00:16:58 +0200 Subject: Fixes issue #35: ToString now defaults to includeFieldNames=true. --- src/lombok/ToString.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/lombok/ToString.java b/src/lombok/ToString.java index 5bcba540..10c61807 100644 --- a/src/lombok/ToString.java +++ b/src/lombok/ToString.java @@ -42,8 +42,9 @@ import java.lang.annotation.Target; * {@link java.lang.StackOverflowError}. However, the implementations for java's own {@link java.util.ArrayList} suffer * from the same flaw. *

- * The toString method that is generated will print the class name as well as each field. You can optionally - * also print the names of each field, by setting the includeFieldNames flag to true. + * The toString method that is generated will print the class name as well as each field (both the name + * and the value). You can optionally choose to suppress the printing of the field name, by setting the + * includeFieldNames flag to false. *

* You can also choose to include the result of toString in your class's superclass by setting the * callSuper to true. @@ -53,9 +54,9 @@ import java.lang.annotation.Target; public @interface ToString { /** * Include the name of each field when printing it. - * default: false + * default: true */ - boolean includeFieldNames() default false; + boolean includeFieldNames() default true; /** * Any fields listed here will not be printed in the generated toString implementation. -- cgit