diff options
Diffstat (limited to 'src/lombok')
-rw-r--r-- | src/lombok/EqualsAndHashCode.java | 1 | ||||
-rw-r--r-- | src/lombok/ToString.java | 17 |
2 files changed, 16 insertions, 2 deletions
diff --git a/src/lombok/EqualsAndHashCode.java b/src/lombok/EqualsAndHashCode.java index 715dbd7a..ac2b95a1 100644 --- a/src/lombok/EqualsAndHashCode.java +++ b/src/lombok/EqualsAndHashCode.java @@ -64,6 +64,7 @@ public @interface EqualsAndHashCode { /** * Call on the superclass's implementations of <code>equals</code> and <code>hashCode</code> before calculating * for the fields in this class. + * <strong>default: false</strong> */ boolean callSuper() default false; } diff --git a/src/lombok/ToString.java b/src/lombok/ToString.java index 8067f647..5bcba540 100644 --- a/src/lombok/ToString.java +++ b/src/lombok/ToString.java @@ -36,7 +36,7 @@ import java.lang.annotation.Target; * All fields that are non-static are used in the toString generation. You can exclude fields by specifying them * in the <code>exclude</code> parameter. * <p> - * Array fields are handled by way of {@link java.util.Arrays#deepToString(Object[], Object[])} where necessary. + * Array fields are handled by way of {@link java.util.Arrays#deepToString(Object[])} where necessary. * The downside is that arrays with circular references (arrays that contain themselves, * possibly indirectly) results in calls to <code>toString</code> throwing a * {@link java.lang.StackOverflowError}. However, the implementations for java's own {@link java.util.ArrayList} suffer @@ -51,7 +51,20 @@ import java.lang.annotation.Target; @Target(ElementType.TYPE) @Retention(RetentionPolicy.SOURCE) public @interface ToString { + /** + * Include the name of each field when printing it. + * <strong>default: false</strong> + */ boolean includeFieldNames() default false; - boolean callSuper() default false; + + /** + * Any fields listed here will not be printed in the generated <code>toString</code> implementation. + */ String[] exclude() default {}; + + /** + * Include the result of the superclass's implementation of <code>toString</code> in the output. + * <strong>default: false</strong> + */ + boolean callSuper() default false; } |