<?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:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd"
	xmlns:media="http://search.yahoo.com/mrss/"
>

<channel>
	<title>blog.stringtree.org &#187; General</title>
	<atom:link href="http://blog.stringtree.org/category/gneral/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.stringtree.org</link>
	<description>Stringtree Development News</description>
	<lastBuildDate>Wed, 01 Oct 2008 14:21:54 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<!-- podcast_generator="podPress/8.8" - maintenance_release="8.8.3" -->
		<copyright>Copyright &#xA9; 2010 blog.stringtree.org </copyright>
		<managingEditor>blog@stringtree.org (Frank Carver)</managingEditor>
		<webMaster>blog@stringtree.org (Frank Carver)</webMaster>
		<category>posts</category>
		<ttl>1440</ttl>
<br />
<b>Warning</b>:  htmlentities() expects at most 3 parameters, 4 given in <b>/home/string4/public_html/blog/wp-content/plugins/podpress/podpress_feed_functions.php</b> on line <b>31</b><br />
		<itunes:keywords></itunes:keywords>
<br />
<b>Warning</b>:  htmlentities() expects at most 3 parameters, 4 given in <b>/home/string4/public_html/blog/wp-content/plugins/podpress/podpress_feed_functions.php</b> on line <b>31</b><br />
		<itunes:subtitle></itunes:subtitle>
<br />
<b>Warning</b>:  htmlentities() expects at most 3 parameters, 4 given in <b>/home/string4/public_html/blog/wp-content/plugins/podpress/podpress_feed_functions.php</b> on line <b>31</b><br />
		<itunes:summary></itunes:summary>
		<itunes:author>Frank Carver</itunes:author>
		<itunes:category text="Technology">
	<itunes:category text="Software How-To"/>
