aboutsummaryrefslogtreecommitdiff
path: root/src/core/lombok/experimental/Value.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lombok/experimental/Value.java')
-rw-r--r--src/core/lombok/experimental/Value.java31
1 files changed, 9 insertions, 22 deletions
diff --git a/src/core/lombok/experimental/Value.java b/src/core/lombok/experimental/Value.java
index 70ac1ba7..6c07d2fc 100644
--- a/src/core/lombok/experimental/Value.java
+++ b/src/core/lombok/experimental/Value.java
@@ -28,30 +28,17 @@ import java.lang.annotation.Target;
/**
* Generates a lot of code which fits with a class that is a representation of an immutable entity.
- * Specifically, it generates:<ul>
- * <li>Getters for all fields
- * <li>toString method
- * <li>hashCode and equals implementations that check all non-transient fields.
- * <li>Generates withers for all fields (except final fields that are initialized in the field declaration itself)
- * <li>Generates a constructor for each argument
- * <li>Adds {@code private} and {@code final} to each field.
- * <li>Makes the class itself final.
- * </ul>
- *
- * In other words, {@code @Value} is a shorthand for:<br />
- * {@code final @Getter @Wither @FieldDefaults(makeFinal=true,level=AccessLevel.PRIVATE) @EqualsAndHashCode @ToString @AllArgsConstructor}.
- * <p>
- * If any method to be generated already exists (in name and parameter count - the return type or parameter types are not relevant), then
- * that method will not be generated by the Value annotation.
* <p>
- * The generated constructor will have 1 parameter for each field. The generated toString will print all fields,
- * while the generated hashCode and equals take into account all non-transient fields.<br>
- * Static fields are skipped (no getter or setter, and they are not included in toString, equals, hashCode, or the constructor).
+ * Equivalent to {@code @Getter @Wither @FieldDefaults(makeFinal=true, level=AccessLevel.PRIVATE) @RequiredArgsConstructor @ToString @EqualsAndHashCode}.
* <p>
- * {@code toString}, {@code equals}, and {@code hashCode} use the deepX variants in the
- * {@code java.util.Arrays} utility class. Therefore, if your class has arrays that contain themselves,
- * these methods will just loop endlessly until the inevitable {@code StackOverflowError}. This behaviour
- * is no different from {@code java.util.ArrayList}, though.
+ * Complete documentation is found at <a href="http://projectlombok.org/features/experimental/Value.html">the project lombok features page for &#64;Value</a>.
+ *
+ * @see lombok.Getter
+ * @see Wither
+ * @see lombok.RequiredArgsConstructor
+ * @see lombok.ToString
+ * @see lombok.EqualsAndHashCode
+ * @see lombok.Data
*/
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.SOURCE)