Index: /trunk/src/lib/lang/class_list.cc
===================================================================
--- /trunk/src/lib/lang/class_list.cc	(revision 5102)
+++ /trunk/src/lib/lang/class_list.cc	(revision 5103)
@@ -48,4 +48,9 @@
 {
   delete this->objectList;
+  if(ClassList::classList != NULL)
+  {
+    delete ClassList::classList;
+    ClassList::classList = NULL;
+  }
   --ClassList::classCount;
 }
@@ -56,4 +61,7 @@
 //! the Count of classes
 unsigned int ClassList::classCount = 0;
+
+//! a List of all strings of all classes, that have registered so far.
+tList<const char>* ClassList::classList = NULL;
 
 /**
@@ -107,4 +115,33 @@
     tmp = tmp->next;
   }
+}
+
+/**
+ * grabs the names of all Classes, and injects it into a List of const chars
+ * @return the generated List
+ *
+ * This function first looks, if the List has been changed (by the ListSize)
+ * befor it changes anything.
+ */
+const tList<const char>* ClassList::getClassList()
+{
+  if (unlikely(ClassList::classList != NULL && ClassList::classList->getSize() != ClassList::classCount))
+  {
+    delete ClassList::classList;
+    ClassList::classList = NULL;
+  }
+  if (unlikely(ClassList::classList == NULL))
+    ClassList::classList = new tList<const char>;
+
+  if(likely(ClassList::first != NULL))
+  {
+    ClassList* tmpCL = ClassList::first;
+    while (likely(tmpCL != NULL))
+    {
+      ClassList::classList->add(tmpCL->className);
+      tmpCL = tmpCL->next;
+    }
+  }
+  return ClassList::classList;
 }
 
Index: /trunk/src/lib/lang/class_list.h
===================================================================
--- /trunk/src/lib/lang/class_list.h	(revision 5102)
+++ /trunk/src/lib/lang/class_list.h	(revision 5103)
@@ -35,26 +35,28 @@
 
     // STATIC FUNCTIONS
-    static void               addToClassList(BaseObject* objectPointer, const long& classID, const char* className);
-    static void               removeFromClassList(BaseObject* objectPointer);
+    static void                     addToClassList(BaseObject* objectPointer, const long& classID, const char* className);
+    static void                     removeFromClassList(BaseObject* objectPointer);
 
-    static tList<BaseObject>* getList(long classID = CL_NULL);
-    static tList<BaseObject>* getList(const char* className);
-    static BaseObject*        getObject(const char* name, long classID = CL_NULL);
-    static bool               exists(const BaseObject* object, long classID = CL_NULL);
+    static tList<BaseObject>*       getList(long classID = CL_NULL);
+    static tList<BaseObject>*       getList(const char* className);
+    static const tList<const char>* getClassList();
+    static BaseObject*              getObject(const char* name, long classID = CL_NULL);
+    static bool                     exists(const BaseObject* object, long classID = CL_NULL);
 
-    static void               whatIs(const BaseObject* object);
-    static void debug(unsigned int debugLevel = 0, long classID = CL_NULL);
+    static void                     whatIs(const BaseObject* object);
+    static void                     debug(unsigned int debugLevel = 0, long classID = CL_NULL);
 
   private:
-    tList<BaseObject>*       objectList;             //!< A list of Objects belonging to this Class
+    tList<BaseObject>*              objectList;             //!< A list of Objects belonging to this Class
 
-    long                     classID;                //!< ClassID stored in this ClassList \see ClassID
-    const char*              className;              //!< Name of the Class Stored here
+    long                            classID;                //!< ClassID stored in this ClassList \see ClassID
+    const char*                     className;              //!< Name of the Class Stored here
 
-    ClassList*               next;                   //!< Pointer to the next class in the List
+    ClassList*                      next;                   //!< Pointer to the next class in the List
 
     // STATIC MEMBERS
-    static ClassList*        first;                  //!< The first Class in the List
-    static unsigned int      classCount;             //!< The Count of classes that have been registered (should match the lower description)
+    static ClassList*               first;                  //!< The first Class in the List
+    static tList<const char>*       classList;              //!< a List of all Names of all classes, that have registered so far.
+    static unsigned int             classCount;             //!< The Count of classes that have been registered (should match the lower description)
 };
 
Index: /trunk/src/lib/util/list.h
===================================================================
--- /trunk/src/lib/util/list.h	(revision 5102)
+++ /trunk/src/lib/util/list.h	(revision 5103)
@@ -135,10 +135,10 @@
   void removeLast();
   void flush();
