/**
  * creates the class template for the new specific typehinted ArrayCollection
  */
 private function createClassTemplate()
 {
     $content = $this->read($this->config->getClassTemplate());
     $content = $this->config->replace($content);
     $this->write($this->config->getClassFile(), $content);
     return true;
 }
 /**
  * registers autoloader for new cached files
  *
  * @param TemplateObject $template
  * @param string $cachedclassname
  */
 private function autoload(TemplateObject $template, $cachedclassname)
 {
     $interfacename = ltrim($this->namspace . '\\I' . $cachedclassname, '\\');
     $classname = ltrim($this->namspace . '\\' . $cachedclassname, '\\');
     spl_autoload_register(function ($class) use($template, $interfacename, $classname) {
         $filename = null;
         if ($class == $interfacename) {
             $filename = $template->getInterfaceFile();
         } else {
             if ($class == $classname) {
                 $filename = $template->getClassFile();
             }
         }
         if (!empty($filename) && is_readable($filename)) {
             require_once $filename;
         }
     });
 }