public function getObjectTemplate($type, $alias=null, $combineOperator=Criteria::OPERATOR_AND) {
    $template = null;

    // use the typeNode, the first time a node template of the query type is requested
    $persistenceFacade = ObjectFactory::getInstance('persistenceFacade');
    $fqType = $persistenceFacade->getFullyQualifiedType($type);
    if ($fqType == $this->typeNode->getType() && !$this->isTypeNodeInQuery) {
      $template = $this->typeNode;
      $this->isTypeNodeInQuery = true;
      // the typeNode is contained already in the rootNodes array
    }
    else {
      // don't use PersistenceFacade::create, because template instances must be transient
      $mapper = self::getMapper($fqType);
      $template = $mapper->create($fqType, BuildDepth::SINGLE);
      $this->rootNodes[] = $template;
    }
    $template->setProperty(self::PROPERTY_COMBINE_OPERATOR, $combineOperator);
    if ($alias != null) {
      $template->setProperty(self::PROPERTY_TABLE_NAME, $alias);
    }
    $initialOid = $template->getOID()->__toString();
    $template->setProperty(self::PROPERTY_INITIAL_OID, $initialOid);
    $this->observedObjects[$initialOid] = $template;
    return $template;
  }