-  T* firstElement();
-  T* lastElement();
-  bool isEmpty();
-  unsigned int getSize();
+  T* firstElement() const;
+  T* lastElement() const;
+  bool isEmpty() const;
+  unsigned int getSize() const;
   bool inList(T* entity);
-  tIterator<T>* getIterator();
+  tIterator<T>* getIterator() const;
   T* nextElement(T* toEntity);
   T* toArray();
@@ -303,5 +303,5 @@
 */
 template<class T>
-inline T* tList<T>::firstElement()
+inline T* tList<T>::firstElement() const
 {
   return this->first->curr;
@@ -314,5 +314,5 @@
 */
 template<class T>
-inline T* tList<T>::lastElement()
+inline T* tList<T>::lastElement() const
 {
   return this->last->curr;
@@ -325,5 +325,5 @@
 */
 template<class T>
-inline bool tList<T>::isEmpty()
+inline bool tList<T>::isEmpty() const
 {
   return (this->size==0)?true:false;
@@ -359,5 +359,5 @@
 */
 template<class T>
-inline unsigned int tList<T>::getSize()
+inline unsigned int tList<T>::getSize() const
 {
   return this->size;
@@ -372,5 +372,5 @@
 */
 template<class T>
-inline tIterator<T>* tList<T>::getIterator()
+inline tIterator<T>* tList<T>::getIterator() const
 {
   tIterator<T>* iterator = new tIterator<T>(this->first);
Index: /trunk/src/util/shell.cc
===================================================================
--- /trunk/src/util/shell.cc	(revision 5102)
+++ /trunk/src/util/shell.cc	(revision 5103)
@@ -24,4 +24,5 @@
 
 #include "load_param.h"
+#include "class_list.h"
 #include "debug.h"
 #include <stdarg.h>
@@ -59,4 +60,5 @@
   this->inputLineText->setParent2D(this);
 
+  this->completionList = NULL;
 
   EventHandler* evh = EventHandler::getInstance();
@@ -91,4 +93,7 @@
   }
   delete charIterator;
+
+//  if (this->completionList != NULL)
+    //delete this->completionList;
 
   Shell::singletonRef = NULL;
@@ -465,5 +470,5 @@
   this->classComplete(commandBegin);
 
-   delete[] completionLine;
+  delete[] completionLine;
 }
 
@@ -477,8 +482,7 @@
   if (unlikely(classBegin == NULL))
     return false;
-  tList<const char>* classList = LoadClassDescription::searchClassWithShort(classBegin);
+  const tList<const char>* classList = this->searchClassWithShort(classBegin);
   if (classList->getSize() == 0)
   {
-    delete classList;
      //PRINTF(0)("no completion found for %s\n", commandBegin);
     return false;
@@ -519,5 +523,4 @@
     delete[] adder;
   }
-  delete classList;
 }
 
@@ -529,4 +532,36 @@
 bool Shell::functionComplete(const char* functionBegin)
 {
+}
+
+
+/**
+ * searches for classes, which beginn with classNameBegin
+ * @param classNameBegin the beginning string of a Class
+ * @return a NEW char-array with ClassNames. The LIST should be deleted afterwards,
+ * !! The strings MUST NOT be deleted !!
+ */
+const tList<const char>* Shell::searchClassWithShort(const char* classNameBegin)
+{
+  unsigned int searchLength = strlen(classNameBegin);
+  if (this->completionList != NULL)
+    delete this->completionList;
+  this->completionList = new tList<const char>;
+
+//  tList<const char>* classList = ClassList::getClassList();
+
+  tIterator<const char>* iterator = ClassList::getClassList()->getIterator();
+  const char* enumString = iterator->nextElement();
+  while (enumString != NULL)
+  {
+    if (strlen(enumString)>searchLength+1 &&
+        !strncasecmp(enumString, classNameBegin, searchLength))
+    {
+      this->completionList->add(enumString);
+    }
+    enumString = iterator->nextElement();
+  }
+  delete iterator;
+
+  return this->completionList;
 }
 
@@ -540,4 +575,3 @@
   if (this->pressedKey != SDLK_FIRST)
     printf("%s::%f %f\n", SDLKToKeyname(this->pressedKey), this->delayed, this->repeatDelay);
-
-}
+}
Index: /trunk/src/util/shell.h
===================================================================
--- /trunk/src/util/shell.h	(revision 5102)
+++ /trunk/src/util/shell.h	(revision 5103)
@@ -72,4 +72,7 @@
 
 
+    const tList<const char>* searchClassWithShort(const char* classNameBegin);
+
+
   private:
     Shell();
@@ -93,4 +96,7 @@
 
     char                   bufferArray[10000];     //!< a BUFFER for fast writing
+
+    // completion
+    tList<const char>*    completionList;          //!< A list of completions, that are io.
 };
 
