<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Serkan Kaba</title>
	<atom:link href="http://skaba.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://skaba.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Sun, 06 Mar 2011 07:47:47 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='skaba.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Serkan Kaba</title>
		<link>http://skaba.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://skaba.wordpress.com/osd.xml" title="Serkan Kaba" />
	<atom:link rel='hub' href='http://skaba.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Status of Gobject Introspection for Java-GNOME</title>
		<link>http://skaba.wordpress.com/2010/09/20/status-of-gobject-introspection-for-java-gnome/</link>
		<comments>http://skaba.wordpress.com/2010/09/20/status-of-gobject-introspection-for-java-gnome/#comments</comments>
		<pubDate>Sun, 19 Sep 2010 21:46:49 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=53</guid>
		<description><![CDATA[With the wide adoption of GObject Introspection (GIR for short), and to overcome the limitations (such as being static,  needing manual update of defs files leading to error-prone and out-of-date code generation) the current defs file based parser started to work on GIR based one to replace (or at least accompany it) it. Back in [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=53&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>With the wide adoption of <a href="http://live.gnome.org/GObjectIntrospection" target="_blank">GObject Introspection</a> (GIR for short), and to overcome the limitations (such as being static,  needing manual update of defs files leading to error-prone and out-of-date code generation) the current defs file based parser started to work on GIR based one to replace (or at least accompany it) it. Back in May.</p>
<p>I had 2 paths in the beginning. Parsing the .gir XML files and using girepository API. I initially started with the former but decided with the latter forseeing that XML parsing would be too fragile for changes and too hacky to code (well I ended up having some hacky code with the latter as well <img src='http://s0.wp.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' />  but anyway)</p>
<p>In the current state it works OK for most cases. Still have false generated code both arising from not fully parsing GTypeInfo to string (which I filed <a href="https://bugzilla.gnome.org/show_bug.cgi?id=628812" target="_blank">bug #628812</a> for direct inclusion) , missing (or at least I think) functions (<a href="https://bugzilla.gnome.org/show_bug.cgi?id=630062" target="_blank">Bug #630062</a>), missing coverage (not yet parsing vfuncs which are mapped to signals in java-gnome) and faulty/missing gir data.</p>
<p>So the future is GIR, but still both the bindings developers (us), API developers and GIR developers should improve the current status for robust bindings. Follow up for the progress.</p>
<p><strong>Further addition:</strong> It was revealed that API provided function to parse parameterized G(S)List types.</p>
<br />Filed under: <a href='http://skaba.wordpress.com/category/planet/linux/gnome/'>gnome</a>, <a href='http://skaba.wordpress.com/category/java/'>java</a>, <a href='http://skaba.wordpress.com/category/java-gnome/'>java-gnome</a>, <a href='http://skaba.wordpress.com/category/planet/linux/'>linux</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/53/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=53&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2010/09/20/status-of-gobject-introspection-for-java-gnome/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<georss:point>0.000000 0.000000</georss:point>
		<geo:lat>0.000000</geo:lat>
		<geo:long>0.000000</geo:long>
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>My GSOC Mentorship</title>
		<link>http://skaba.wordpress.com/2010/04/06/my-gsoc-mentorship-1/</link>
		<comments>http://skaba.wordpress.com/2010/04/06/my-gsoc-mentorship-1/#comments</comments>
		<pubDate>Tue, 06 Apr 2010 18:26:28 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[Gentoo]]></category>
		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/2010/04/06/my-gsoc-mentorship-1</guid>
		<description><![CDATA[I applied as a GSOC mentor for the first time. I&#8217;ll be mentoring Gentoo/Java IDE integration project. I&#8217;m personally interested in this project since I use Eclipse for Java development on my Gentoo box and I think many people like me can benefit from the outcome. Although I&#8217;m not a Netbeans user, the same applies [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=70&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I applied as a GSOC mentor for the first time. I&#8217;ll be mentoring  <a href="http://en.gentoo-wiki.com/wiki/Google_Summer_of_Code_2010_ideas#Gentoo.2FJava_IDE_integration">Gentoo/Java IDE integration</a> project. I&#8217;m personally interested in this project since I use Eclipse for Java development on my Gentoo box and I think many people like me can benefit from the outcome. Although I&#8217;m not a Netbeans user, the same applies for it as well. Yes I&#8217;m tired of defining user libraries (additionally pointing to their sources, jni libs, javadocs)</p>
<p>So let&#8217;s see if anyone applies for this project (A few already contacted by mail)</p>
<br />Filed under: <a href='http://skaba.wordpress.com/category/planet/linux/gentoo/'>Gentoo</a>, <a href='http://skaba.wordpress.com/category/java/'>java</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/70/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=70&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2010/04/06/my-gsoc-mentorship-1/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Announcing GMSO 2</title>
		<link>http://skaba.wordpress.com/2010/03/27/announcing-gmso-2/</link>
		<comments>http://skaba.wordpress.com/2010/03/27/announcing-gmso-2/#comments</comments>
		<pubDate>Sat, 27 Mar 2010 12:19:24 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[printing]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=50</guid>
		<description><![CDATA[Years later discontinuing GMSO , a GNOME application to query inklevels of various printers, I started rewriting it in Java using Java-Gnome and JNI to interface with native libraries. The project&#8217;s home page is hosted at Google (http:/mso.googlecode.com) and the source branches are hosted at Launchpad. The project currently consists of 3 components JInkLevel: Java [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=50&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Years later discontinuing GMSO , a GNOME application to query inklevels of various printers, I started rewriting it in Java using Java-Gnome and JNI to interface with native libraries. The project&#8217;s home page is hosted at Google (<a href="http:/mso.googlecode.com" target="_blank">http:/mso.googlecode.com</a>) and the source branches are hosted at Launchpad.</p>
<p>The project currently consists of 3 components</p>
<ul>
<li>JInkLevel: Java bindings for <a href="http://libinklevel.sourceforge.net" target="_self">libinklevel</a>.</li>
<li>LibMso: JNI library to detect printers attached to the system. It uses libhd (part of hwinfo by SuSE)</li>
<li>GMSO 2: The main application</li>
</ul>
<p>See the homepage for screenshots, downloads and javadoc of the libraries. The source code be browsed at <a href="https://code.launchpad.net/~serkan-kaba/mso/" target="_blank">Launchpad</a>. Looking for the future I may be adding additional GUI&#8217;s based on the libraries (Java Swing, SWT, QT &#8230;.)</p>
<br />Filed under: <a href='http://skaba.wordpress.com/category/planet/linux/gnome/'>gnome</a>, <a href='http://skaba.wordpress.com/category/java/'>java</a>, <a href='http://skaba.wordpress.com/category/java-gnome/'>java-gnome</a>, <a href='http://skaba.wordpress.com/category/printing/'>printing</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/50/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=50&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2010/03/27/announcing-gmso-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>0.000000 0.000000</georss:point>
		<geo:lat>0.000000</geo:lat>
		<geo:long>0.000000</geo:long>
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Looking for contributors for my incomplete Java-Gnome Bazaar branches</title>
		<link>http://skaba.wordpress.com/2009/07/27/looking-for-contributor-for-my-incomplete-java-gnome-bazaar-branches/</link>
		<comments>http://skaba.wordpress.com/2009/07/27/looking-for-contributor-for-my-incomplete-java-gnome-bazaar-branches/#comments</comments>
		<pubDate>Mon, 27 Jul 2009 11:58:50 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=34</guid>
		<description><![CDATA[I&#8217;ll be unavailable for a period of time, so my Java-Gnome development will halt during that period. As a result I&#8217;m looking for contributors to continue my incomplete branches. Vte: http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/vte/ VTE library provides a terminal widget which powers Gnome Terminal and other GTK+ terminal emulators. The purpose of this branch to add coverage of [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=34&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ll be unavailable for a period of time, so my Java-Gnome development will halt during that period. As a result I&#8217;m looking for contributors to continue my incomplete branches.</p>
<p><strong>Vte:</strong> <a href="http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/vte/" target="_blank">http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/vte/</a><br />
VTE library provides a terminal widget which powers Gnome Terminal and other GTK+ terminal emulators. The purpose of this branch to add coverage of VTE API.</p>
<p><strong>Sexy:</strong> <a href="http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/sexy/" target="_blank">http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/sexy/</a><br />
<a href="http://www.chipx86.com/w/index.php/Libsexy" target="_blank"> Libsexy</a> provides additional widgets for GTK+. The purpose of this branch to add coverage of widgets provided by Libsexy.</p>
<p><strong>Gerrorcode:</strong> <a href="http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/gerrorcode/" target="_blank">http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/gerrorcode/</a><br />
Current implementation of GlibException doesn&#8217;t capture error code and error domain associated with a GError. The purpose of this branch is to add necessary native and Java bits to provide those these two properties.</p>
<p><strong>Linkbutton:</strong> <a href="http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/linkbutton/" target="_blank">http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/linkbutton/</a><br />
LinkButton is a widget providing an HTML anchor like link. The purpose of this branch is to cover LinkButton.</p>
<p>And thanks in advance to people who take over the development of the branches. And special thanks to Andrew Cowie who helped throughout my Java-Gnome development.</p>
<br />Posted in gnome, java, java-gnome, linux  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/34/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=34&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/07/27/looking-for-contributor-for-my-incomplete-java-gnome-bazaar-branches/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Writing a Last.FM REST client with Jersey and Java-Gnome</title>
		<link>http://skaba.wordpress.com/2009/07/26/writing-a-last-fm-rest-client-with-jersey-and-java-gnome/</link>
		<comments>http://skaba.wordpress.com/2009/07/26/writing-a-last-fm-rest-client-with-jersey-and-java-gnome/#comments</comments>
		<pubDate>Sun, 26 Jul 2009 08:50:49 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[jax-rs]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[rest]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[web service]]></category>
		<category><![CDATA[xml]]></category>
		<category><![CDATA[xml schema]]></category>
		<category><![CDATA[xsd]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=24</guid>
		<description><![CDATA[This tutorial will start with a sample top artists (i.e favorite artists) file from http://ws.audioscrobbler.com/2.0/?method=user.gettopartists&#38;user=Firari&#38;api_key=b25b959554ed76058ac220b7b2e0a026. It will follow several steps to write a dynamic client GTK UI for the topartists service. Project depends on java-gnome (4.0.12+), jsr311-api (aka jax-rs), jersey-core and jersey-client libraries. Note that there&#8217;s a Java library for accessing Last.FM web services available [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=24&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This tutorial will start with a sample top artists (i.e favorite artists) file from <a href="http://ws.audioscrobbler.com/2.0/?method=user.gettopartists&amp;user=Firari&amp;api_key=b25b959554ed76058ac220b7b2e0a026" target="_blank">http://ws.audioscrobbler.com/2.0/?method=user.gettopartists&amp;user=Firari&amp;api_key=b25b959554ed76058ac220b7b2e0a026</a>. It will follow several steps to write a dynamic client GTK UI for the topartists service. Project depends on java-gnome (4.0.12+), jsr311-api (aka jax-rs), jersey-core and jersey-client libraries. Note that there&#8217;s a Java library for accessing Last.FM web services available at <a href="http://www.u-mass.de/lastfm" target="_blank">http://www.u-mass.de/lastfm</a> Project files can be downloaded as a <a href="http://dev.gentoo.org/~serkan/TopArtists.tar.gz">tarball</a>.</p>
<p><strong>Step 1: Generating XML schema from the sample XML</strong></p>
<p>I downloaded a sample file from the the given URL. I used <a href="http://thaiopensource.com/relaxng/trang.html" target="_blank">Trang</a> to reverse engineer the XSD from XML. The command line tool just takes 2 arguments, the input xml and the output xsd files. Here&#8217;s the generated XSD file.</p>
<pre><tt><strong><span style="color:#000080;">&lt;?xml</span></strong> <span style="color:#009900;">version</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"1.0"</span> <span style="color:#009900;">encoding</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"UTF-8"</span><strong><span style="color:#000080;">?&gt;</span></strong>
<strong><span style="color:#0000ff;">&lt;xs:schema</span></strong> <span style="color:#009900;">xmlns:xs</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"http://www.w3.org/2001/XMLSchema"</span> <span style="color:#009900;">elementFormDefault</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"qualified"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"lfm"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;xs:complexType&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:sequence&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"topartists"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;/xs:sequence&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:attribute</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"status"</span> <span style="color:#009900;">use</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"required"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:NCName"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;/xs:complexType&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;/xs:element&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"topartists"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;xs:complexType&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:sequence&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">maxOccurs</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"unbounded"</span> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"artist"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;/xs:sequence&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:attribute</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"type"</span> <span style="color:#009900;">use</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"required"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:NCName"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:attribute</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"user"</span> <span style="color:#009900;">use</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"required"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:NCName"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;/xs:complexType&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;/xs:element&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"artist"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;xs:complexType&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:sequence&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"name"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"playcount"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"mbid"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"url"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"streamable"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">maxOccurs</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"unbounded"</span> <span style="color:#009900;">ref</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"image"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;/xs:sequence&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:attribute</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"rank"</span> <span style="color:#009900;">use</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"required"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:integer"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;/xs:complexType&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;/xs:element&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"name"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:string"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"playcount"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:integer"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"mbid"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:string"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"url"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:anyURI"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"streamable"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:integer"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;xs:element</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"image"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;xs:complexType&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;xs:simpleContent&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;xs:extension</span></strong> <span style="color:#009900;">base</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:anyURI"</span><strong><span style="color:#0000ff;">&gt;</span></strong>
          <strong><span style="color:#0000ff;">&lt;xs:attribute</span></strong> <span style="color:#009900;">name</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"size"</span> <span style="color:#009900;">use</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"required"</span> <span style="color:#009900;">type</span><span style="color:#990000;">=</span><span style="color:#ff0000;">"xs:NCName"</span><strong><span style="color:#0000ff;">/&gt;</span></strong>
        <strong><span style="color:#0000ff;">&lt;/xs:extension&gt;</span></strong>
      <strong><span style="color:#0000ff;">&lt;/xs:simpleContent&gt;</span></strong>
    <strong><span style="color:#0000ff;">&lt;/xs:complexType&gt;</span></strong>
  <strong><span style="color:#0000ff;">&lt;/xs:element&gt;</span></strong>
<strong><span style="color:#0000ff;">&lt;/xs:schema&gt;</span></strong>
</tt></pre>
<p><strong>Step 2: Generating data classes for mapping the xml</strong></p>
<p>xjc (JAXB Binding Compiler) is used to generate the classes in generated package. Jersey can utilize JAXB to map the result XML to data classes.</p>
<p><strong>Step 3: Writing code to query Last.FM web service</strong></p>
<pre><tt><strong><span style="color:#0000ff;">public</span></strong> <strong><span style="color:#0000ff;">static</span></strong> Lfm <strong><span style="color:#000000;">queryTopArtists</span></strong><span style="color:#990000;">(</span>String userName<span style="color:#990000;">)</span> <span style="color:#ff0000;">{</span>
	<strong><span style="color:#0000ff;">final</span></strong> Client client<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">final</span></strong> WebResource webResource<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">final</span></strong> MultivaluedMap queryParams<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">final</span></strong> Lfm result<span style="color:#990000;">;</span>

	client <span style="color:#990000;">=</span> Client<span style="color:#990000;">.</span><strong><span style="color:#000000;">create</span></strong><span style="color:#990000;">();</span>
	webResource <span style="color:#990000;">=</span> client<span style="color:#990000;">.</span><strong><span style="color:#000000;">resource</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"http://ws.audioscrobbler.com/2.0"</span><span style="color:#990000;">);</span>
	queryParams <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">MultivaluedMapImpl</span></strong><span style="color:#990000;">();</span>
	queryParams<span style="color:#990000;">.</span><strong><span style="color:#000000;">add</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"method"</span><span style="color:#990000;">,</span> <span style="color:#ff0000;">"user.gettopartists"</span><span style="color:#990000;">);</span>
	queryParams<span style="color:#990000;">.</span><strong><span style="color:#000000;">add</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"user"</span><span style="color:#990000;">,</span> userName<span style="color:#990000;">);</span>
	queryParams<span style="color:#990000;">.</span><strong><span style="color:#000000;">add</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"api_key"</span><span style="color:#990000;">,</span> <span style="color:#ff0000;">"b25b959554ed76058ac220b7b2e0a026"</span><span style="color:#990000;">);</span>
	result <span style="color:#990000;">=</span> webResource<span style="color:#990000;">.</span><strong><span style="color:#000000;">queryParams</span></strong><span style="color:#990000;">(</span>queryParams<span style="color:#990000;">).</span><strong><span style="color:#000000;">get</span></strong><span style="color:#990000;">(</span>Lfm<span style="color:#990000;">.</span><strong><span style="color:#0000ff;">class</span></strong><span style="color:#990000;">);</span>
	<strong><span style="color:#0000ff;">return</span></strong> result<span style="color:#990000;">;</span>
<span style="color:#ff0000;">}</span>
</tt></pre>
<p>Here we&#8217;re building the HTTP request along with the parameters in the query string. And finally we&#8217;re calling the service and mapping the result to <code>Lfm</code> class which corresponds to XML&#8217;s root element <code>lfm</code>.</p>
<p><strong>Step 4: The GTK+ GUI</strong></p>
<p>Here were initializing the table and its data model.</p>
<pre><tt>
<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;"> * Initialize the table with its DataColumn's.</span></em>
<em><span style="color:#9a1900;"> */</span></em>
model <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">ListStore</span></strong><span style="color:#990000;">(</span><strong><span style="color:#0000ff;">new</span></strong> DataColumn<span style="color:#990000;">[]</span> <span style="color:#ff0000;">{</span> rank <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataColumnString</span></strong><span style="color:#990000;">(),</span>
		artistImage <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataColumnPixbuf</span></strong><span style="color:#990000;">(),</span>
		artist <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataColumnString</span></strong><span style="color:#990000;">(),</span>
		playCount <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataColumnString</span></strong><span style="color:#990000;">(),</span>
		percent <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataColumnInteger</span></strong><span style="color:#990000;">()</span> <span style="color:#ff0000;">}</span><span style="color:#990000;">);</span>
view <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">TreeView</span></strong><span style="color:#990000;">(</span>model<span style="color:#990000;">);</span></tt></pre>
<p>Here we&#8217;re creating the view columns and binding their properties to data model. Note that were&#8217;re binding 2 properties of the <code>CellRendererProgress</code> to different columns in the data model.</p>
<pre><tt><em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;"> * Create TreeViewColumns and bind the DataColumn's to their properties.</span></em>
<em><span style="color:#9a1900;"> */</span></em>
vertical <span style="color:#990000;">=</span> view<span style="color:#990000;">.</span><strong><span style="color:#000000;">appendColumn</span></strong><span style="color:#990000;">();</span>
vertical<span style="color:#990000;">.</span><strong><span style="color:#000000;">setTitle</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"Rank"</span><span style="color:#990000;">);</span>
rendererText <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">CellRendererText</span></strong><span style="color:#990000;">(</span>vertical<span style="color:#990000;">);</span>
rendererText<span style="color:#990000;">.</span><strong><span style="color:#000000;">setText</span></strong><span style="color:#990000;">(</span>rank<span style="color:#990000;">);

</span>vertical <span style="color:#990000;">=</span> view<span style="color:#990000;">.</span><strong><span style="color:#000000;">appendColumn</span></strong><span style="color:#990000;">();</span>
rendererPixbuf <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">CellRendererPixbuf</span></strong><span style="color:#990000;">(</span>vertical<span style="color:#990000;">);</span>
rendererPixbuf<span style="color:#990000;">.</span><strong><span style="color:#000000;">setPixbuf</span></strong><span style="color:#990000;">(</span>artistImage<span style="color:#990000;">);</span>

vertical <span style="color:#990000;">=</span> view<span style="color:#990000;">.</span><strong><span style="color:#000000;">appendColumn</span></strong><span style="color:#990000;">();</span>
vertical<span style="color:#990000;">.</span><strong><span style="color:#000000;">setTitle</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"Artist"</span><span style="color:#990000;">);</span>
rendererText <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">CellRendererText</span></strong><span style="color:#990000;">(</span>vertical<span style="color:#990000;">);</span>
rendererText<span style="color:#990000;">.</span><strong><span style="color:#000000;">setText</span></strong><span style="color:#990000;">(</span>artist<span style="color:#990000;">);</span>

vertical <span style="color:#990000;">=</span> view<span style="color:#990000;">.</span><strong><span style="color:#000000;">appendColumn</span></strong><span style="color:#990000;">();</span>
vertical<span style="color:#990000;">.</span><strong><span style="color:#000000;">setTitle</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"# of times played"</span><span style="color:#990000;">);</span>
rendererProgress <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">CellRendererProgress</span></strong><span style="color:#990000;">(</span>vertical<span style="color:#990000;">);</span>
<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;"> * It's nice that in GTK+ we can bind multiple DataColumn's to</span></em>
<em><span style="color:#9a1900;"> * properties of a single TreeViewColumn.</span></em>
<em><span style="color:#9a1900;"> */</span></em>
rendererProgress<span style="color:#990000;">.</span><strong><span style="color:#000000;">setText</span></strong><span style="color:#990000;">(</span>playCount<span style="color:#990000;">);</span>
rendererProgress<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>percent<span style="color:#990000;">);</span></tt></pre>
<p>Here we&#8217;re querying the service (i.e calling the utility method we wrote) and populating the table. The image data will be fetched asynchroniously by <code>AsyncImageLoader</code> which is a subclass of <code>Thread</code> (Its code wil follow)</p>
<pre><tt><em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;"> * Query Last.FM user.gettopartists method JAX-RS handles the Webservice</span></em>
<em><span style="color:#9a1900;"> * call and JAXB handles the unmarshalling of the XML response.</span></em>
<em><span style="color:#9a1900;"> */</span></em>
result <span style="color:#990000;">=</span> LastFMUtil<span style="color:#990000;">.</span><strong><span style="color:#000000;">queryTopArtists</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"Firari"</span><span style="color:#990000;">);</span>

