fixed ExtensionMethod example to return T (generic type) , seem to remove or forgot for some reason...

This commit is contained in:
Daniel committed 2018-03-21 21:54:07 +02:00
1 parent 5a5d75a931
commit 57b66fd576
1 file changed
+1 -1
@@ -36,7 +36,7 @@
</p><p>
Lombok does not (currently) have any runtime dependencies which means lombok does not (currently) ship with any useful extension methods so you'll have to make your own. However, here's one that might spark your imagination: <br />
<pre>public class ObjectExtensions {
public static &lt;T&gt; or(T object, T ifNull) {
public static &lt;T&gt; T or(T object, T ifNull) {
return object != null ? object : ifNull;
}
}</pre><br />