public function create($wordType, $genreType, $newValue, $created) { $newWord = new Word(); $newWord->setWordType($wordType); $newWord->setWord($newValue); $newWord->setGenreType($genreType); $newWord->setBackup(0); $newWord->setCreated($created); $newWord->setModified(0); $newWord->setEnabled(1); $this->getEntityManager()->persist($newWord); $this->getEntityManager()->flush(); return $newWord; }