// Beispiele für Codeverbesserungen:
// Hilfsklassen zur Verkürzung von Deklarationen
private class LineType extends LinkedList<Boolean> {private static final long serialVersionUID = 1L;};
private class LineList extends LinkedList<LineType> {private static final long serialVersionUID = 1L;};
private class HintList extends LinkedList<Integer> {private static final long serialVersionUID = 1L;};
private class RessList extends LinkedList<String> {private static final long serialVersionUID = 1L;};
// Generische Klasse
public class Beispiel <ConsumerType,RessourceType>
// Collection-Parameter
public boolean addRessources ( Collection<RessourceType> c)
{
if ( c == null ) return false;
boolean ret = false;
for ( RessourceType r : c )
{
ret = addRessource(r,true) ? true : ret;
}
return ret;
}