<?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>javablog.ch&#187; Generics Gala</title>
	<atom:link href="http://www.javablog.ch/category/generics-gala/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.javablog.ch</link>
	<description>Keep on learning...</description>
	<lastBuildDate>Sun, 04 Dec 2011 17:15:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>Generics Teil 3: Wildcards (und lesender Zugriff darauf)</title>
		<link>http://www.javablog.ch/2006/09/10/generics-teil-3-wildcards-und-lesender-zugriff-darauf/</link>
		<comments>http://www.javablog.ch/2006/09/10/generics-teil-3-wildcards-und-lesender-zugriff-darauf/#comments</comments>
		<pubDate>Sun, 10 Sep 2006 17:21:42 +0000</pubDate>
		<dc:creator>HeikoMaass</dc:creator>
				<category><![CDATA[Generics Gala]]></category>

		<guid isPermaLink="false">http://www.javablog.ch/?p=25</guid>
		<description><![CDATA[Auch der lesende Zugriff auf Wildcard Referenzen ist eingeschränkt. In einer ArrayList]]></description>
			<content:encoded><![CDATA[<p>Auch der lesende Zugriff auf Wildcard Referenzen ist eingeschränkt.</p>
<p>In einer ArrayList<strong><? extends E></strong> werden Objekte vom Typ E oder Subtypen von E gespeichert.<br />
Da wir die obere Grenze kennen, können wir bedenkenlos die Supertypen von E (oder E selbst) aus<br />
dieser ArrayList lesen.</p>
<p><strong>Beispiel:</strong></p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;Stringlist stringList = <span style="color: #222222; font-weight: bold;">new</span> ArrayList&lt;String&gt;<span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">stringList.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">String</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;? <span style="color: #222222; font-weight: bold;">extends</span> CharSequence&gt; list = stringList ;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">CharSequence cs = list.<span style="color: #537799;font-weight: bold;">get</span><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// gibt ein Objekt vom Typ CharSequence zurueck.</span></div></li></ol></div>
</div>
<p>In einer ArrayList<strong><?  super E> </strong>werden Objekte vom Typ E oder die Supertypen von E gespeichert.<br />
Hier kennen wir nur die untere Grenze, und der einzige Cast, der immer funktioniert, ist der<br />
Cast nach <code>Object</code>. Von daher gibt ein lesender Zugriff immer ein Objekt vom Typ <code>Object </code>zurück.</p>
<p><strong>Beispiel:</strong></p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;CharSequence&gt; csList = <span style="color: #222222; font-weight: bold;">new</span> ArrayList&lt;CharSequence&gt;<span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">csList .<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">String</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;? <span style="color: #222222; font-weight: bold;">super</span> String&gt; list = csList &nbsp;;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AObject+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Object</span></a> o = list.<span style="color: #537799;font-weight: bold;">get</span><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// gibt ein Objekt vom Typ Object zurueck.</span></div></li></ol></div>
</div>
<p>Ok, so weit zur Theorie. Aber wo werden diese Wildcards konkret eingesetzt ? Google hilft.</p>
<p><strong><? extends E></strong> wird in der Klassenbibliothek <a href="http://www.google.de/search?hl=de&#038;as_qdr=all&#038;q=%22%3C%3F+extends+E%3E%22+site%3Ahttp%3A%2F%2Fjava.sun.com%2Fj2se%2F1.5.0%2Fdocs%2Fapi%2F&#038;btnG=Suche&#038;meta=">25 mal eingesetzt</a>.<br />
Z.B. <code>Collection.addAll(Collection <? extends E> c)</code></p>
<p><strong><? super E></strong>  dagegen <a href="http://www.google.de/search?hl=de&#038;as_qdr=all&#038;q=%22%3C%3F+super+E%3E%22+site%3Ahttp%3A%2F%2Fjava.sun.com%2Fj2se%2F1.5.0%2Fdocs%2Fapi%2F&#038;btnG=Suche&#038;meta=">nur 9 mal</a>.<br />
Z.B. im Konstruktor von <code>TreeSet(Comparator<? super E> c)</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.javablog.ch/2006/09/10/generics-teil-3-wildcards-und-lesender-zugriff-darauf/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Generics Teil 2: Wildcards (und schreibender Zugriff darauf)</title>
		<link>http://www.javablog.ch/2006/09/03/generics-teil-2-wildcards-und-schreibender-zugriff-darauf/</link>
		<comments>http://www.javablog.ch/2006/09/03/generics-teil-2-wildcards-und-schreibender-zugriff-darauf/#comments</comments>
		<pubDate>Sun, 03 Sep 2006 16:23:57 +0000</pubDate>
		<dc:creator>HeikoMaass</dc:creator>
				<category><![CDATA[Generics Gala]]></category>

		<guid isPermaLink="false">http://www.javablog.ch/?p=24</guid>
		<description><![CDATA[Komplexer werden die Generics mit der Verwendung von sogenannten Wildcards. Es gibt 3 Typen von Wildcards: ArrayList - Die ArrayList kann mit jedem Typ parametisiert worden sein. ArrayList nichts hinzufügen. Warum? Weil nicht bekannt ist, mit welchen Typ diese Liste parametisiert wurde. Wenn ich in die Liste jeden Typ einfügen könnte, dann könnte ich auch [...]]]></description>
			<content:encoded><![CDATA[<p>Komplexer werden die Generics mit der Verwendung von sogenannten <strong>Wildcards</strong>. Es gibt 3 Typen von Wildcards:</p>
<ul>
<li>ArrayList<strong><?></strong>	-	Die ArrayList kann mit <strong>jedem </strong>Typ parametisiert worden sein.</li>
<li>ArrayList<strong><? super E></strong>	- Die ArrayList kann mit Typ E oder einer <strong>Oberklasse von Typ E</strong> parametisiert worden sein. (E markiert dabei die untere Grenze)</li>
<li>ArrayList<strong><? extends E></strong>  Die ArrayList kann mit Typ E oder einer <strong>Unterklasse von Typ E</strong> parametisiert worden sein. (E markiert dabei die obere Grenze)</li>
</ul>
<p>Jetzt wirds spannend: Der schreibende Zugriff solche Referenzen ist eingeschränkt. Beispielsweise darf ich in eine Wildcard ArrayList<strong><?> </strong>nichts hinzufügen. Warum?<br />
Weil nicht bekannt ist, mit welchen Typ diese Liste parametisiert wurde. Wenn ich in die Liste<br />
jeden Typ einfügen könnte, dann könnte ich auch einen Typ einfügen, der nicht zum Parametertyp gecastet werden kann.<br />
Das würde dann eine <code>ClassCastException </code>zur Laufzeit bedeuten. (Und das wäre wiederum unschön).</p>
<p><strong>Beispiel:</strong></p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;?&gt; list = <span style="color: #222222; font-weight: bold;">new</span> ArrayList&lt;CharSequence&gt;<span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">list.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">String</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// semantisch zwar richtig, aber der Compiler kann das nicht zulassen, da sonst auch</span></div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">list.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AObject+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Object</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// funktionieren wuerde</span></div></li></ol></div>
</div>
<p>In eine ArrayList<strong><? super E></strong> kann ich dagegen Typ E oder eine Unterklasse von Typ E einfügen, da garantiert ist, dass die Liste mit einer Oberklasse von Typ E (oder Typ E selbst) parametisiert wurde. Ein Cast nach E wird also immer funktionieren.</p>
<p><strong>Beispiel: </strong></p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;? <span style="color: #222222; font-weight: bold;">super</span> CharSequence&gt; list = <span style="color: #222222; font-weight: bold;">new</span> ArrayList&lt;Object&gt;<span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">list.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">String</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; &nbsp; <span style="color: #808080; font-style: italic;">// funktioniert, da String von CharSequence ableitet</span></div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #808080; font-style: italic;">// (und so auch nach CharSequence oder hoeher gecastet werden koennte)</span></div></li></ol></div>
</div>
<p>In eine ArrayList<strong><? extends E></strong> dürfen <strong>überhaupt keine Elemente</strong> hinzugefügt werden. Warum?<br />
Weil sonst immer die Gefahr einer <code>ClassCastException </code>besteht. </p>
<p><strong>Beispiel: </strong></p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;? <span style="color: #222222; font-weight: bold;">extends</span> CharSequence&gt; list = <span style="color: #222222; font-weight: bold;">new</span> ArrayList&lt;StringBuffer&gt;<span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">list.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">String</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// Compilerfehler. String leitet zwar von CharSequence ab, kann aber nicht nach StringBuffer gecastet werden.</span></div></li></ol></div>
</div>
<p></p>
<p>So, genug für heute. Im nächsten Eintrag geht es um dem lesenden Zugriff.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.javablog.ch/2006/09/03/generics-teil-2-wildcards-und-schreibender-zugriff-darauf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Generics Teil 1: Einführung</title>
		<link>http://www.javablog.ch/2006/09/02/generics-teil-1-einfuhrung/</link>
		<comments>http://www.javablog.ch/2006/09/02/generics-teil-1-einfuhrung/#comments</comments>
		<pubDate>Sat, 02 Sep 2006 21:01:56 +0000</pubDate>
		<dc:creator>HeikoMaass</dc:creator>
				<category><![CDATA[Generics Gala]]></category>

		<guid isPermaLink="false">http://www.javablog.ch/?p=23</guid>
		<description><![CDATA[Vor kurzem wurde ich nach dem Sinn bzw. dem Einsatzzweck von &#60;? super E&#62; gefragt. Bevor ich die Frage hier im Blog nochmals beantworte, kurz noch eine ganz kleine Einführung in Generics Mit dem JDK 5.0 kamen die sogenannten Generics, mit denen Klassen und Methoden zusätzlich parametisiert werden können (Ähnlich wie die Templates in C++, [...]]]></description>
			<content:encoded><![CDATA[<p>Vor kurzem wurde ich nach dem Sinn bzw. dem Einsatzzweck von &lt;? super E&gt; gefragt.<br />
Bevor ich die Frage hier im Blog nochmals beantworte, kurz noch eine ganz kleine Einführung in Generics <img src='http://www.javablog.ch/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Mit dem JDK 5.0 kamen die sogenannten Generics, mit denen Klassen und Methoden zusätzlich<br />
parametisiert werden können (Ähnlich wie die Templates in C++, mit dem Unterschied, dass keine<br />
neuen Klassen pro Parametertyp erstellt werden). Ziel der Generics ist die <strong>Lesbarkeit des Codes zu erhöhen</strong> und <strong>explizite Casts zu reduzieren</strong>. Allerdings kann die Verwendung von Generics auch sehr tückisch werden. Aber fangen wir mal einfach an (also ohne Generics):</p>
<p>Der folgende Codeausschnitt wird kompiliert und erzeugt zur Laufzeit eine ClassCastException. Unschön.</p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AArrayList+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">ArrayList</span></a> intList = <span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AArrayList+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">ArrayList</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">intList.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3ADouble+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Double</span></a><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">2</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// Semantisch falsch, aber kein Fehler beim Kompilieren.</span></div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AInteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Integer</span></a> integer = <span style="color: #111111;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AInteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Integer</span></a><span style="color: #111111;">&#41;</span> intList.<span style="color: #537799;font-weight: bold;">get</span><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #111111;">&#41;</span>; <span style="color: #808080; font-style: italic;">// Ups, ClassCastException zur Laufzeit</span></div></li></ol></div>
</div>
<p>Ungefährlicher ist Codeausschnitt 2, da hier schon der Compiler den Fehler meldet:</p>
<div class="codeblock">
<div class="java" style="font-family: monospace;"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ArrayList&lt;Integer&gt; intList = <span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AArrayList+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">ArrayList</span></a><span style="color: #111111;">&#40;</span><span style="color: #111111;">&#41;</span>&lt;Integer&gt;;</div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">intList.<span style="color: #537799;font-weight: bold;">add</span><span style="color: #111111;">&#40;</span><span style="color: #222222; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3ADouble+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Double</span></a><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">2</span><span style="color: #111111;">&#41;</span><span style="color: #111111;">&#41;</span>; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// Fehler zur Kompilierzeit</span></div></li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AInteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Integer</span></a> integer = <span style="color: #111111;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AInteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #415D77; ">Integer</span></a><span style="color: #111111;">&#41;</span> intList.<span style="color: #537799;font-weight: bold;">get</span><span style="color: #111111;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #111111;">&#41;</span>;</div></li></ol></div>
</div>
<p>Mit der Verwendung der Generics wird die ArrayListe parametisiert und erlaubt nur das Hinzufügen<br />
von Integer Objekten. Der Compiler unterbindet den fehlerhaften Aufruf und verhindert unliebsame<br />
Überraschungen zur Laufzeit. Schön.</p>
<p>Morgen gibts schon weiter mit Teil 2: Wildcards. Da wirds etwas kniffliger.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.javablog.ch/2006/09/02/generics-teil-1-einfuhrung/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