<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;"> * Add the properties of Artist items as TreeView rows.</span></em>
<em><span style="color:#9a1900;"> */</span></em>
<strong><span style="color:#0000ff;">if</span></strong> <span style="color:#990000;">(</span>result<span style="color:#990000;">.</span><strong><span style="color:#000000;">getStatus</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">equals</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"ok"</span><span style="color:#990000;">))</span> <span style="color:#ff0000;">{</span>
	<strong><span style="color:#0000ff;">final</span></strong> List<span style="color:#990000;">&lt;</span>Artist<span style="color:#990000;">&gt;</span> topArtists <span style="color:#990000;">=</span> result<span style="color:#990000;">.</span><strong><span style="color:#000000;">getTopartists</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">getArtist</span></strong><span style="color:#990000;">();</span>
	<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;">	 * Determining maximum playcount from top of the list.</span></em>
<em><span style="color:#9a1900;">	 * It will be used to calculate the percentage of the ProgressBar's.</span></em>
<em><span style="color:#9a1900;">	 */</span></em>
	maxPlayCount <span style="color:#990000;">=</span> topArtists<span style="color:#990000;">.</span><strong><span style="color:#000000;">get</span></strong><span style="color:#990000;">(</span><span style="color:#993399;">0</span><span style="color:#990000;">).</span><strong><span style="color:#000000;">getPlaycount</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">floatValue</span></strong><span style="color:#990000;">();</span>
	<strong><span style="color:#0000ff;">for</span></strong> <span style="color:#990000;">(</span><strong><span style="color:#0000ff;">final</span></strong> Artist artistItem <span style="color:#990000;">:</span> topArtists<span style="color:#990000;">)</span> <span style="color:#ff0000;">{</span>
		<strong><span style="color:#0000ff;">final</span></strong> TreeIter row <span style="color:#990000;">=</span> model<span style="color:#990000;">.</span><strong><span style="color:#000000;">appendRow</span></strong><span style="color:#990000;">();</span>
		model<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>row<span style="color:#990000;">,</span> rank<span style="color:#990000;">,</span> artistItem<span style="color:#990000;">.</span><strong><span style="color:#000000;">getRank</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">toString</span></strong><span style="color:#990000;">());</span>
		<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;">		 * Asynchronously load the image data and set it as the image</span></em>
<em><span style="color:#9a1900;">		 * column. The first image URL is the "small" one.</span></em>
<em><span style="color:#9a1900;">		 */</span></em>
		<strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">AsyncImageLoader</span></strong><span style="color:#990000;">(</span>model<span style="color:#990000;">,</span> row<span style="color:#990000;">,</span> artistImage<span style="color:#990000;">,</span> artistItem<span style="color:#990000;">.</span><strong><span style="color:#000000;">getImage</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">get</span></strong><span style="color:#990000;">(</span><span style="color:#993399;">0</span><span style="color:#990000;">).</span><strong><span style="color:#000000;">getValue</span></strong><span style="color:#990000;">()).</span><strong><span style="color:#000000;">start</span></strong><span style="color:#990000;">();</span>
		model<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>row<span style="color:#990000;">,</span> artist<span style="color:#990000;">,</span> artistItem<span style="color:#990000;">.</span><strong><span style="color:#000000;">getName</span></strong><span style="color:#990000;">());</span>
		model<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>row<span style="color:#990000;">,</span> playCount<span style="color:#990000;">,</span> artistItem<span style="color:#990000;">.</span><strong><span style="color:#000000;">getPlaycount</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">toString</span></strong><span style="color:#990000;">());</span>
		model<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>row<span style="color:#990000;">,</span> percent<span style="color:#990000;">,</span> Math<span style="color:#990000;">.</span><strong><span style="color:#000000;">round</span></strong><span style="color:#990000;">(</span>artistItem<span style="color:#990000;">.</span><strong><span style="color:#000000;">getPlaycount</span></strong><span style="color:#990000;">().</span><strong><span style="color:#000000;">intValue</span></strong><span style="color:#990000;">()</span> <span style="color:#990000;">/</span> maxPlayCount <span style="color:#990000;">*</span> <span style="color:#993399;">100</span><span style="color:#990000;">));</span>
	<span style="color:#ff0000;">}</span>
