<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Molindo Techblog &#187; Fun</title>
	<atom:link href="http://techblog.molindo.at/category/fun/feed" rel="self" type="application/rss+xml" />
	<link>http://techblog.molindo.at</link>
	<description>Molindo Techblog - formerly known as talk-on-tech.blogspot.com</description>
	<lastBuildDate>Fri, 05 Feb 2010 16:06:12 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Fun Friday Second Life</title>
		<link>http://techblog.molindo.at/2008/07/fun-friday-second-life.html</link>
		<comments>http://techblog.molindo.at/2008/07/fun-friday-second-life.html#comments</comments>
		<pubDate>Fri, 25 Jul 2008 08:26:00 +0000</pubDate>
		<dc:creator>Michael Sparer</dc:creator>
				<category><![CDATA[Fun]]></category>

		<guid isPermaLink="false">http://tech.molindo.at/2008/07/fun-friday-second-life.html</guid>
		<description><![CDATA[I found a link to some interesting college art work while browsing SEOMoz&#8217;s roundup thursday.
College students could gain an additional point in an exam if they could &#8216;answer&#8217; the following question:
Choose a particular piece of web-related software, such as a particular web browser, operating system or text editor. Then draw a picture of what a [...]]]></description>
			<content:encoded><![CDATA[<p>I found a link to <a href="http://www.cs.washington.edu/education/courses/190m/08sp/exams/final/student_art.pdf">some interesting college art work </a>while browsing <a href="http://www.seomoz.org/blog/roundup-thursday-for-the-week-of-72008">SEOMoz&#8217;s roundup</a> thursday.<br />
College students could gain an additional point in an exam if they could &#8216;answer&#8217; the following question:</p>
<p><em style="font-weight: bold;">Choose a particular piece of web-related software, such as a particular web browser, operating system or text editor. Then draw a picture of what a typical user of that software looks like. </em></p>
<p><a href="http://www.songtexte.com/user/fuzy">Stefan </a>was sure he could have answered the exam question better than the rest &#8230; and for sure he did. but have a look for yourself.<br />
<span id="more-21"></span><br />
<a href="http://bp0.blogger.com/_uXeW0-_1vE0/SImO3QOUv6I/AAAAAAAAAAM/lgE_aRgJZ38/s1600-h/2ndlife_small.jpg" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"><img id="BLOGGER_PHOTO_ID_5226865922439167906" style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 358px; height: 421px;" src="http://bp0.blogger.com/_uXeW0-_1vE0/SImO3QOUv6I/AAAAAAAAAAM/lgE_aRgJZ38/s320/2ndlife_small.jpg" border="0" alt="" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://techblog.molindo.at/2008/07/fun-friday-second-life.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Overcautious or just paranoid?</title>
		<link>http://techblog.molindo.at/2008/02/overcautious-or-just-paranoid.html</link>
		<comments>http://techblog.molindo.at/2008/02/overcautious-or-just-paranoid.html#comments</comments>
		<pubDate>Wed, 06 Feb 2008 23:01:00 +0000</pubDate>
		<dc:creator>Stefan Fußenegger</dc:creator>
				<category><![CDATA[Fun]]></category>
		<category><![CDATA[Wicket]]></category>

		<guid isPermaLink="false">http://tech.molindo.at/2008/02/overcautious-or-just-paranoid.html</guid>
		<description><![CDATA[Wicket&#8217;s RepeatingView is a very handy component: You can add as many components as you want. As a result, the usage of this component differs from other, as you don&#8217;t add components using html tags with a wicket:id attribute. Instead, IDs are generated by incrementing a number and convert it to a string. The RepeatingView [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://wicket.apache.org/">Wicket</a>&#8217;s <a href="http://people.apache.org/%7Etobrien/wicket/apidocs/org/apache/wicket/markup/repeater/RepeatingView.html">RepeatingView</a> is a very handy component: You can add as many components as you want. As a result, the usage of this component differs from other, as you don&#8217;t add components using html tags with a wicket:id attribute. Instead, IDs are generated by incrementing a number and convert it to a string. The RepeatingView even offers a nice helper method to generate those IDs. Basically, this method does nothing else than<br /><code><br />public String newChildId() {<br />&nbsp; return Integer.toString(childIdCounter++);<br />}<br /></code><br />But the folks behind Wicket seem to work more carefully than I do:</p>
<p><code><br />/**<br />&nbsp;* Generates a unique id string. This makes it easy to add items to be rendered w/out having to<br />&nbsp;* worry about generating unique id strings in your code.<br />&nbsp;*<br />&nbsp;* @return unique child id<br />&nbsp;*/<br />public String newChildId()<br />{<br />&nbsp; childIdCounter++;<br />&nbsp; if (childIdCounter == Long.MAX_VALUE)<br />&nbsp; {<br />&nbsp; &nbsp; // mmm yeah...like this will ever happen<br />&nbsp; &nbsp; throw new RuntimeException("generateChildId() out of space.");<br />&nbsp; }</p>
<p>&nbsp; // We prepend the id's with the text 'id' so they will generate valid<br />&nbsp; // markup id's if needed.<br />&nbsp; return String.valueOf(childIdCounter);<br />}<br /></code><br />But does it really make sense to check whether <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Long.html#MAX_VALUE">Long.MAX_VALUE</a> (2<sup>63</sup>-1 or 9,223,372,036,854,775,808) was reached? The developer doesn&#8217;t believe so, but seems to work carefully &#8230; or overcautious? &#8230; or just paranoid? Well, let&#8217;s do the maths:</p>
<p>As already <a href="http://www.javaworld.com/javaworld/javatips/jw-javatip130.html?page=2">an empty string object has 40 bytes</a> (x86 processor, Sun JVM), creating this number of empty strings would require more than 325.000 petabytes of memory. </p>
<p>But even if the objects are left for garbage collection, calling this method Long.MAX_VALUE times takes ages. I tested the same method with <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Integer.html#MAX_VALUE">Integer.MAX_VALUE</a> (2<sup>31</sup>-1 or 2,147,483,647) on my Pentium M 1.86GHz and it took  14 minutes to hit the RuntimeException. As It would take 2<sup>32</sup> times longer to reach Long.MAX_VALUE, it would approximately take 114,401 years. Quite a long time to construct a web page, eh? <img src='http://techblog.molindo.at/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://techblog.molindo.at/2008/02/overcautious-or-just-paranoid.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
