aboutsummaryrefslogtreecommitdiff
path: root/website/features
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@tipit.to>2009-07-17 21:25:36 +0200
committerReinier Zwitserloot <reinier@tipit.to>2009-07-17 21:25:36 +0200
commit642dad3f0c13a8a900aac21fe26e1eb672fbb5a6 (patch)
tree8b7c7577ad569d430ffc0ce278abd19248e6c774 /website/features
parent3bfe8d21610b7d92aa932685bc40abf011295328 (diff)
downloadlombok-642dad3f0c13a8a900aac21fe26e1eb672fbb5a6.tar.gz
lombok-642dad3f0c13a8a900aac21fe26e1eb672fbb5a6.tar.bz2
lombok-642dad3f0c13a8a900aac21fe26e1eb672fbb5a6.zip
Very minor typos in Data/GetterSetter, added an index page for the features overview, and increased transparancy on the pepper background.
Diffstat (limited to 'website/features')
-rw-r--r--website/features/Data.html29
-rw-r--r--website/features/GetterSetter.html29
-rw-r--r--website/features/features.css25
-rw-r--r--website/features/index.html35
-rw-r--r--website/features/lombok-background.pngbin34309 -> 34208 bytes
5 files changed, 91 insertions, 27 deletions
diff --git a/website/features/Data.html b/website/features/Data.html
index 3a9697cc..23f9cea8 100644
--- a/website/features/Data.html
+++ b/website/features/Data.html
@@ -41,6 +41,20 @@
instance. This way, javac will infer the variable name. Thus, by declaring like so: <code>@Data(staticConstructor="of") class Foo&lt;T&gt; { private T x;}</code>
you can create new instances of <code>Foo</code> by writing: <code>Foo.of(5);</code> instead of having to write: <code>new Foo&lt;Integer&gt;(5);</code>.
</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>
Arrays are 'deep' compared/printed/hashCoded, which means that arrays that contain themselves will result in <code>StackOverflowError</code>s. However,
@@ -49,7 +63,7 @@
You may safely presume that the hashCode implementation used will not change between versions of lombok, however this guarantee is not set in stone;
if there's a significant performance improvement to be gained from using an alternate hash algorithm, that will be substituted in a future version.
</p><p>
- For a general idea of how lombok generated the <code>equals</code>, <code>hashCode</code>, and <code>toString</code> methods, check the example below.
+ For a general idea of how lombok generated the <code>equals</code>, <code>hashCode</code>, and <code>toString</code> methods, check the example after.
</p><p>
For the purposes of equality, 2 <code>NaN</code> (not a number) values for floats and doubles are considered equal, eventhough 'NaN == NaN' would
return false. This is analogous to <code>java.lang.Double</code>'s equals method, and is in fact required to ensure that comparing an object
@@ -57,19 +71,8 @@
</p>
</div>
</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>
<footer>
- <a href="features.html">Back to features</a> | <a href="GetterSetter.html">Previous feature (@Getter / @Setter)</a> | <a href="Cleanup.html">Next feature (@Cleanup)</a><br />
+ <a href="index.html">Back to features</a> | <a href="GetterSetter.html">Previous feature (@Getter / @Setter)</a> | <a href="Cleanup.html">Next feature (@Cleanup)</a><br />
<span class="copyright">Copyright &copy; 2009 Reinier Zwitserloot and Roel Spilker, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT licence</a>.</span>
</footer>
<div style="clear: both;"></div>
diff --git a/website/features/GetterSetter.html b/website/features/GetterSetter.html
index 9840d3ba..e865cfff 100644
--- a/website/features/GetterSetter.html
+++ b/website/features/GetterSetter.html
@@ -20,9 +20,23 @@
if the field's type is <code>boolean</code>). A default setter is named <code>setFoo</code> if the field is called <code>foo</code>, returns <code>void</code>,
and takes 1 parameter of the same type as the field. It simply sets the field to this value.
</p><p>
- The generated getter/setter method will be <code>public</code> unless you explicitly specify an <code>AccessLevel</code>, as shown in the example below.
+ The generated getter/setter method will be <code>public</code> unless you explicitly specify an <code>AccessLevel</code>, as shown in the example above.
Legal access levels are <code>PUBLIC</code>, <code>PROTECTED</code>, <code>PACKAGE</code>, and <code>PRIVATE</code>.
</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>
For generating the method names, the first character of the field, if it is a lowercase character, is title-cased, otherwise, it is left unmodified.
@@ -37,19 +51,8 @@
</p>
</div>
</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>
<footer>
- <a href="features.html">Back to features</a> | <span class="disabled">Previous feature</span> | <a href="Data.html">Next feature (@Data)</a><br />
+ <a href="index.html">Back to features</a> | <span class="disabled">Previous feature</span> | <a href="Data.html">Next feature (@Data)</a><br />
<span class="copyright">Copyright &copy; 2009 Reinier Zwitserloot and Roel Spilker, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT licence</a>.</span>
</footer>
<div style="clear: both;"></div>
diff --git a/website/features/features.css b/website/features/features.css
index 4f8fe468..f2eff7fc 100644
--- a/website/features/features.css
+++ b/website/features/features.css
@@ -33,10 +33,33 @@ h1 {
text-align: center;
}
-.overview code {
+.index {
+ font-size: 1.2em;
+ margin: 64px 0px 32px 64px;
+}
+
+.index dt {
+ margin-top: 8px;
font-size: 1.2em;
}
+.index dd {
+ margin-left: 32px;
+}
+
+.overview code {
+ font-size: 1.1em;
+}
+
+.smallprint {
+ font-size: 0.8em;
+ color: #444;
+}
+
+.smallprint code {
+ font-size: 1em;
+}
+
.snippets {
margin-top: 32px;
}
diff --git a/website/features/index.html b/website/features/index.html
new file mode 100644
index 00000000..c270f4e3
--- /dev/null
+++ b/website/features/index.html
@@ -0,0 +1,35 @@
+<!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>Lombok feature overview</title>
+ <!--[if lt IE 7]><script type="text/javascript" src="logi/iepngfix_tilebg.js"></script><![endif]-->
+</head><body><div id="pepper">
+ <div class="meat">
+ <div class="minimumHeight"></div>
+ <div class="header"><a href="../index.html">Project Lombok</a></div>
+ <h1>Lombok features</h1>
+ <div class="index overview">
+ <dl>
+ <dt><a href="GetterSetter.html"><code>@Getter</code> / <code>@Setter</code></a></dt>
+ <dd>Never write <code>public int getFoo() {return foo;}</code> again.</dd>
+ <dt><a href="Data.html"><code>@Data</code></a></dt>
+ <dd>'struct' for java: Automatically generate <code>toString</code>, <code>hashCode</code>, <code>equals</code>, a constructor, and getters and setters
+ from just the fields in your class.</dd>
+ <dt><a href="Cleanup.html"><code>@Cleanup</code></a></dt>
+ <dd>Automatic resource management: Call your <code>close()</code> methods safely with no hassle.</dd>
+ <dt><a href="Synchronized.html"><code>@Synchronized</code></a></dt>
+ <dd><code>synchronized</code> done right: Don't expose your locks.</dd>
+ <dt><a href="SneakyThrows.html"><code>@SneakyThrows</code></a></dt>
+ <dd>To boldly throw checked exceptions where no one has thrown them before!</dd>
+ </dl>
+ </div>
+ <footer>
+ <span class="copyright">Copyright &copy; 2009 Reinier Zwitserloot and Roel Spilker, licensed under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT licence</a>.</span>
+ </footer>
+ <div style="clear: both;"></div>
+ </div>
+</div></body></html>
diff --git a/website/features/lombok-background.png b/website/features/lombok-background.png
index 0fbdf64c..aac3195a 100644
--- a/website/features/lombok-background.png
+++ b/website/features/lombok-background.png
Binary files differ