<span style="color:#ff0000;">}</span>
</tt></pre>
<p>Here&#8217;s the code for <code>AsyncImageLoader</code>.</p>
<pre><tt><strong><span style="color:#0000ff;">class</span></strong> <span style="color:#009900;">AsyncImageLoader</span> <strong><span style="color:#0000ff;">extends</span></strong> Thread <span style="color:#ff0000;">{</span>
	<strong><span style="color:#0000ff;">private</span></strong> ListStore model<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">private</span></strong> TreeIter row<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">private</span></strong> DataColumnPixbuf artistImage<span style="color:#990000;">;</span>
	<strong><span style="color:#0000ff;">private</span></strong> String url<span style="color:#990000;">;</span>

	<strong><span style="color:#0000ff;">public</span></strong> <strong><span style="color:#000000;">AsyncImageLoader</span></strong><span style="color:#990000;">(</span>ListStore model<span style="color:#990000;">,</span> TreeIter row<span style="color:#990000;">,</span>
			DataColumnPixbuf artistImage<span style="color:#990000;">,</span> String url<span style="color:#990000;">)</span> <span style="color:#ff0000;">{</span>
		<strong><span style="color:#0000ff;">super</span></strong><span style="color:#990000;">();</span>
		<strong><span style="color:#0000ff;">this</span></strong><span style="color:#990000;">.</span>model <span style="color:#990000;">=</span> model<span style="color:#990000;">;</span>
		<strong><span style="color:#0000ff;">this</span></strong><span style="color:#990000;">.</span>row <span style="color:#990000;">=</span> row<span style="color:#990000;">;</span>
		<strong><span style="color:#0000ff;">this</span></strong><span style="color:#990000;">.</span>artistImage <span style="color:#990000;">=</span> artistImage<span style="color:#990000;">;</span>
		<strong><span style="color:#0000ff;">this</span></strong><span style="color:#990000;">.</span>url <span style="color:#990000;">=</span> url<span style="color:#990000;">;</span>
	<span style="color:#ff0000;">}</span>

	@Override
	<strong><span style="color:#0000ff;">public</span></strong> <span style="color:#009900;">void</span> <strong><span style="color:#000000;">run</span></strong><span style="color:#990000;">()</span> <span style="color:#ff0000;">{</span>
		<strong><span style="color:#0000ff;">try</span></strong> <span style="color:#ff0000;">{</span>
			<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;">			 * Fetch the image data and set it as the image column of the</span></em>
<em><span style="color:#9a1900;">			 * specified row.</span></em>
<em><span style="color:#9a1900;">			 */</span></em>
			URL artistImageURL <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">URL</span></strong><span style="color:#990000;">(</span>url<span style="color:#990000;">);</span>
			URLConnection artistImageConnection <span style="color:#990000;">=</span> artistImageURL
					<span style="color:#990000;">.</span><strong><span style="color:#000000;">openConnection</span></strong><span style="color:#990000;">();</span>
			DataInputStream in <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">DataInputStream</span></strong><span style="color:#990000;">(</span>artistImageConnection
					<span style="color:#990000;">.</span><strong><span style="color:#000000;">getInputStream</span></strong><span style="color:#990000;">());</span>
			<span style="color:#009900;">byte</span><span style="color:#990000;">[]</span> artistImageData <span style="color:#990000;">=</span> <strong><span style="color:#0000ff;">new</span></strong> <span style="color:#009900;">byte</span><span style="color:#990000;">[</span>artistImageConnection
					<span style="color:#990000;">.</span><strong><span style="color:#000000;">getContentLength</span></strong><span style="color:#990000;">()];</span>
			in<span style="color:#990000;">.</span><strong><span style="color:#000000;">readFully</span></strong><span style="color:#990000;">(</span>artistImageData<span style="color:#990000;">);</span>
			<em><span style="color:#9a1900;">/*</span></em>
<em><span style="color:#9a1900;">			 * The image will have 32 pixels height.</span></em>
<em><span style="color:#9a1900;">			 */</span></em>
			model<span style="color:#990000;">.</span><strong><span style="color:#000000;">setValue</span></strong><span style="color:#990000;">(</span>row<span style="color:#990000;">,</span> artistImage<span style="color:#990000;">,</span> <strong><span style="color:#0000ff;">new</span></strong> <strong><span style="color:#000000;">Pixbuf</span></strong><span style="color:#990000;">(</span>artistImageData<span style="color:#990000;">,</span> <span style="color:#993399;">-1</span><span style="color:#990000;">,</span>
					<span style="color:#993399;">32</span><span style="color:#990000;">,</span> <strong><span style="color:#0000ff;">true</span></strong><span style="color:#990000;">));</span>
		<span style="color:#ff0000;">}</span> <strong><span style="color:#0000ff;">catch</span></strong> <span style="color:#990000;">(</span>IOException e<span style="color:#990000;">)</span> <span style="color:#ff0000;">{</span>
			e<span style="color:#990000;">.</span><strong><span style="color:#000000;">printStackTrace</span></strong><span style="color:#990000;">();</span>
		<span style="color:#ff0000;">}</span>
	<span style="color:#ff0000;">}</span>
