public function createDeleteForm(Message $message, $access = "ajax")
    {
        $form_name = "message_delete_" . $message->getId();
        return $this->get('form.factory')->createNamedBuilder($form_name,FormType::class)
            ->setAction($this->generateUrl('message_delete', array(
                'id' => $message->getId(),
                'access' => $access)))
            ->setMethod('DELETE')
            ->getForm()
        ;
    }
public function createDeleteForm(Message $message, $access = "ajax")
    {
        $form_name = "message_delete_" . $message->getId();
        return $this->get('form.factory')->createNamedBuilder($form_name,FormType::class)
            ->setAction($this->generateUrl('message_delete', array(
                'id' => $message->getId(),
                'access' => $access)))
            ->setMethod('DELETE')
            ->getForm()
        ;
    }
public function createDeleteForm ( Message $ message , $ access = "ajax" ) { $ form_name = "message_delete_" . $ message -> getId ( ) ; return $ this -> get ( 'form.factory' ) -> createNamedBuilder ( $ form_name , FormType :: class ) -> setAction ( $ this -> generateUrl ( 'message_delete' , array ( 'id' => $ message -> getId ( ) , 'access' => $ access ) ) ) -> setMethod ( 'DELETE' ) -> getForm ( ) ; }
Creates a form to delete a message entity.

@param Message $message The message entity

@return \Symfony\Component\Form\Form The form
Creates a form to delete a message entity .