diff options
author | Reinier Zwitserloot <reinier@zwitserloot.com> | 2013-06-25 00:23:02 +0200 |
---|---|---|
committer | Reinier Zwitserloot <reinier@zwitserloot.com> | 2013-06-25 00:23:02 +0200 |
commit | b5747963c022f680168ff66ebdc7860adb954882 (patch) | |
tree | b88314281dff0f022a85c941c6f53830ec18a1ab /website/features/experimental | |
parent | e1c39bbc601408decb0ae147d181708a5af41307 (diff) | |
download | lombok-b5747963c022f680168ff66ebdc7860adb954882.tar.gz lombok-b5747963c022f680168ff66ebdc7860adb954882.tar.bz2 lombok-b5747963c022f680168ff66ebdc7860adb954882.zip |
Value has been promoted to the main package.
Diffstat (limited to 'website/features/experimental')
-rw-r--r-- | website/features/experimental/Value.html | 81 | ||||
-rw-r--r-- | website/features/experimental/Wither.html | 2 | ||||
-rw-r--r-- | website/features/experimental/index.html | 9 | ||||
-rw-r--r-- | website/features/experimental/onX.html | 2 |
4 files changed, 9 insertions, 85 deletions
diff --git a/website/features/experimental/Value.html b/website/features/experimental/Value.html deleted file mode 100644 index d2acfee4..00000000 --- a/website/features/experimental/Value.html +++ /dev/null @@ -1,81 +0,0 @@ -<!DOCTYPE html> -<html><head> - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> - <link rel="stylesheet" type="text/css" href="../../logi/reset.css" /> - <link rel="stylesheet" type="text/css" href="../features.css" /> - <link rel="shortcut icon" href="../../favicon.ico" type="image/x-icon" /> - <meta name="description" content="Spice up your java" /> - <title>EXPERIMENTAL - @ExtensionMethod</title> -</head><body><div id="pepper"> - <div class="minimumHeight"></div> - <div class="meat"> - <div class="header"><a href="../../index.html">Project Lombok</a></div> - <h1>@Value</h1> - <div class="byline">Immutable classes made very easy.</div> - <div class="since"> - <h3>Since</h3> - <p> - <code>@Value</code> was introduced as experimental feature in lombok v0.11.4. - </p><p> - <code>@Value</code> no longer implies <code>@Wither</code> since lombok v0.11.8. - </div> - <div class="experimental"> - <h3>Experimental</h3> - <p> - Experimental because: - <ul> - <li>Various choices still have to be vetted as being the correct 'least surprise' choice: Should the class be made final by default, etc.</li> - </ul> - Current status: <em>positive</em> - Currently we feel this feature may move out of experimental status with no or minor changes soon. - </div> - <div class="overview"> - <h3>Overview</h3> - <p> - <code>@Value</code> is the immutable variant of <a href="../Data.html"><code>@Data</code></a>; all fields are made <code>private</code> and <code>final</code> by default, and setters are not generated. The class itself is also made <code>final</code> by default, because immutability is not something that can be forced onto a subclass. Like <code>@Data</code>, useful <code>toString()</code>, <code>equals()</code> and <code>hashCode()</code> methods are also generated, each field gets a getter method, and a constructor that covers every - argument (except <code>final</code> fields that are initialized in the field declaration) is also generated. - </p><p> - In practice, <code>@Value</code> is shorthand for: <code>final @ToString @EqualsAndHashCode @AllArgsConstructor @FieldDefaults(makeFinal = true, level = AccessLevel.PRIVATE) @Getter</code>. - </p><p> - It is possible to override the final-by-default and private-by-default behaviour using either an explicit access level on a field, or by using the <code>@NonFinal</code> or <code>@PackagePrivate</code> annotations.<br /> - It is possible to override any default behaviour for any of the 'parts' that make up <code>@Value</code> by explicitly using that annotation. - </p> - </div> - <div class="snippets"> - <div class="pre"> - <h3>With Lombok</h3> - <div class="snippet">@HTML_PRE@</div> - </div> - <div class="sep"></div> - <div class="post"> - <h3>Vanilla Java</h3> - <div class="snippet">@HTML_POST@</div> - </div> - </div> - <div style="clear: left;"></div> - <div class="overview"> - <h3>Small print</h3><div class="smallprint"> - <p> - Look for the documentation on the 'parts' of <code>@Value</code>: <a href="../ToString.html"><code>@ToString</code></a>, <a href="../EqualsAndHashCode.html"><code>@EqualsAndHashCode</code></a>, <a href="../Constructor.html"><code>@AllArgsConstructor</code></a>, <a href="FieldDefaults.html"><code>@FieldDefaults</code></a>, and <a href="../GetterSetter.html"><code>@Getter</code></a>. - </p><p> - For classes with generics, it's useful to have a static method which serves as a constructor, because inference of generic parameters via static methods works in java6 and avoids having to use the diamond operator. While you can force this by applying an explicit <code>@AllArgsConstructor(staticConstructor="of")</code> annotation, there's also the <code>@Value(staticConstructor="of")</code> feature, which will make the generated all-arguments constructor private, and generates a public static method named <code>of</code> which is a wrapper around this private constructor. - </p> - </div> - </div> - <div class="footer"> - <a href="index.html">Back to experimental features</a> | <a href="Wither.html">Previous feature (@Wither)</a> | <a href="onX.html">Next feature (onX)</a><br /> - <a href="../../credits.html" class="creditsLink">credits</a> | <span class="copyright">Copyright © 2009-2013 The Project Lombok Authors, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT license</a>.</span> - </div> - <div style="clear: both;"></div> - </div> -</div> -<script type="text/javascript"> - var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); - document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); -</script> -<script type="text/javascript"> - try { - var pageTracker = _gat._getTracker("UA-9884254-1"); - pageTracker._trackPageview(); - } catch(err) {} -</script> -</body></html> diff --git a/website/features/experimental/Wither.html b/website/features/experimental/Wither.html index da2156cd..9cbcd5ed 100644 --- a/website/features/experimental/Wither.html +++ b/website/features/experimental/Wither.html @@ -83,7 +83,7 @@ </div> </div> <div class="footer"> - <a href="index.html">Back to experimental features</a> | <a href="FieldDefaults.html">Previous feature (@FieldDefaults)</a> | <a href="Value.html">Next feature (@Value)</a><br /> + <a href="index.html">Back to experimental features</a> | <a href="FieldDefaults.html">Previous feature (@FieldDefaults)</a> | <a href="onX.html">Next feature (onX)</a><br /> <a href="../../credits.html" class="creditsLink">credits</a> | <span class="copyright">Copyright © 2009-2013 The Project Lombok Authors, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT license</a>.</span> </div> <div style="clear: both;"></div> diff --git a/website/features/experimental/index.html b/website/features/experimental/index.html index d0a086a0..31fcd5ad 100644 --- a/website/features/experimental/index.html +++ b/website/features/experimental/index.html @@ -32,12 +32,17 @@ <dd>New default field modifiers for the 21st century.</dd> <dt><a href="Wither.html"><code>@Wither</code></a></dt> <dd>Immutable 'setters' - methods that create a clone but with one changed field.</dd> - <dt><a href="Value.html"><code>@Value</code></a></dt> - <dd>Immutable classes made very easy.</dd> <dt><a href="onX.html"><code>onMethod= / onConstructor= / onParam</code></a></dt> <dd>Sup dawg, we heard you like annotations, so we put annotations in your annotations so you can annotate while you're annotating.</dd> </dl> </div> + <div class="index overview"> + <h3>Putting the "Ex" in "Experimental": promoted or deleted experimental features.</h3> + <dl> + <dt><a href="../Value.html"><code>@Value</code></a>: Promoted</dt> + <dd><code>@Value</code> has proven its value and has been moved to the main package.</li> + </dl> + </div> <div class="footer"> <a href="../../credits.html" class="creditsLink">credits</a> | <span class="copyright">Copyright © 2009-2013 The Project Lombok Authors, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT license</a>.</span> </div> diff --git a/website/features/experimental/onX.html b/website/features/experimental/onX.html index 99365deb..66b0164f 100644 --- a/website/features/experimental/onX.html +++ b/website/features/experimental/onX.html @@ -69,7 +69,7 @@ </div> </div> <div class="footer"> - <a href="index.html">Back to experimental features</a> | <a href="Value.html">Previous feature (@Value)</a> | <span class="disabled">Next feature</span><br /> + <a href="index.html">Back to experimental features</a> | <a href="Wither.html">Previous feature (@Wither)</a> | <span class="disabled">Next feature</span><br /> <a href="../../credits.html" class="creditsLink">credits</a> | <span class="copyright">Copyright © 2009-2013 The Project Lombok Authors, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT license</a>.</span> </div> <div style="clear: both;"></div> |