<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" > <channel><title>Comments on: Null-safe Type in Java 7: New way to handle NullPointerException</title> <atom:link href="http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/feed" rel="self" type="application/rss+xml" /><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html</link> <description>Tutorials, Java, J2EE, Struts, AJAX, JavaScript, CSS, Web 2.0, MySQL, Articles</description> <lastBuildDate>Wed, 08 Feb 2012 10:36:26 +0000</lastBuildDate> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>By: Tim</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11493</link> <dc:creator>Tim</dc:creator> <pubDate>Mon, 12 Oct 2009 15:28:19 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11493</guid> <description>Null safe checks are useful in large legacy codebase.   I personally prefer to fail fast with liberal use of preconditions to fail early in a method call however different processing needs have different requirements.This syntax is horrible and I cant thing of something better.I do think of C++ and the -&gt; Operatorpublic String getPostcode(Person person) { return person-&gt;getAddress()-&gt;getPostcode(); }Or potentially use the .. operator (my own concoction)public String getPostcode(Person person) { return person..getAddress()..getPostcode(); }Both seem horrible because of c++ nostalga and general eyesore.</description> <content:encoded><![CDATA[<p>Null safe checks are useful in large legacy codebase.   I personally prefer to fail fast with liberal use of preconditions to fail early in a method call however different processing needs have different requirements.</p><p>This syntax is horrible and I cant thing of something better.</p><p>I do think of C++ and the -&gt; Operator</p><p>public String getPostcode(Person person) {<br /> return person-&gt;getAddress()-&gt;getPostcode();<br /> }</p><p>Or potentially use the .. operator (my own concoction)</p><p>public String getPostcode(Person person) {<br /> return person..getAddress()..getPostcode();<br /> }</p><p>Both seem horrible because of c++ nostalga and general eyesore.</p> ]]></content:encoded> </item> <item><title>By: Kon Soulianidis</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11481</link> <dc:creator>Kon Soulianidis</dc:creator> <pubDate>Thu, 08 Oct 2009 22:37:38 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11481</guid> <description>Yes, it was rejected.  Whilst it makes sense in Groovy, when actually tried out with real Java codebases as part of project coin testing, it didnt work so well compared to the Groovy implementation.  Who knows, if you want it, contribute to the project.Javaposse interview with Project Coin is a great resource about the how and why http://javaposse.com/index.php?post_id=529403I would strongly recommend Viral puts an Edit at the top of the article per Stephan and Stefans comments.</description> <content:encoded><![CDATA[<p>Yes, it was rejected.  Whilst it makes sense in Groovy, when actually tried out with real Java codebases as part of project coin testing, it didnt work so well compared to the Groovy implementation.  Who knows, if you want it, contribute to the project.</p><p>Javaposse interview with Project Coin is a great resource about the how and why <a href="http://javaposse.com/index.php?post_id=529403" rel="nofollow">http://javaposse.com/index.php?post_id=529403</a></p><p>I would strongly recommend Viral puts an Edit at the top of the article per Stephan and Stefans comments.</p> ]]></content:encoded> </item> <item><title>By: Pascal</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11476</link> <dc:creator>Pascal</dc:creator> <pubDate>Thu, 08 Oct 2009 12:12:54 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11476</guid> <description>I do not like this. This makes it very difficult to read there is an null check and people will most likely over use it. There are times when it&#039;s valid to do a null check and there are times it&#039;s simply hiding a bug elsewhere. Also, during debugging, it would make it difficult to know which value is null.</description> <content:encoded><![CDATA[<p>I do not like this. This makes it very difficult to read there is an null check and people will most likely over use it. There are times when it&#8217;s valid to do a null check and there are times it&#8217;s simply hiding a bug elsewhere. Also, during debugging, it would make it difficult to know which value is null.</p> ]]></content:encoded> </item> <item><title>By: Stephen Colebourne</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11474</link> <dc:creator>Stephen Colebourne</dc:creator> <pubDate>Thu, 08 Oct 2009 09:53:23 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11474</guid> <description>I believe that the opinion is that it would promote the use of null, which is &#039;a bad thing&#039;. Personally, I&#039;m more pragmatic and think that avoiding loads of NPEs justifies the change. I know I would have used it all the time. If you don&#039;t like the decision, write to the Coin mailing list.</description> <content:encoded><![CDATA[<p>I believe that the opinion is that it would promote the use of null, which is &#8216;a bad thing&#8217;. Personally, I&#8217;m more pragmatic and think that avoiding loads of NPEs justifies the change. I know I would have used it all the time. If you don&#8217;t like the decision, write to the Coin mailing list.</p> ]]></content:encoded> </item> <item><title>By: Luciano Fiandesio</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11472</link> <dc:creator>Luciano Fiandesio</dc:creator> <pubDate>Thu, 08 Oct 2009 07:44:03 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11472</guid> <description>This is the way Freemarker handles Null. In Freemarker you can go like: ( object.getThis().getThat() )?</description> <content:encoded><![CDATA[<p>This is the way Freemarker handles Null. In Freemarker you can go like:<br /> ( object.getThis().getThat() )?</p> ]]></content:encoded> </item> <item><title>By: Raminder</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11470</link> <dc:creator>Raminder</dc:creator> <pubDate>Thu, 08 Oct 2009 04:25:23 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11470</guid> <description>Wow !! Its looks great. Certainly helpful. @ Stephen Colebourne: Can you provide more details for rejection?</description> <content:encoded><![CDATA[<p>Wow !! Its looks great. Certainly helpful.<br /> @ Stephen Colebourne: Can you provide more details for rejection?</p> ]]></content:encoded> </item> <item><title>By: Stefan Zobel</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11467</link> <dc:creator>Stefan Zobel</dc:creator> <pubDate>Wed, 07 Oct 2009 19:13:45 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11467</guid> <description>Seehttp://blogs.sun.com/darcy/entry/project_coin_final_five</description> <content:encoded><![CDATA[<p>See</p><p><a href="http://blogs.sun.com/darcy/entry/project_coin_final_five" rel="nofollow">http://blogs.sun.com/darcy/entry/project_coin_final_five</a></p> ]]></content:encoded> </item> <item><title>By: Stephen Colebourne</title><link>http://viralpatel.net/blogs/2009/10/null-safe-type-java-7-nullpointerexception.html/comment-page-1#comment-11464</link> <dc:creator>Stephen Colebourne</dc:creator> <pubDate>Wed, 07 Oct 2009 13:51:39 +0000</pubDate> <guid isPermaLink="false">http://viralpatel.net/blogs/?p=1823#comment-11464</guid> <description>This was rejected by Project Coin.</description> <content:encoded><![CDATA[<p>This was rejected by Project Coin.</p> ]]></content:encoded> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced

Served from: viralpatel.net @ 2012-02-09 09:52:11 -->