<span style="color:#ff0000;">}</span>
</tt></pre>
<p>Here&#8217;s a screenshot of the running application.</p>
<p><img class="alignleft size-full wp-image-32" title="TopArtists" src="http://skaba.files.wordpress.com/2009/07/topartists1.png?w=780" alt="TopArtists"   /></p>
<div id="_mcePaste" style="overflow:hidden;position:absolute;left:-10000px;top:3420px;width:1px;height:1px;">The image will have 32 pixels height.</div>
<br />Posted in gnome, java, java-gnome, jax-rs, linux, rest, tutorial, web service, xml, xml schema, xsd  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/24/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=24&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/07/26/writing-a-last-fm-rest-client-with-jersey-and-java-gnome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>

		<media:content url="http://skaba.files.wordpress.com/2009/07/topartists1.png" medium="image">
			<media:title type="html">TopArtists</media:title>
		</media:content>
	</item>
		<item>
		<title>Introducing spellchecking support for TextView widget in Java-gnome</title>
		<link>http://skaba.wordpress.com/2009/06/08/introducing-spellchecking-support-for-textview-widget-in-java-gnome/</link>
		<comments>http://skaba.wordpress.com/2009/06/08/introducing-spellchecking-support-for-textview-widget-in-java-gnome/#comments</comments>
		<pubDate>Mon, 08 Jun 2009 18:05:05 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=21</guid>
		<description><![CDATA[I was working on spellcheckers in Linux for quite a long time. My interest comes from another project that I&#8217;m involved in,  Zemberek, a Turkish NLP library which also includes a spellchecker. For Linux part, I was involved in developing its DBus interface as well as porting Enchant plugin to this new interface. I&#8217;m also [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=21&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I was working on spellcheckers in Linux for quite a long time. My interest comes from another project that I&#8217;m involved in,  <a href="http://zemberek.googlecode.com" target="_blank">Zemberek</a>, a Turkish NLP library which also includes a spellchecker. For Linux part, I was involved in developing its DBus interface as well as porting <a href="http://www.abisource.com/enchant/" target="_blank">Enchant</a> plugin to this new interface. I&#8217;m also maintaining Gentoo ebuilds for Zemberek packages and helping with Enchant package.</p>
<p>As a result, I gained experience with spellcheckers. At first, I started investigating <a href="http://gtkspell.sourceforge.net/" target="_blank">GtkSpell</a> to add bindings for Java, but I was unable to created usable .defs file from the headers. And after investigating Python bindings and seeing that it was hand-written, I examined another possibility, <a href="http://www.chipx86.com/w/index.php/Libsexy" target="_blank">LibSexy</a>. I started implementing LibSexy Java bindings which is still not complete. And main motivation was SexySpellEntry included in the library. I unfortunately hit a <a href="http://bugzilla.gnome.org/show_bug.cgi?id=559982" target="_blank">bug</a> with text segmentation with it along with another bug causing a critical error (which ends up in an unchecked Exception in Java) which occurs in GtkSpell as well. (See Gentoo bugs <a href="http://bugs.gentoo.org/show_bug.cgi?id=270179" target="_blank">#270179</a> and <a href="http://bugs.gentoo.org/show_bug.cgi?id=270177" target="_blank">#270177</a>) Anyway, later on Andrew helped to start-up the GtkSpell coverage with hand-crafted .defs file.</p>
<p>After a few weeks of development spelling branch is now merged to mainline which will make its way into 4.0.12 release. During the development I discovered that GtkSpell has a fallback mechanism for language of the spellchecker. The order is</p>
<ul>
<li><code>lang</code> peremeter passed to functions</li>
<li><code>LANG</code> environment variable</li>
<li>English if none of the above is set.</li>
</ul>
<br />Posted in gnome, java, java-gnome, linux  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/21/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=21&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/06/08/introducing-spellchecking-support-for-textview-widget-in-java-gnome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Announcing Libnotify Java bindings</title>
		<link>http://skaba.wordpress.com/2009/06/02/announcing-libnotify-java-bindings/</link>
		<comments>http://skaba.wordpress.com/2009/06/02/announcing-libnotify-java-bindings/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 17:23:36 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[libnotify]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=18</guid>
		<description><![CDATA[After 2 ½ months of work libnotify branch finally made its way to mainline. It&#8217;s my biggest contribution to Java-Gnome project. Again thanks to Andrew, Guillaume and Vrexio for their help and aid in the development and the testing. It will close a more than 3 year old ticket reported to Galago Project. Bleeding-edge testers [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=18&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>After 2 ½ months of work libnotify branch finally made its way to mainline. It&#8217;s my biggest contribution to Java-Gnome project. Again thanks to Andrew, Guillaume and Vrexio for their help and aid in the development and the testing. It will close a more than 3 year old <a href="http://trac.galago-project.org/ticket/35" target="_blank">ticket</a> reported to Galago Project.</p>
<p>Bleeding-edge testers may grab the <a href="http://research.operationaldynamics.com/bzr/java-gnome/mainline/" target="_blank">mainline branch</a> and others may wait until next version (4.0.12) is released.</p>
<br />Posted in gnome, java, java-gnome, libnotify, linux  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/18/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=18&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/06/02/announcing-libnotify-java-bindings/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Intltool: A story on how a bug in one piece of software can kill all the others</title>
		<link>http://skaba.wordpress.com/2009/05/20/intltool-a-story-on-how-a-bug-in-one-pie/</link>
		<comments>http://skaba.wordpress.com/2009/05/20/intltool-a-story-on-how-a-bug-in-one-pie/#comments</comments>
		<pubDate>Thu, 07 May 2009 06:44:59 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[Gentoo]]></category>
		<category><![CDATA[gnome]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/2009/05/20/intltool-a-story-on-how-a-bug-in-one-pie</guid>
		<description><![CDATA[0.40.6 version of intltool has a nasty bug in handling of LINGUAS variable. It causes localization (i.e .mo files) not to be built if your LINGUAS environment variable is set (I have it set to &#8220;tr&#8221;). At first, the issue popped up in GNOME packages (nautilus, seahorse and probably quite more that was fixed before [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=68&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>0.40.6 version of intltool has a nasty <a href="http://bugzilla.gnome.org/show_bug.cgi?id=577133">bug</a> in handling of LINGUAS variable. It causes localization (i.e .mo files) not to be built if your LINGUAS environment variable is set (I have it set to &#8220;tr&#8221;). At first, the issue popped up in GNOME packages (<a href="https://bugs.gentoo.org/show_bug.cgi?id=265012">nautilus</a>, seahorse and probably quite more that was fixed before I noticed) And now it started hitting other applications with tarballs generated using broken intltool. I first noticed it in <a href="https://bugs.gentoo.org/show_bug.cgi?id=266821">Liferea</a>, and then came <a href="https://bugs.gentoo.org/show_bug.cgi?id=268810">Geany</a>.</p>
<p>So users, upstream developers and downstream maintainers; if you notice or you&#8217;re reported of a package that appears untranslated even though the package has translations (langcode.po) please report it (for users), fix your tarball for the next release (upstream), fix your package (downstream)</p>
<br />Posted in Gentoo, gnome  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=68&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/05/20/intltool-a-story-on-how-a-bug-in-one-pie/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Libnotify Java bindings &#8211; Adding actions</title>
		<link>http://skaba.wordpress.com/2009/05/16/libnotify-java-bindings-adding-actions/</link>
		<comments>http://skaba.wordpress.com/2009/05/16/libnotify-java-bindings-adding-actions/#comments</comments>
		<pubDate>Sat, 16 May 2009 13:44:11 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[libnotify]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=16</guid>
		<description><![CDATA[Java-Gnome bindings doesn&#8217;t support callbacks at the moment. It can generate code for signals only. To add action callbacks, I reimplemented it as action signal. Here&#8217;s an example code to show how to add signals: notification.addAction("a", "Action 1.a", new Notification.Action() { public void onAction(Notification source, String action) { System.out.println("1.a"); } }); The implementation currently has [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=16&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Java-Gnome bindings doesn&#8217;t support callbacks at the moment. It can generate code for signals only. To add action callbacks, I reimplemented it as <strong>action</strong> signal. Here&#8217;s an example code to show how to add signals:</p>
<pre><tt>notification<span style="color:#990000;">.</span><strong><span style="color:#000000;">addAction</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"a"</span><span style="color:#990000;">,</span> <span style="color:#ff0000;">"Action 1.a"</span><span style="color:#990000;">,</span> <strong><span style="color:#0000ff;">new</span></strong> Notification<span style="color:#990000;">.</span><strong><span style="color:#000000;">Action</span></strong><span style="color:#990000;">()</span> <span style="color:#ff0000;">{</span>

    <strong><span style="color:#0000ff;">public</span></strong> <span style="color:#009900;">void</span> <strong><span style="color:#000000;">onAction</span></strong><span style="color:#990000;">(</span>Notification source<span style="color:#990000;">,</span> String action<span style="color:#990000;">)</span> <span style="color:#ff0000;">{</span>
        System<span style="color:#990000;">.</span>out<span style="color:#990000;">.</span><strong><span style="color:#000000;">println</span></strong><span style="color:#990000;">(</span><span style="color:#ff0000;">"1.a"</span><span style="color:#990000;">);</span>
    <span style="color:#ff0000;">}</span>

<span style="color:#ff0000;">}</span><span style="color:#990000;">);</span></tt></pre>
<p>The implementation currently has one drawback. Signals are not disconnected properly. This causes two issues. One, signals aren&#8217;t disconnected if actions are removed with <em>clearActions()</em>. Two, if actions with same actionIDs are added signals for all are triggered. Andrew will be adding support for signal disconnection to java-gnome and I&#8217;ll be using it in libnotify branch.</p>
<br />Posted in gnome, java, java-gnome, libnotify, linux  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/16/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=16&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/05/16/libnotify-java-bindings-adding-actions/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>
	</item>
		<item>
		<title>Bringing Libnotify to Java</title>
		<link>http://skaba.wordpress.com/2009/05/05/bringing-libnotify-to-java/</link>
		<comments>http://skaba.wordpress.com/2009/05/05/bringing-libnotify-to-java/#comments</comments>
		<pubDate>Tue, 05 May 2009 15:28:58 +0000</pubDate>
		<dc:creator>Serkan Kaba</dc:creator>
				<category><![CDATA[gnome]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java-gnome]]></category>
		<category><![CDATA[libnotify]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://skaba.wordpress.com/?p=4</guid>
		<description><![CDATA[I&#8217;ve been contributing to java-gnome for sometime. It was generally build system and test improvements with little bits of coverage addition that was merged to mainline for now. Although I began libnotify branch later than other two (libsexy and vte) the branch improved way faster than the others. The Bazaar branch has nearly full coverage [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=4&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been contributing to <a href="http://java-gnome.sourceforge.net/" target="_blank">java-gnome</a> for sometime. It was generally build system and test improvements with little bits of coverage addition that was merged to mainline for now. Although I began <a href="http://research.operationaldynamics.com/bzr/java-gnome/hackers/serkan/libnotify/" target="_blank">libnotify branch</a> later than other two (libsexy and vte) the branch improved way faster than the others. The Bazaar branch has nearly full coverage of the underlying API.</p>
<p>The example included shows a critical low-battery warning with gnome-power-manager icon sitting in the notification area (Assuming you have it installed).</p>
<p><img class="size-full wp-image-5 alignnone" title="low-battery" src="http://skaba.files.wordpress.com/2009/05/low-battery.png?w=780" alt="low-battery"   /></p>
<p>I&#8217;ll be implementing the missing action covarage now and try to make it to our next release 4.0.12. And of course thanks goes to our lead <a href="http://www.operationaldynamics.com/about/staff/andrew/" target="_blank">Andrew Cowie</a> for his help in development and <a href="http://respawner.fr/" target="_blank">Guillaume Mazoyer</a> for testing it and providing feedback.</p>
<br />Posted in gnome, java, java-gnome, libnotify, linux  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/skaba.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/skaba.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/skaba.wordpress.com/4/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skaba.wordpress.com&amp;blog=7611709&amp;post=4&amp;subd=skaba&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://skaba.wordpress.com/2009/05/05/bringing-libnotify-to-java/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/b7de211c5763ac406b8ce1d7b93f8eb8?s=96&#38;d=&#38;r=G" medium="image">
			<media:title type="html">Serkan Kaba</media:title>
		</media:content>

		<media:content url="http://skaba.files.wordpress.com/2009/05/low-battery.png" medium="image">
			<media:title type="html">low-battery</media:title>
		</media:content>
	</item>
	</channel>
</rss>