</itunes:category>
		<itunes:owner>
			<itunes:name>Frank Carver</itunes:name>
			<itunes:email>blog@stringtree.org</itunes:email>
		</itunes:owner>
		<itunes:block>No</itunes:block>
		<itunes:explicit>no</itunes:explicit>
		<itunes:image href="http://stringtree.org/images/lawnchair-300.jpg" />
		<image>
			<url>http://stringtree.org/images/lawnchair-144.jpg</url>
			<title>blog.stringtree.org</title>
			<link>http://blog.stringtree.org</link>
			<width>144</width>
			<height>144</height>
		</image>
		<item>
		<title>Merging of Blogs</title>
		<link>http://blog.stringtree.org/2008/10/01/merging-of-blogs/</link>
		<comments>http://blog.stringtree.org/2008/10/01/merging-of-blogs/#comments</comments>
		<pubDate>Wed, 01 Oct 2008 14:06:21 +0000</pubDate>
		<dc:creator>Stringtree</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Site News]]></category>
		<category><![CDATA[blog]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=29</guid>
		<description><![CDATA[A few months ago I started a new blog as somewhere to record general links and discussion of wider software development and other issues. As time has progressed, that blog has become very busy and a virtual centre for my blogging activity, leaving little time to manage this one. I have tried to run both [...]]]></description>
			<content:encoded><![CDATA[<p>A few months ago I started <a href="http://blog.punchbarrel.com/">a new blog</a> as somewhere to record general links and discussion of wider software development and other issues. As time has progressed, that blog has become very busy and a virtual centre for my blogging activity, leaving little time to manage this one. I have tried to run both this Stringtree development blog and the new one in parallel. This has proved problematic when posts are potentially appropriate to both. </p>
<p>For the last month or so I have tried the approach of automatically cross-posting Stringtree articles on both blogs, but this has resulted in some confusion and a potential splitting of comments. I no longer feel that this is a valid way to progress. </p>
<p>My plan, therefore is to &#8220;deprecate&#8221; this blog, and post all future Stringtree updates only on <a href="http://blog.punchbarrel.com/">blog.punchbarrel.com</a>. I would naturally hope that some of the other posts might also be of interest, but if you only wish to see Stringtree-related posts, you may view <a href="http://blog.punchbarrel.com/category/stringtree/">just that category</a>.</p>
<p>At some point over the next few months I will ensure than all the existing posts from this blog are transferred to the new one, and disable comments etc. here. If you have subscribed to this blog using a feed reader or feed-converter, please update your subscription to http://blog.punchbarrel.com/feed/</p>
<p>I think the effort will be worth it. There are some exciting things planned for Stringtree software over the next year!</p>
<p>Thanks,<br />
Frank.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2008/10/01/merging-of-blogs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Java 6 breaks JDBC</title>
		<link>http://blog.stringtree.org/2008/09/23/java-6-breaks-jdbc/</link>
		<comments>http://blog.stringtree.org/2008/09/23/java-6-breaks-jdbc/#comments</comments>
		<pubDate>Tue, 23 Sep 2008 10:36:40 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[compatibility]]></category>
		<category><![CDATA[interface]]></category>
		<category><![CDATA[Java 1.4]]></category>
		<category><![CDATA[Java 5]]></category>
		<category><![CDATA[Java 6]]></category>
		<category><![CDATA[JDBC]]></category>
		<category><![CDATA[Wrapper]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=27</guid>
		<description><![CDATA[I&#8217;m cross. Very cross. Cross with Sun for releasing a new version of Java which shatters both backward- and forward- compatibility. Cross enough that I cannot see any sensible way of moving my software to Java 6 in the near future.
It all started with an innocuous question in a comment on my Punchbarrel blog. I [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m cross. <strong>Very</strong> cross. Cross with Sun for releasing a new version of Java which <em>shatters</em> both backward- <em>and</em> forward- compatibility. Cross enough that I cannot see any sensible way of moving my software to Java 6 in the near future.</p>
<p>It all started with an innocuous question in a <a href="http://blog.punchbarrel.com/2008/09/21/is-it-time-for-java-5/#comment-196">comment on my Punchbarrel blog</a>. I had posted asking for opinions on a move to Java 5, potentially abandoning Java 1.4, for the core Stringtree codebase. The question in the comment was about skipping Java 5 and moving directly to Java 6. This would normally be too big a leap, but I replied that I would endeavour to continue my policy of ensuring my code works with as wide a range of Java versions as possible.</p>
<p>Then I actually tried to do it, and that&#8217;s what made me cross. The more I attempted to produce code which would compile and run on Java 1.4, Java 5 and Java 6, the more impossible it began to seem.</p>
<p>I was already aware of the first hurdle. Sun have <a href="http://weblogs.java.net/blog/lancea/archive/2006/02/jdbc_40_wrapper.html">added new methods to a lot of key JDBC interfaces</a> by tagging them with the new <a href="http://java.sun.com/javase/6/docs/api/java/sql/Wrapper.html">javax.sql.Wrapper</a> interface. This is actually relatively easy to fix in a compatible way. Just add two new methods to each class which implements one of the affected JDBC interfaces:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p27code2'); return false;">View Code</a> JAVA</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p272"><td class="code" id="p27code2"><pre class="java" style="font-family:monospace;">    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">boolean</span> isWrapperFor<span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">Class</span> clz<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">return</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #003399;">Object</span> unwrap<span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">Class</span> clz<span style="color: #009900;">&#41;</span> <span style="color: #000000; font-weight: bold;">throws</span> <span style="color: #003399;">SQLException</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">throw</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">SQLException</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Not a Wrapper for &quot;</span> <span style="color: #339933;">+</span> clz<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>The actual method signatures in the Java 6 Wrapper interface are phrased in terms of Generics, but the above stripped version compiles fine using Java 1.4, Java 5 and Java 6 compiler and libraries.</p>
<p>However, even after adding these arguably pointless methods to all my concrete implementations of affected JDBC interfaces, I still had a bunch of compilation errors when using Java 6 libraries. And this is where Sun have really screwed up.</p>
<p>Several other key JDBC interfaces have also been extended. But this time it has not been done by anything as simple as tagging with a new interface. These interfaces have all gained extra method themselves. This should not be a deal-breaker. It should be feasible to just add implementations of these methods to the existing Java 1.4-compatible code. After all, any class is free to define any methods it likes, not just those from an interface.</p>
<p><strong>Nope.</strong></p>
<p>It is simply impossible to add these new methods to a class and have that class still compile in a Java 1.4 or Java 5 environment. </p>
<p>The reason is that these methods are themselves defined in terms of classes and interfaces which do not exist in earlier Java versions. For example, the <a href="http://java.sun.com/javase/6/docs/api/java/sql/Connection.html">java.sql.Connection interface</a> gains methods referring to new interfaces <a href="http://java.sun.com/javase/6/docs/api/java/sql/NClob.html">NClob</a> and <a href="http://java.sun.com/javase/6/docs/api/java/sql/SQLXML.html">SQLXML</a></p>
<p>There is no answer to this. Sun have broken backward and forward compatibility of JDBC in Java 6. It is no longer possible to write an implementation of several key JDBC interfaces in a way which compiles under all the most popular Java versions.</p>
<p>Once again, Sun completely misunderstands the real world. Not everyone is free to upgrade every deployment to the very latest Java version immediately it is released. Even within those who do manage to update all their machines in one go, not everyone can immediately drop real work to spend time messing with old code <strong>which should still work</strong> to bring it into line with a new fashion.</p>
<p>As I wrote at the start of this rant. I&#8217;m cross.  </p>
<p>Grrr.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2008/09/23/java-6-breaks-jdbc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Is it time for Java 5?</title>
		<link>http://blog.stringtree.org/2008/09/20/is-it-time-for-java-5/</link>
		<comments>http://blog.stringtree.org/2008/09/20/is-it-time-for-java-5/#comments</comments>
		<pubDate>Sat, 20 Sep 2008 19:59:00 +0000</pubDate>
		<dc:creator>Stringtree</dc:creator>
				<category><![CDATA[Friki]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[HTTPClient]]></category>
		<category><![CDATA[Inkling]]></category>
		<category><![CDATA[JSON]]></category>
		<category><![CDATA[Mojasef]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[Templater]]></category>
		<category><![CDATA[autoboxing]]></category>
		<category><![CDATA[enum]]></category>
		<category><![CDATA[generics]]></category>
		<category><![CDATA[iterable]]></category>
		<category><![CDATA[Java 1.4]]></category>
		<category><![CDATA[Java 5]]></category>
		<category><![CDATA[varargs]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=25</guid>
		<description><![CDATA[A major goal of the Stringtree software project has always been to be as compatible as possible with all the software people are using for their Java development. Naturally that also includes whatever Java version is being used.
For a long time I interpreted this goal as implying that all Stringtree code should run on all [...]]]></description>
			<content:encoded><![CDATA[<p>A major goal of the Stringtree software project has always been to be as compatible as possible with all the software people are using for their Java development. Naturally that also includes whatever Java version is being used.</p>
<p>For a long time I interpreted this goal as implying that all Stringtree code should run on all Java versions from Java 1.2 onwards. Java 1.4, however, introduced some compelling new features including built-in regular-expression handling. For a few years I still tried to ensure that most code was still 1.2-compatible (for example by using Ant to swap in a third-party regular-expression library while building a jar file), while also providing a Java 1.4 version. Eventually, use of Java versions prior to 1.4 declined enough that I felt comfortable removing the complicated pre-1.4 version.</p>
<p>For the last few years I have been very careful to keep all my Stringtree code compatible with all versions of Java from 1.4 upwards. Now, however, the pressure is building again to move over to Java 5. In my day-to-day coding I develop with Java 5 and make increasing use of Java 5 features such as the enhanced for loop, the Iterable interface, enums, generics, autoboxing, varargs and so on. It would be very nice to be able to update the Stringtree codebase to use these features too.</p>
<p>Occasionally a Java 5-specific detail has crept in to a Stringtree library, and I have soon received comments or emails pointing this out. I haven&#8217;t noticed this for a while, which might indicate either that I have been especially careful, or that I there are no longer any/many people developing with Stringtree code who are still limited to Java 1.4.</p>
<p>If you are reading this and you still require Java 1.4 support, please let me know. Likewise, if you have thrown off the shackles of 1.4 within the last year or so or are desperately hoping for a Java 5 Stringtree that would be good to know too.</p>
<p>Is it time for Java 5 yet?</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2008/09/20/is-it-time-for-java-5/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stringtree Maven Repository</title>
		<link>http://blog.stringtree.org/2008/01/07/stringtree-maven-repository/</link>
		<comments>http://blog.stringtree.org/2008/01/07/stringtree-maven-repository/#comments</comments>
		<pubDate>Mon, 07 Jan 2008 11:48:12 +0000</pubDate>
		<dc:creator>Stringtree</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=21</guid>
		<description><![CDATA[I have experimented with Maven a few times, but never been particularly impressed. 
Recently, however, one of my users has been bugging me to make the Stringtree and Mojasef classes and sources available in a Maven-style repository, for easier integration with Maven (or Maven-like) build tools and workflows. So I have done it. The current [...]]]></description>
			<content:encoded><![CDATA[<p>I have experimented with <a href="http://maven.apache.org/">Maven</a> a few times, but never been particularly impressed. </p>
<p>Recently, however, <a href="http://www.realsolve.co.uk/site/home.php">one of my users</a> has been bugging me to make the Stringtree and Mojasef classes and sources available in a Maven-style repository, for easier integration with Maven (or Maven-like) build tools and workflows. So I have done it. The current versions of key Stringtree and Mojasef files are now available from the <a href="http://stringtree.org/repository/">Stringtree repository</a> at the following URLs:</p>
<ul>
<li><a href="http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-2.0.10-sources.jar">http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-2.0.10-sources.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-2.0.10.jar">http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-2.0.10.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-httpclient-2.0.10.jar">http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-httpclient-2.0.10.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-json-2.0.10.jar">http://stringtree.org/repository/org/stringtree/stringtree/2.0.10/stringtree-json-2.0.10.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-sources.jar">http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-sources.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-withdependencies-sources.jar">http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-withdependencies-sources.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-withdependencies.jar">http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1-withdependencies.jar</a></li>
<li><a href="http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1.jar">http://stringtree.org/repository/org/stringtree/mojasef/2.0.b1/mojasef-2.0.b1.jar</a></li>
</ul>
<p>The Stringtree and Mojasef build scripts now include a &#8220;publish&#8221; target which uploads such artefacts to appropriate places in the repository, so future versions should continue to be available.</p>
<p>This is the first time I have done this, so I would welcome comments from any readers who actually use Maven (or buildr, or anything else which supports this repository format). In particular, I am interested in opinions on whether it is OK to simply replace artefacts with the same names and locations for minor tweaks and bug-fixes, or whether even the smallest change should result in the generation and upload of a new version with a new name and location.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2008/01/07/stringtree-maven-repository/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Stringtree 2.0.9</title>
		<link>http://blog.stringtree.org/2007/07/20/stringtree-209/</link>
		<comments>http://blog.stringtree.org/2007/07/20/stringtree-209/#comments</comments>
		<pubDate>Fri, 20 Jul 2007 11:12:08 +0000</pubDate>
		<dc:creator>Stringtree</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=17</guid>
		<description><![CDATA[It&#8217;s been a month or so, so it&#8217;s time for another release of Stringtree. Changes in this release include:

fixed some broken EasyTemplater constructors
added switchable prefixing of attributes in XMLReader
added switchable forcing all values to lists in XMLReader
added storing cdata from mixed elements as &#8220;text()&#8221; in XMLReader
added extra &#8220;read&#8221; methods to JSONReader to allow calling with [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a month or so, so it&#8217;s time for another release of Stringtree. Changes in this release include:</p>
<ul>
<li>fixed some broken EasyTemplater constructors</li>
<li>added switchable prefixing of attributes in XMLReader</li>
<li>added switchable forcing all values to lists in XMLReader</li>
<li>added storing cdata from mixed elements as &#8220;text()&#8221; in XMLReader</li>
<li>added extra &#8220;read&#8221; methods to JSONReader to allow calling with a CharacterIterator</li>
<li>XMLReader now skips a DOCTYPE without complaining.</li>
<li>tests.Hierarchy renamed to tests.tree</li>
<li>small tidyup of object creation to allow reference to context items instead of full class+parameter specifications</li>
<li>support a naive view of namespaces in XML parser, include colonprefix in the name</li>
<li>some slight improvements to class creation stuff in util to better deal with multiple calls to &#8220;init&#8221;.</li>
<li>added a GUID generator for use in REST-style applications</li>
</ul>
<p><a href='http://sourceforge.net/project/showfiles.php?group_id=80689&#038;package_id=82458&#038;release_id=524466'>Download available from Sourceforge as usual</a> </p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2007/07/20/stringtree-209/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Read JSON from a CharacterIterator</title>
		<link>http://blog.stringtree.org/2007/07/05/read-json-from-a-characteriterator/</link>
		<comments>http://blog.stringtree.org/2007/07/05/read-json-from-a-characteriterator/#comments</comments>
		<pubDate>Thu, 05 Jul 2007 22:52:32 +0000</pubDate>
		<dc:creator>Stringtree</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[JSON]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://blog.stringtree.org/?p=15</guid>
		<description><![CDATA[I just had a pleasant email exchange with someone who is interested in embedding Stringtree JSON in another project. In this particular case, the basic functionality of the JSONReader is fine, but the calling API was not quite aligned with what they need.
So now, as well as reading JSON from a String, you now have [...]]]></description>
			<content:encoded><![CDATA[<p>I just had a pleasant email exchange with <a href="http://www.mail-archive.com/dev@tomcat.apache.org/msg17996.html">someone</a> who is interested in embedding Stringtree JSON in another project. In this particular case, the basic functionality of the JSONReader is fine, but the calling API was not quite aligned with what they need.</p>
<p>So now, as well as reading JSON from a String, you now have the ability to read JSON from a CharacterIterator. This was a neat changes, as Stringtree JSONReader uses a CharacterIterator internally anyway, so the extra method actually does a bit <i>less</i> than the original one.</p>
<p>For &#8220;power users&#8221;, there is actually an extra method. When JSONReader starts reading from a CharacterIterator it&#8217;s not entirely clear whether it should get its first character by calling <tt>current()</tt> to get a character already read once, or by calling <tt>next()</tt> to get the next unread character, or by calling <tt>first()</tt> to get the first character of the sequence. With this in mind I have provided a <b><tt>read(CharacterIterator ci, int start)</tt></b>, where start can be <tt>JSONReader.START</tt>, <tt>JSONReader.NEXT</tt>, or <tt>JSONReader.CURRENT</tt>.</p>
<p>This update is available in sourceforge subversion, and will be included in the next release of Stringtree and Stringtree JSON.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.stringtree.org/2007/07/05/read-json-from-a-characteriterator/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
