public function deleteType(ClassMetadata $metadata) { $type = $this->getIndex($metadata->index)->getType($metadata->type); return $type->delete(); }