<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>No One Is Perfect</title>
	<atom:link href="http://watchitlater.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://watchitlater.com/blog</link>
	<description>A reluctant foray into the world of blogging.</description>
	<lastBuildDate>Tue, 31 Aug 2010 13:07:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>PostgreSQL &amp; Python on Mac</title>
		<link>http://watchitlater.com/blog/2010/08/postgresql-python-on-mac/</link>
		<comments>http://watchitlater.com/blog/2010/08/postgresql-python-on-mac/#comments</comments>
		<pubDate>Tue, 31 Aug 2010 13:07:41 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[Reminders]]></category>
		<category><![CDATA[postgres]]></category>
		<category><![CDATA[psycopg2]]></category>
		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=224</guid>
		<description><![CDATA[I&#8217;ve been playing with Django &#038; MySQL for a while but for my next project I wanted to integrate it with a PostgreSQL database. Everything went well until I wanted to install Psycopg as my python adapter to PostgreSQL.
After a bit of blundering about here&#8217;s what it eventually took:

Download and install PostgreSQL one-click installer from [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been playing with Django &#038; MySQL for a while but for my next project I wanted to integrate it with a PostgreSQL database. Everything went well until I wanted to install <a href="http://initd.org/psycopg/">Psycopg</a> as my python adapter to PostgreSQL.</p>
<p>After a bit of blundering about here&#8217;s what it eventually took:</p>
<ul>
<li>Download and install PostgreSQL one-click installer from <a href="http://www.postgresql.org/download/macosx">http://www.postgresql.org/download/macosx</a>. Remember to read the README file before actually running the installer.</li>
<li>Download the psycopg2 source from <a href="http://initd.org/pub/software/psycopg/">http://initd.org/pub/software/psycopg/</a>.</li>
<li>Edit the setup.cfg file to provide a path to the pg_config executable. On my Mac it sits in <code>/Library/PostgreSQL/8.4/bin/pg_config</code> and is not by default on the PATH so if you don&#8217;t put it on the PATH or in this configuration file the next step will fail in a spectacular manner.</li>
<li>Run &#8216;<code>sudo easy_install .</code>&#8216; in the top level psycopg2 source directory.</li>
<li>Specify <code>postgresql_psycopg2</code> when you configure Django&#8217;s database layer for your project.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2010/08/postgresql-python-on-mac/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Manipulating collections with lambdaj</title>
		<link>http://watchitlater.com/blog/2010/06/manipulating-collections-with-lambdaj/</link>
		<comments>http://watchitlater.com/blog/2010/06/manipulating-collections-with-lambdaj/#comments</comments>
		<pubDate>Sun, 13 Jun 2010 03:23:14 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[functional]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=212</guid>
		<description><![CDATA[My day-to-day work often consists of writing web applications that aggregate data from a number of sources. Corporate constraints frequently dictate that I cannot use languages that make crunching of collections easier so I am forced into an old-fashioned for-loop frenzy. Ugh.
On a recent java project my pairing buddy (Jules &#8211; thank you) suggested that [...]]]></description>
			<content:encoded><![CDATA[<p>My day-to-day work often consists of writing web applications that aggregate data from a number of sources. Corporate constraints frequently dictate that I cannot use languages that make crunching of collections easier so I am forced into an old-fashioned for-loop frenzy. Ugh.</p>
<p>On a recent java project my pairing buddy (Jules &#8211; thank you) suggested that we look at <a href="http://code.google.com/p/lambdaj/">lambdaj</a>. From the lamdbaj site: &#8220;lambdaj is a library that makes easier to address this issue by allowing to manipulate collections in a pseudo-functional and statically typed way&#8221;. The following examples are very contrived but I&#8217;m sure you&#8217;ve seen something like them:</p>
<p>Old school:</p>
<pre name="code" class="java:nogutter">
List&lt;Customer&gt; activeCustomers = new ArrayList&lt;Customer&gt;();
for (Customer customer : customers) {
  if (customer.isActive()) {
    activeCusomers.add(customer);
  }
}
List&lt;Account&gt; accounts = new ArrayList&lt;Account&gt;();
for (Customer customer : activeCustomers) {
  accounts.addAll(customer.getAccounts());
}
Map&lt;String, List&lt;Account&gt;&gt; groups = new HashMap&lt;String, List&lt;Account&gt;&gt;();
for (Account account : accounts) {
  String type = account.getType();
  List&lt;Account&gt; group = groups.get(type);
  if (group == null) {
    group = new ArrayList&lt;Account&gt;();
    groups.put(type, group);
  }
  group.add(account);
}
</pre>
<p>New hotness:</p>
<pre name="code" class="java:nogutter">
List&lt;Customer&gt; activeCustomers = select(customers, having(on(Customer.class).isActive(), equalTo(true)));
List&lt;Account&gt; accounts = flatten(extract(activeCustomers, on(Customer.class).getAccounts()));
Group&lt;Account&gt; groups = group(accounts, by(on(Account.class).getType()));
</pre>
<p>My verdict: lambdaj certainly lives up to its promises. Obviously the old-school java code will be faster but is it easier to write or more readable? You decide &#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2010/06/manipulating-collections-with-lambdaj/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Test definitions for developers</title>
		<link>http://watchitlater.com/blog/2010/03/test-definitions-for-developers/</link>
		<comments>http://watchitlater.com/blog/2010/03/test-definitions-for-developers/#comments</comments>
		<pubDate>Fri, 19 Mar 2010 03:53:02 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Soap Box]]></category>
		<category><![CDATA[Software Development]]></category>
		<category><![CDATA[acceptance]]></category>
		<category><![CDATA[definition]]></category>
		<category><![CDATA[integration]]></category>
		<category><![CDATA[testing]]></category>
		<category><![CDATA[unit]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=201</guid>
		<description><![CDATA[One of the best descriptions of the hierarchy of tests that I have seen comes from &#8220;Growing Object-Oriented Software, Guided by Tests&#8221; by Steve Freeman and Nat Price.
1. Acceptance Tests: Does the whole system work?
2. Integration Tests: Does our code work against code we can&#8217;t change?
3. Unit Tests: Do our objects do the right thing, [...]]]></description>
			<content:encoded><![CDATA[<p>One of the best descriptions of the hierarchy of tests that I have seen comes from &#8220;<a href="http://amzn.com/0321503627">Growing Object-Oriented Software, Guided by Tests</a>&#8221; by Steve Freeman and Nat Price.</p>
<p>1. <strong>Acceptance Tests</strong>: Does the whole system work?<br />
2. <strong>Integration Tests</strong>: Does our code work against code we can&#8217;t change?<br />
3. <strong>Unit Tests</strong>: Do our objects do the right thing, are they convenient to work with?</p>
<p>Can we now get on with some work, rather than discussing definitions ad nauseam?</p>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2010/03/test-definitions-for-developers/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
