<?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>OlliN&#039;s &#187; software</title>
	<atom:link href="http://www.nautsch.net/category/software/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.nautsch.net</link>
	<description>Notizen über Software und Anderes von Oliver Nautsch</description>
	<lastBuildDate>Fri, 03 Feb 2012 09:12:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>It&#8217;s never to late for git.</title>
		<link>http://www.nautsch.net/2011/12/18/its-never-to-late-for-git/</link>
		<comments>http://www.nautsch.net/2011/12/18/its-never-to-late-for-git/#comments</comments>
		<pubDate>Sun, 18 Dec 2011 11:32:57 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[FLOSS]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=637</guid>
		<description><![CDATA[<p>If not already done, every software developer must try <a href="http://git-scm.com/">GIT</a> - the fast, distributed version control system. It&#8217;s such a nice and useful tool. Once every week I find a new little nice feature.</p> <p>The last month I used the git-client together with a svn-remote repository and I will never use the svn client again. It is so handy to [...]]]></description>
			<content:encoded><![CDATA[<p>If not already done, every software developer must try <a href="http://git-scm.com/">GIT</a> - the fast, distributed version control system. It&#8217;s such a nice and useful tool. Once every week I find a new little nice feature.</p>
<p>The last month I used the git-client together with a svn-remote repository and I will never use the svn client again. It is so handy to have the full history of the repository on my notebook.  I can commit my changes every time to my local repository and merging/branching is just fun.  I&#8217;m so much faster &#8230;</p>
<p>Here my path to git</p>
<ul>
<li><a href="http://www.viget.com/extend/effectively-using-git-with-subversion/">Effectively Using Git With Subversion</a></li>
<li><a href="http://inventage.com/employees.html">Dominik</a> (a colleague which answered my first questions)</li>
<li><a href="http://pragprog.com/book/pg_git/pragmatic-guide-to-git">Pragmatic Guide to Git</a> by Travis Swicegood</li>
<li><a href="http://book.git-scm.com/">The Git Community Book</a></li>
<li>the git man pages</li>
<li>&#8230; and using it every day</li>
</ul>
<p>Here my favorite git client in action (the command line client <img src='http://www.nautsch.net/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  :</p>
<div id="attachment_638" class="wp-caption alignnone" style="width: 310px"><a href="http://www.nautsch.net/wp-content/uploads/git.command.line_.png"><img class="size-medium wp-image-638" title="git.command.line" src="http://www.nautsch.net/wp-content/uploads/git.command.line_-300x166.png" alt="" width="300" height="166" /></a><p class="wp-caption-text">git command line</p></div>
<p>There are plugins for eclise, idea, windows, mac&#8230; So give it a try and have fun!</p>
<p>And if you want to have the little nice prompt add the following lines to your .bashrc:</p>

<div class="wp_codebox"><table><tr id="p6372"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
</pre></td><td class="code" id="p637code2"><pre class="bash" style="font-family:monospace;">...
<span style="color: #666666; font-style: italic;">#-----------------------------------</span>
<span style="color: #666666; font-style: italic;"># git in prompt</span>
<span style="color: #666666; font-style: italic;">#-----------------------------------</span>
        <span style="color: #007800;">RED</span>=<span style="color: #ff0000;">&quot;\[\033[0;31m\]&quot;</span>
     <span style="color: #007800;">YELLOW</span>=<span style="color: #ff0000;">&quot;\[\033[0;33m\]&quot;</span>
      <span style="color: #007800;">GREEN</span>=<span style="color: #ff0000;">&quot;\[\033[0;32m\]&quot;</span>
       <span style="color: #007800;">BLUE</span>=<span style="color: #ff0000;">&quot;\[\033[0;34m\]&quot;</span>
  <span style="color: #007800;">LIGHT_RED</span>=<span style="color: #ff0000;">&quot;\[\033[1;31m\]&quot;</span>
<span style="color: #007800;">LIGHT_GREEN</span>=<span style="color: #ff0000;">&quot;\[\033[1;32m\]&quot;</span>
      <span style="color: #007800;">WHITE</span>=<span style="color: #ff0000;">&quot;\[\033[1;37m\]&quot;</span>
 <span style="color: #007800;">LIGHT_GRAY</span>=<span style="color: #ff0000;">&quot;\[\033[0;37m\]&quot;</span>
 <span style="color: #007800;">COLOR_NONE</span>=<span style="color: #ff0000;">&quot;\[\e[0m\]&quot;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> parse_git_branch <span style="color: #7a0874; font-weight: bold;">&#123;</span>
        <span style="color: #c20cb9; font-weight: bold;">git</span> rev-parse <span style="color: #660033;">--git-dir</span> <span style="color: #000000; font-weight: bold;">&amp;</span>amp;<span style="color: #000000; font-weight: bold;">&amp;</span>gt; <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
        <span style="color: #007800;">git_status</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">$(git status 2&amp;gt; /dev/null)</span>&quot;</span>
        <span style="color: #007800;">branch_pattern</span>=<span style="color: #ff0000;">&quot;^# On branch ([^<span style="color: #007800;">${IFS}</span>]*)&quot;</span>
        <span style="color: #007800;">remote_pattern</span>=<span style="color: #ff0000;">&quot;# Your branch is (.*) of&quot;</span>
        <span style="color: #007800;">diverge_pattern</span>=<span style="color: #ff0000;">&quot;# Your branch and (.*) have diverged&quot;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #000000; font-weight: bold;">!</span> <span style="color: #800000;">${git_status}</span> =~ <span style="color: #ff0000;">&quot;working directory clean&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #007800;">state</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${RED}</span>?&quot;</span>
        <span style="color: #000000; font-weight: bold;">else</span>
                <span style="color: #007800;">state</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${GREEN}</span>?&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
        <span style="color: #666666; font-style: italic;"># add an else if or two here if you want to get more specific</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #800000;">${git_status}</span> =~ <span style="color: #800000;">${remote_pattern}</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #800000;">${BASH_REMATCH[1]}</span> == <span style="color: #ff0000;">&quot;ahead&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
                        <span style="color: #007800;">remote</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${YELLOW}</span>?&quot;</span>
                <span style="color: #000000; font-weight: bold;">else</span>
                        <span style="color: #007800;">remote</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${YELLOW}</span>?&quot;</span>
                <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #800000;">${git_status}</span> =~ <span style="color: #800000;">${diverge_pattern}</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #007800;">remote</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${YELLOW}</span>?&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #800000;">${git_status}</span> =~ <span style="color: #800000;">${branch_pattern}</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #007800;">branch</span>=<span style="color: #800000;">${BASH_REMATCH[1]}</span>
                <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot; (<span style="color: #007800;">${branch}</span>)<span style="color: #007800;">${remote}</span><span style="color: #007800;">${state}</span>&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
<span style="color: #000000; font-weight: bold;">function</span> prompt_func<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
        <span style="color: #007800;">previous_return_value</span>=<span style="color: #007800;">$?</span>;
        <span style="color: #007800;">prompt</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${GREEN}</span><span style="color: #007800;">${USER:-$(type whoami &amp;gt;/dev/null &amp;amp;&amp;amp; whoami)}</span>@<span style="color: #007800;">$(type uname &amp;gt;/dev/null &amp;amp;&amp;amp; uname -n)</span> <span style="color: #007800;">${BLUE}</span>[\w<span style="color: #007800;">${GREEN}</span><span style="color: #007800;">$(parse_git_branch)</span><span style="color: #007800;">${BLUE}</span>]<span style="color: #007800;">${COLOR_NONE}</span> &quot;</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #007800;">$previous_return_value</span> <span style="color: #660033;">-eq</span> <span style="color: #000000;">0</span>
        <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #666666; font-style: italic;"># PS1=&quot;${prompt}? &quot;</span>
                <span style="color: #007800;">PS1</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${prompt}</span> \<span style="color: #000099; font-weight: bold;">\$</span> &quot;</span>
        <span style="color: #000000; font-weight: bold;">else</span>
                <span style="color: #666666; font-style: italic;">#PS1=&quot;${prompt}${RED}?${COLOR_NONE}&quot;</span>
                <span style="color: #007800;">PS1</span>=<span style="color: #ff0000;">&quot;<span style="color: #007800;">${prompt}</span><span style="color: #007800;">${RED}</span>\<span style="color: #000099; font-weight: bold;">\$</span> <span style="color: #007800;">${COLOR_NONE}</span>&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
<span style="color: #007800;">PROMPT_COMMAND</span>=prompt_func</pre></td></tr></table></div>

<p>I found this script at <a href="https://gist.github.com/1485616">github</a> and changed it a little bit. Thx to <a href="https://github.com/trapni">trapni</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2011/12/18/its-never-to-late-for-git/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Clean Coder</title>
		<link>http://www.nautsch.net/2011/11/08/the-clean-coder/</link>
		<comments>http://www.nautsch.net/2011/11/08/the-clean-coder/#comments</comments>
		<pubDate>Tue, 08 Nov 2011 07:56:49 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[bücher]]></category>
		<category><![CDATA[leute]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=626</guid>
		<description><![CDATA[<p>Habe gestern Abend <a href="http://www.amazon.de/Clean-Coder-Conduct-Professional-Programmers/dp/0137081073/">&#8220;The Clean Coder&#8221; von Robert C. Martin </a>(<a href="http://en.wikipedia.org/wiki/Robert_Cecil_Martin">Uncle Bob</a>) fertig gelesen. Ich wäre so froh gewesen, wenn ich dieses Buch als Berufseinsteiger gelesen hätte. Es hätte mich so manche Fettnäpfchen vermeiden lassen.</p> <p>Spannend zu lesen war seine Meinung über den &#8220;Flow&#8221;. Dieser Zustand beim Programmieren, oder Arbeiten allgemein, wo man [...]]]></description>
			<content:encoded><![CDATA[<p>Habe gestern Abend <a href="http://www.amazon.de/Clean-Coder-Conduct-Professional-Programmers/dp/0137081073/">&#8220;The Clean Coder&#8221; von Robert C. Martin </a>(<a href="http://en.wikipedia.org/wiki/Robert_Cecil_Martin">Uncle Bob</a>) fertig gelesen. Ich wäre so froh gewesen, wenn ich dieses Buch als Berufseinsteiger gelesen hätte. Es hätte mich so manche Fettnäpfchen vermeiden lassen.</p>
<p>Spannend zu lesen war seine Meinung über den &#8220;Flow&#8221;. Dieser Zustand beim Programmieren, oder Arbeiten allgemein, wo man die Zeit vergisst und einem schier alles gelingt. Uncle Bob findet diesen Zustand eher hinderlich, weil man den Blick für das Grosse verliert. Ich denke es hängt ein wenig vom Arbeitsstil ab. Ich habe immer zu Beginn mein Notizbuch vor mir liegen, wo ich den grossen Kontext aufzeichne. Manchmal komme ich dann schon in Flow während ich beim dem Design bin &#8211; also einem relativ hohen Abstraktionsniveau. Trotzdem hat mich das Buch etwas kritischer gegenüber dem Flow werden lassen.</p>
<p>Einen völlig anderen Blickwinkel auf den Flow hat z.B.  Joel Spolsky (bekannt von dem Blog &#8220;<a href="http://www.joelonsoftware.com/">Joel on Software</a>&#8220;).  Er erzählt in einem <a href="http://www.youtube.com/watch?v=NF8ZVB-v3IM">Interview</a>, wie wichtig er den Flow findet und das er die Büros sogar so gestaltet, das man sich richtig gut in die Arbeit vertiefen kann.</p>
<p>Es gibt aber in dem Buch noch sehr viele andere Perlen und Denkanstösse zu finden. Lesen!</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2011/11/08/the-clean-coder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>netbeans 7 update and the license agreement dialog</title>
		<link>http://www.nautsch.net/2011/08/09/netbeans-7-update-and-the-license-agreement-dialog/</link>
		<comments>http://www.nautsch.net/2011/08/09/netbeans-7-update-and-the-license-agreement-dialog/#comments</comments>
		<pubDate>Tue, 09 Aug 2011 12:19:56 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[netbeans]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=597</guid>
		<description><![CDATA[<p>I&#8217;ve just updated NetBeans. The following dialog appeared:</p> <p>How many people read those 85 263 lines of text carefully?</p>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just updated NetBeans. The following dialog appeared:</p>
<div id="attachment_598" class="wp-caption alignnone" style="width: 243px"><a href="http://www.nautsch.net/wp-content/uploads/netbeans70update.-license.dialog.png"><img class="size-medium wp-image-598" title="" src="http://www.nautsch.net/wp-content/uploads/netbeans70update.-license.dialog-233x300.png" alt="" width="233" height="300" /></a><p class="wp-caption-text">License Agreement Dialog</p></div>
<p>How many people read those <strong>85 263</strong> lines of text <em>carefully</em>?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2011/08/09/netbeans-7-update-and-the-license-agreement-dialog/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I&#8217;m going to FOSDEM 2011</title>
		<link>http://www.nautsch.net/2011/02/02/im-going-to-fosdem-2011/</link>
		<comments>http://www.nautsch.net/2011/02/02/im-going-to-fosdem-2011/#comments</comments>
		<pubDate>Wed, 02 Feb 2011 09:05:59 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[FLOSS]]></category>
		<category><![CDATA[reisen]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=556</guid>
		<description><![CDATA[<p><a href="http://www.fosdem.org"></a><a href="http://www.fosdem.org"></a></p>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.fosdem.org"></a><a href="http://www.fosdem.org"><img class="alignnone size-full wp-image-568" title="FOSDEM 2011" src="http://www.nautsch.net/wp-content/uploads/going-to.png" alt="I'm going to FOSDEM, the Free and Open Source Software Developers' European Meeting" width="150" height="89" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2011/02/02/im-going-to-fosdem-2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Funny Emerging Threats</title>
		<link>http://www.nautsch.net/2010/11/02/funny-emerging-threats/</link>
		<comments>http://www.nautsch.net/2010/11/02/funny-emerging-threats/#comments</comments>
		<pubDate>Tue, 02 Nov 2010 20:19:03 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[leute]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=495</guid>
		<description><![CDATA[<p> </p> <p><a href="http://www.nautsch.net/wp-content/uploads/et-forbidden.png"></a></p> <p>I hope I did not land on the black list.</p>]]></description>
			<content:encoded><![CDATA[<p> <img src='http://www.nautsch.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://www.nautsch.net/wp-content/uploads/et-forbidden.png"><img class="alignnone size-full wp-image-499" style="border: 0pt none;" title="et-forbidden" src="http://www.nautsch.net/wp-content/uploads/et-forbidden.png" alt="" width="363" height="179" /></a></p>
<p>I hope I did not land on the black list.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2010/11/02/funny-emerging-threats/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Gesetz von Demeter, Unit Tests und der zweite Programmierer</title>
		<link>http://www.nautsch.net/2009/11/21/gesetz-von-demeter-unit-tests-und-der-zweite-programmierer/</link>
		<comments>http://www.nautsch.net/2009/11/21/gesetz-von-demeter-unit-tests-und-der-zweite-programmierer/#comments</comments>
		<pubDate>Sat, 21 Nov 2009 10:43:33 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=423</guid>
		<description><![CDATA[<p>In meinem <a href="http://www.nautsch.net/2009/11/19/gesetz-von-demeter-im-alltag/">letzten Post</a> habe ich beschrieben, das Delegation für den Benutzer einer Klasse angenehm ist und das wir dies auch im realen Leben schätzen. Heute möchte ich kurz beschreiben wie sich das Einhalten des <a href="http://de.wikipedia.org/wiki/Law_of_Demeter">Gesetzes von Demeter</a> auf das Schreiben von Unit-Tests und das Benutzen meiner Implementierungen auswirkt. Dazu habe ich das [...]]]></description>
			<content:encoded><![CDATA[<p>In meinem <a href="http://www.nautsch.net/2009/11/19/gesetz-von-demeter-im-alltag/">letzten Post</a> habe ich beschrieben, das Delegation für den Benutzer einer Klasse angenehm ist und das wir dies auch im realen Leben schätzen. Heute möchte ich kurz beschreiben wie sich das Einhalten des <a href="http://de.wikipedia.org/wiki/Law_of_Demeter">Gesetzes von Demeter</a> auf das Schreiben von Unit-Tests und das Benutzen meiner Implementierungen auswirkt. Dazu habe ich das Modell um Implementierungen erweitert:</p>
<p><img class="size-full wp-image-424 alignnone" title="lod_overview_1" src="http://www.nautsch.net/wp-content/uploads/lod_overview_1.png" alt="lod overview 1" width="637" height="340" /></p>
<p><span id="more-423"></span>Am Beispiel von CityBike möchte ich erklären, dass die Implementierung der Unit-Test&#8217;s jetzt ganz einfach geht. Wir haben also die leere Implementierung der Klasse:</p>

<div class="wp_codebox"><table><tr id="p4239"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
</pre></td><td class="code" id="p423code9"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> CityBike <span style="color: #000000; font-weight: bold;">implements</span> WithBasket <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Basket basket<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> CityBike<span style="color: #009900;">&#40;</span>Basket basket<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> addElement <span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aelement+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Element</span></a> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> Basket getBasket <span style="color: #009900;">&#40;</span><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;">null</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Alle Implementierungen sind leer, da wir ja im Sinne von <a href="http://de.wikipedia.org/wiki/Testgetriebene_Entwicklung">Test-Driven Development</a> (TDD) zuerst unsere Tests schreiben und erst danach die Implementierung. Hier also die <a href="http://www.junit.org/">JUnit4</a>-Testklasse:</p>

<div class="wp_codebox"><table><tr id="p42310"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
</pre></td><td class="code" id="p423code10"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Before</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Test</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">static</span> org.<span style="color: #006633;">junit</span>.<span style="color: #000000; font-weight: bold;">Assert</span>.<span style="color: #339933;">*;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">static</span> org.<span style="color: #006633;">mockito</span>.<span style="color: #006633;">Mockito</span>.<span style="color: #339933;">*;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> CityBikeTest <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Basket basket<span style="color: #339933;">;</span>
    <span style="color: #000000; font-weight: bold;">private</span> CityBike cityBike<span style="color: #339933;">;</span>
&nbsp;
    @Before
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> setUp<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        basket <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>Basket.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        cityBike <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> CityBike<span style="color: #009900;">&#40;</span>basket<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    @Test<span style="color: #009900;">&#40;</span>expected<span style="color: #339933;">=</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aillegalargumentexception+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">IllegalArgumentException</span></a>.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span>
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> shouldNotCreateWithNullAsBasket<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">new</span> CityBike<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">null</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    @Test
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> shouldDelegateAddElementToBasket<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aelement+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Element</span></a> e1 <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aelement+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Element</span></a>.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #666666; font-style: italic;">//</span>
        cityBike.<span style="color: #006633;">addElement</span><span style="color: #009900;">&#40;</span>e1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #666666; font-style: italic;">//</span>
        verify<span style="color: #009900;">&#40;</span>basket<span style="color: #009900;">&#41;</span>.<span style="color: #006633;">add</span><span style="color: #009900;">&#40;</span>e1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    @Test
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> shouldReturnBasket<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        assertEquals<span style="color: #009900;">&#40;</span>basket, cityBike.<span style="color: #006633;">getBasket</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Alle 3 Tests melden einen Fehler. Also ändern wir die Implementierung so, dass die Tests funktionieren:</p>

<div class="wp_codebox"><table><tr id="p42311"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
</pre></td><td class="code" id="p423code11"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> CityBike <span style="color: #000000; font-weight: bold;">implements</span> WithBasket <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Basket basket<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> CityBike<span style="color: #009900;">&#40;</span>Basket basket<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">null</span> <span style="color: #339933;">==</span> basket<span style="color: #009900;">&#41;</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> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aillegalargumentexception+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">IllegalArgumentException</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;null as basket not allowed&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">basket</span> <span style="color: #339933;">=</span> basket<span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> addElement <span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aelement+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Element</span></a> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">basket</span>.<span style="color: #006633;">add</span><span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> Basket getBasket <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">return</span> <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">basket</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Alle Tests funktionieren. <img src='http://www.nautsch.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  (Die Implementierung und Tests für SimpleBasket und SimpleElement lasse ich hier im Text mal weg, damit es nicht zu unübersichtlich wird.) Damit haben wir als Programmierer von CityBike mal alles gemacht</p>
<p>Jetzt kommt ein zweiter Programmierer und möchte unsere Klassen benutzen. Es wird eine Person implementiert, die mit dem Fahrrad fahren soll. Allerdings muss dieser Fahrer seine Umhängetasche in den Korb (Basket) legen, bevor er losfahren darf. Natürlich sollte auch der zweite Programmierer seine Klassen &#8220;Fahrer&#8221; und &#8220;Tasche&#8221; testen. Hier die fertigen Implementierungen:</p>

<div class="wp_codebox"><table><tr id="p42312"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
</pre></td><td class="code" id="p423code12"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> Fahrer <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Tasche tasche<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> CityBike cityBike<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> Fahrer<span style="color: #009900;">&#40;</span>Tasche tasche, CityBike cityBike<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">null</span> <span style="color: #339933;">==</span> tasche<span style="color: #009900;">&#41;</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> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aillegalargumentexception+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">IllegalArgumentException</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;null as tasche not allowed&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">tasche</span> <span style="color: #339933;">=</span> tasche<span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">null</span> <span style="color: #339933;">==</span> cityBike<span style="color: #009900;">&#41;</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> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aillegalargumentexception+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">IllegalArgumentException</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;null as cityBike not allowed&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">cityBike</span> <span style="color: #339933;">=</span> cityBike<span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000066; font-weight: bold;">void</span> losfahren<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">cityBike</span>.<span style="color: #006633;">addElement</span><span style="color: #009900;">&#40;</span>tasche<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #666666; font-style: italic;">// aufsteigen</span>
        <span style="color: #666666; font-style: italic;">// nach rechts und links schauen</span>
        <span style="color: #666666; font-style: italic;">// anfangen in die Pedalen zu treten</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> Tasche <span style="color: #000000; font-weight: bold;">implements</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aelement+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Element</span></a> <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">int</span> getWeight<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">return</span> <span style="color: #cc66cc;">12</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Before</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Test</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">static</span> org.<span style="color: #006633;">mockito</span>.<span style="color: #006633;">Mockito</span>.<span style="color: #339933;">*;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> FahrerTest <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Tasche tasche<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> CityBike cityBike<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Fahrer fahrer<span style="color: #339933;">;</span>
&nbsp;
    @Before
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> setUp<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">tasche</span> <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>Tasche.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">cityBike</span> <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>CityBike.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">fahrer</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Fahrer<span style="color: #009900;">&#40;</span>tasche, cityBike<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    @Test
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> shouldAddTascheInKorb<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #666666; font-style: italic;">//</span>
        fahrer.<span style="color: #006633;">losfahren</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #666666; font-style: italic;">//</span>
        verify<span style="color: #009900;">&#40;</span>cityBike<span style="color: #009900;">&#41;</span>.<span style="color: #006633;">addElement</span><span style="color: #009900;">&#40;</span>tasche<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Was passiert, wenn wir die Methode addElement(Element e) aus WithBasket und CityBike rausnehmen. Jeder der dann WithBasket, CityBike oder andere Subklassen von WithBasket benutzt muss dann den Wege über getBasket().add(Element e) gehen. Die Methode losfahren in Fahrer sieht dann so aus:</p>

<div class="wp_codebox"><table><tr id="p42313"><td class="line_numbers"><pre>1
2
3
4
5
6
7
</pre></td><td class="code" id="p423code13"><pre class="java" style="font-family:monospace;">    <span style="color: #000066; font-weight: bold;">void</span> losfahren<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">cityBike</span>.<span style="color: #006633;">getBasket</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #006633;">add</span><span style="color: #009900;">&#40;</span>tasche<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #666666; font-style: italic;">// aufsteigen</span>
        <span style="color: #666666; font-style: italic;">// nach rechts und links schauen</span>
        <span style="color: #666666; font-style: italic;">// anfangen in die Pedalen zu treten</span>
    <span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Aber nicht nur das wir jetzt in X Klassen dieses getBasket().add(tasche) stehen haben. Wir machen den Benutzern unserer Klasse auch noch das Testen schwieriger:</p>

<div class="wp_codebox"><table><tr id="p42314"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
</pre></td><td class="code" id="p423code14"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Before</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">org.junit.Test</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">static</span> org.<span style="color: #006633;">mockito</span>.<span style="color: #006633;">Mockito</span>.<span style="color: #339933;">*;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> FahrerTest <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Tasche tasche<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> CityBike cityBike<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Basket basket<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> Fahrer fahrer<span style="color: #339933;">;</span>
&nbsp;
    @Before
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> setUp<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">tasche</span> <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>Tasche.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">cityBike</span> <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>CityBike.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">basket</span> <span style="color: #339933;">=</span> mock<span style="color: #009900;">&#40;</span>Basket.<span style="color: #000000; font-weight: bold;">class</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">fahrer</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Fahrer<span style="color: #009900;">&#40;</span>tasche, cityBike<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #009900;">&#125;</span>
&nbsp;
    @Test
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> shouldAddTascheInKorb<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
&nbsp;
        when<span style="color: #009900;">&#40;</span>cityBike.<span style="color: #006633;">getBasket</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>.<span style="color: #006633;">thenReturn</span><span style="color: #009900;">&#40;</span>basket<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #666666; font-style: italic;">//</span>
&nbsp;
        fahrer.<span style="color: #006633;">losfahren</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #666666; font-style: italic;">//</span>
&nbsp;
        verify<span style="color: #009900;">&#40;</span>basket<span style="color: #009900;">&#41;</span>.<span style="color: #006633;">add</span><span style="color: #009900;">&#40;</span>tasche<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Wir haben eine zusätzliche Membervariable basket im Test und der Test muss noch Vorbereiten das auf cityBike auch wirklich ein Basket geliefert wird. Und hier haben wir nur eine Verschachtelungstiefe. Man denke sich mal aus wie es aussieht wenn wir folgende Situation haben: <code>A.getB().getC().getD().add(E e)</code>. Und jetzt stelle sich der Leser noch vor, dass das ganze Konsequent in der ganzen Applikation so gemacht wird. Irgendwann sind die Tests so aufwendig und kompliziert, dass kein Entwickler mehr Tests schreibt, weil einfach keine Zeit ist. Wenn dagegen immer das Law of Demeter eingehalten wird, dann sind die Tests kurz und einfach.</p>
<p>Schlusswort:</p>
<p>Ich habe hier <a href="http://mockito.org/">Mockito</a> verwendet um die Mock-Objekte zu schreiben. Eine wirkliche Empfehlung von meiner Seite. Diese Bibo ist der Hammer. Wirklich schnell zu lernen und eine wunderschöne API. Gratulation an die Entwickler zu diesem tollen Stück Software.</p>
<p>Schönes Wochenende!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2009/11/21/gesetz-von-demeter-unit-tests-und-der-zweite-programmierer/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Netbeans, Ivy und Spring 3.0.0M4</title>
		<link>http://www.nautsch.net/2009/08/11/netbeans-ivy-und-spring-3-0-0m4/</link>
		<comments>http://www.nautsch.net/2009/08/11/netbeans-ivy-und-spring-3-0-0m4/#comments</comments>
		<pubDate>Tue, 11 Aug 2009 20:35:52 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[netbeans]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=357</guid>
		<description><![CDATA[<p>Ich programmiere gerade eine kleine Web-Applikation und möchte dazu die neuen <a href="http://blog.springsource.com/2009/03/08/rest-in-spring-3-mvc/">REST-Features</a> vom <a href="http://www.springsource.org/">Spring-Framework</a> benutzen. Bis gestern habe ich mir dazu in Netbeans ein Webprojekt gebaut und dann ganz artig alle notwendigen Bibos von Hand dem Projekt hinzugefügt. Gestern wurde nun der Milestone 4 von Spring 3.0.0 veröffentlicht und ich wollte mir nicht [...]]]></description>
			<content:encoded><![CDATA[<p>Ich programmiere gerade eine kleine Web-Applikation und möchte dazu die neuen <a href="http://blog.springsource.com/2009/03/08/rest-in-spring-3-mvc/">REST-Features</a> vom <a href="http://www.springsource.org/">Spring-Framework</a> benutzen. Bis gestern habe ich mir dazu in Netbeans ein Webprojekt gebaut und dann ganz artig alle notwendigen Bibos von Hand dem Projekt hinzugefügt. Gestern wurde nun der Milestone 4 von Spring 3.0.0 veröffentlicht und ich wollte mir nicht noch einmal die Arbeit machen.<br />
<span id="more-357"></span><br />
Also musste ein Tool her, welches mir alle notwendigen Jar&#8217;s auflösen kann und in mein Projekt einhängt. Da ich nicht so ein rechter Fan von <a href="http://ant.apache.org/ivy/">Maven</a> bin, habe ich wieder einmal die Gelegenheit genutzt und <a href="http://ant.apache.org/ivy/">Ivy</a> ausprobiert. Als IDE verwende ich <a href="http://www.netbeans.org/">Netbeans</a> &#8211; also muss ein Plugin für Netbeans her, welches mir die Arbeit mit Ivy innerhalb der IDE vereinfacht. Also schnell mal bei <a href="http://code.google.com/p/ivybeans/">ivybeans</a> vorbeigeschaut. Version 1.1 unterstützt jetzt auch Webprojekte &#8211; Schick! Also schnell das Plugin installiert und ein Repository gesucht in welchem die 3.0.0M4 Version von Spring liegt. Nach ein wenig Suchen habe ich dann herausgefunden, dass es ein Spring-eigenes Repository in <a href="http://aws.amazon.com/s3/">Amazon S3</a> gibt (<a href="http://s3browse.com/explore/maven.springframework.org/milestone/org/springframework/spring-webmvc/3.0.0.M4/">S3Browse</a> ist übrigens ein guter Browser für S3).</p>
<p>Dann habe ich mir noch die folgenden zwei Dateien für die Konfiguration von Ivy im Projektverzeichnis meines Webprojektes angelegt:</p>
<p><a href="http://www.nautsch.net/wp-content/uploads/ivy-configfiles-location.png"><img class="alignnone size-medium wp-image-370" title="Ablageort der Konfigurationsdateien von Ivy" src="http://www.nautsch.net/wp-content/uploads/ivy-configfiles-location-224x300.png" alt="Ablageort der Konfigurationsdateien von Ivy" width="224" height="300" /></a></p>
<p>Hier der Inhalt der Dateien:</p>

<div class="wp_codebox"><table><tr id="p35717"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
</pre></td><td class="code" id="p357code17"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;?xml</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span> <span style="color: #000066;">encoding</span>=<span style="color: #ff0000;">&quot;UTF-8&quot;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;ivy-module</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;2.0&quot;</span></span>
<span style="color: #009900;">            <span style="color: #000066;">xmlns:xsi</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/2001/XMLSchema-instance&quot;</span></span>
<span style="color: #009900;">            <span style="color: #000066;">xsi:noNamespaceSchemaLocation</span>=</span>
<span style="color: #009900;">                   <span style="color: #ff0000;">&quot;http://ant.apache.org/ivy/schemas/ivy.xsd&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;info</span> <span style="color: #000066;">module</span>=<span style="color: #ff0000;">&quot;WebApplication2&quot;</span> <span style="color: #000066;">organisation</span>=<span style="color: #ff0000;">&quot;WebApplication2&quot;</span> <span style="color: #000066;">revision</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;configurations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;conf</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;compile&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;conf</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;runtime&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;conf</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;compile-test&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;conf</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;runtime-test&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/configurations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;dependencies<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;dependency</span> <span style="color: #000066;">org</span>=<span style="color: #ff0000;">&quot;org.springframework&quot;</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;spring-webmvc&quot;</span> <span style="color: #000066;">rev</span>=<span style="color: #ff0000;">&quot;3.0.0.M4&quot;</span> <span style="color: #000066;">conf</span>=<span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/dependencies<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/ivy-module<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></td></tr></table></div>


<div class="wp_codebox"><table><tr id="p35718"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
</pre></td><td class="code" id="p357code18"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;?xml</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span> <span style="color: #000066;">encoding</span>=<span style="color: #ff0000;">&quot;UTF-8&quot;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;ivysettings<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;settings</span> <span style="color: #000066;">defaultResolver</span>=<span style="color: #ff0000;">&quot;chained&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;resolvers<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;chain</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;chained&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
            <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;ibiblio</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;maven2&quot;</span> <span style="color: #000066;">m2compatible</span>=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
            <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;ibiblio</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;s3.maven.springframework.org&quot;</span> <span style="color: #000066;">m2compatible</span>=<span style="color: #ff0000;">&quot;true&quot;</span> <span style="color: #000066;">root</span>=<span style="color: #ff0000;">&quot;http://s3.amazonaws.com/maven.springframework.org/milestone/&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/chain<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/resolvers<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/ivysettings<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></td></tr></table></div>

<p>Dann im Projekt Ivy aktivieren. Dazu mit der rechten Maustaste auf das Projekt und in den Ivy-Einstellungen das Häkchen machen und die zwei Dateien auswählen:</p>
<p><a href="http://www.nautsch.net/wp-content/uploads/ivy-activation-netbeans.png"><img class="alignnone size-medium wp-image-365" title="Ivy in Netbeans aktivieren" src="http://www.nautsch.net/wp-content/uploads/ivy-activation-netbeans-300x142.png" alt="Ivy in Netbeans aktivieren" width="300" height="142" /></a></p>
<p>Dann noch das Projekt zwingen sich die Jars zu holen:</p>
<p><a href="http://www.nautsch.net/wp-content/uploads/ivy-force-resolve.png"><img class="alignnone size-medium wp-image-366" title="Force Resolve" src="http://www.nautsch.net/wp-content/uploads/ivy-force-resolve-179x300.png" alt="Force Resolve" width="179" height="300" /></a></p>
<p>Und siehe da&#8230; alle Jar&#8217;s und Sourcen (wenn im Repository) sind da:</p>
<p><a href="http://www.nautsch.net/wp-content/uploads/ivy-resolved-jars.png"><img class="alignnone size-medium wp-image-367" title="Mit Ivy geholte Abhängigkeiten (Jar's und Sourcen)" src="http://www.nautsch.net/wp-content/uploads/ivy-resolved-jars-243x300.png" alt="Mit Ivy geholte Abhängigkeiten (Jar's und Sourcen)" width="243" height="300" /></a></p>
<p>Mit der rechten Maustaste kann man nun ganz einfach die Abhängigkeiten entfernen, die man nicht braucht.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2009/08/11/netbeans-ivy-und-spring-3-0-0m4/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Upgrade Debian Etch zu Debian Lenny mit Virtualmin</title>
		<link>http://www.nautsch.net/2009/05/04/upgrade-debian-etch-zu-debian-lenny-mit-virtualmin/</link>
		<comments>http://www.nautsch.net/2009/05/04/upgrade-debian-etch-zu-debian-lenny-mit-virtualmin/#comments</comments>
		<pubDate>Mon, 04 May 2009 19:54:47 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[os]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=294</guid>
		<description><![CDATA[<p>Letztes Wochenende habe ich nun endlich meinen <a href="http://www.hetzner.de/">Hetzner</a>-Server von <a href="http://www.debian.org/">Debian</a> 4 auf Debian 5 umgestellt. Zur Administration der Domains benutze ich Virtualmin und dies sollte natürlich dann auch noch laufen. Eine Anleitung war bei <a href="http://www.virtualmin.com/documentation/id,upgrading_debian_etch_to_lenny_with_distupgrade/">www.virtualmin.com</a> zu finden. Allerdings stimmte da die Reihenfolge in welcher man die Pakete installieren sollte noch nicht ganz. [...]]]></description>
			<content:encoded><![CDATA[<p>Letztes Wochenende habe ich nun endlich meinen <a href="http://www.hetzner.de/">Hetzner</a>-Server von <a href="http://www.debian.org/">Debian</a> 4 auf Debian 5 umgestellt. Zur Administration der Domains benutze ich Virtualmin und dies sollte natürlich dann auch noch laufen. Eine Anleitung war bei <a href="http://www.virtualmin.com/documentation/id,upgrading_debian_etch_to_lenny_with_distupgrade/">www.virtualmin.com</a> zu finden. Allerdings stimmte da die Reihenfolge in welcher man die Pakete installieren sollte noch nicht ganz. Nachdem ich einen Bug bei virtualmin.com aufgemacht hatte, war das Problem aber zusammen mit den Jungs von virtualmin.com (Jamie Cameron und Joe Cooper) schnell gelöst. Wirklich schneller und kompetenter Support &#8211; <strong>Spitzenklasse!</strong></p>
<p>Nach dem Upgrade konnte ich mich dann aber nicht via POP3 auf dem Mail-Server einloggen. Ich musste dazu noch die Konfigurationsdatei (/etc/default/saslauthd) von saslauthd anpassen:</p>
<blockquote><p>Die Zeile</p>
<p><code>START=no</code></p>
<p>auf</p>
<p><code>START=yes</code></p>
<p>ändern und den richten Pfad eintragen. Von:</p>
<p><code>OPTIONS="-c -m /var/run/saslauthd"</code></p>
<p>auf:</p>
<p><code>OPTIONS="-c -m /var/spool/postfix/var/run/saslauthd"</code></p>
<p>Dann die Services nochmal neu starten</p>
<pre># /etc/init.d/saslauthd restart
# /etc/init.d/postfix restart</pre>
</blockquote>
<p>Und schon funktionierte die Anmeldung auf dem POP3 wieder.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2009/05/04/upgrade-debian-etch-zu-debian-lenny-mit-virtualmin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Künstler und Softwareentwicklung &#8211; Teil 2</title>
		<link>http://www.nautsch.net/2009/03/18/kunstler-und-softwareentwicklung-teil-2/</link>
		<comments>http://www.nautsch.net/2009/03/18/kunstler-und-softwareentwicklung-teil-2/#comments</comments>
		<pubDate>Wed, 18 Mar 2009 20:12:34 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=272</guid>
		<description><![CDATA[<p>Nun, Künstler und Auftragsarbeiten ist so eine Sache&#8230; Aber nicht nur der Punkt war an meinem letzten Blog-Eintrag ein wenig &#8220;schräg&#8221;.  </p> <p>Unter der Annahme das der Auftraggeber weiss was er möchte, geht es eigentlich bei der Anforderungsanalyse darum, dass der Auftragnehmer versteht was der Kunde eigentlich möchte. D.h. der Künstler &#8211; um beim Beispiel [...]]]></description>
			<content:encoded><![CDATA[<p>Nun, Künstler und Auftragsarbeiten ist so eine Sache&#8230; Aber nicht nur der Punkt war an meinem letzten Blog-Eintrag ein wenig &#8220;schräg&#8221;.  <img src='http://www.nautsch.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Unter der Annahme das der Auftraggeber weiss was er möchte, geht es eigentlich bei der Anforderungsanalyse darum, dass der Auftragnehmer versteht was der Kunde eigentlich möchte. D.h. der Künstler &#8211; um beim Beispiel zu bleiben &#8211; muss die grobe Beschreibung lesen und die richtigen Fragen stellen. Er muss dem Bildliebhaber z.B. fragen: &#8220;Ist es okay, wenn das Bild kubistisch ist?&#8221;. Wenn das nicht klar ist, dann muss man sich darüber unterhalten&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2009/03/18/kunstler-und-softwareentwicklung-teil-2/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Künstler und Softwareentwicklung</title>
		<link>http://www.nautsch.net/2009/03/12/maler-und-softwareentwicklung/</link>
		<comments>http://www.nautsch.net/2009/03/12/maler-und-softwareentwicklung/#comments</comments>
		<pubDate>Thu, 12 Mar 2009 14:42:01 +0000</pubDate>
		<dc:creator>ollin</dc:creator>
				<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.nautsch.net/?p=269</guid>
		<description><![CDATA[<p>Was hat die Anforderungsanalyse oder besser <a href="http://de.wikipedia.org/wiki/Anforderungserhebung" target="_blank">Anforderungserhebung</a> in der Softwareentwicklung mit einem Künstler zu tun?</p> <p>Will man ein Softwaresystem bauen, so muss man wissen was man da eigentlich bauen möchte. Logisch, oder? Also notiert man sich die Anforderungen. Doch die Frage ist: Wie genau muss dies gemacht werden?</p> <p>Genau wie man Aufwand in [...]]]></description>
			<content:encoded><![CDATA[<p>Was hat die Anforderungsanalyse oder besser <a href="http://de.wikipedia.org/wiki/Anforderungserhebung" target="_blank">Anforderungserhebung</a> in der Softwareentwicklung mit einem Künstler zu tun?</p>
<p>Will man ein Softwaresystem bauen, so muss man wissen was man da eigentlich bauen möchte. Logisch, oder? Also notiert man sich die Anforderungen. Doch die Frage ist: Wie genau muss dies gemacht werden?</p>
<p><span id="more-269"></span>Genau wie man Aufwand in die Erstellung eines Systems steckt, so bekommt auch eine detailierte Anforderungsspezfikation nicht umsonst erstellt. Es macht auch wenig Sinn 3 Jahre zu spezifizieren und dann festzustellen, dass man es in 3 Monaten implementieren kann. Die Verhältnismässigkeit ist nicht mehr gegeben. Als Auftraggeber kann man nun trotzdem der Meinung sein, dass, wenn man nur genau genug sein Anliegen spezifiziert, diesen Anforderungskatalog jedem Softwareentwickler geben kann und dann das System erhält, welches man haben möchte.</p>
<p>Dazu folgendes Gedankenspiel:</p>
<blockquote><p>Herangehensweise 1:</p>
<p>Ich möchte ein Bild für mein Wohnzimmer. Es sollen Pferde auf einer Wiese dargestellt werden. Nun beschreibe ich das Bild so gut wie ich kann und gehe zum ersten Künstler um die Ecke.</p>
<p>Herangehensweise 2:</p>
<p>Als erstes suche ich mir einen Künstler aus, dessen Werke ich kenne und die mir gefallen. Eventuell hat er schon ähnliche Bilder gemalt und ich beschreibe mein Wunschbild in groben Zügen.</p>
<p>Was funktioniert besser?</p>
<p>Man bedenke allein die vielen Stilrichtungen &#8230; Der Künstler an der Ecke war ein Kubist und ich habe alles spezifiziert nur nicht die Stilrichtung. Wo ich doch <a href="http://de.wikipedia.org/wiki/Caspar_David_Friedrich">Caspar David Friedrich</a> so mag.</p></blockquote>
<p>Fortsetzung folgt&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nautsch.net/2009/03/12/maler-und-softwareentwicklung/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

