protected function addFlashMessage($type, $transKey, $transOpts = array(), $domain = 'messages')
    {
        $this->get('session')
            ->getFlashBag()
            ->add(
                $type,
                $this->get('translator')->trans($transKey, $transOpts, $domain)
            );
    }
protected function addFlashMessage($type, $transKey, $transOpts = array(), $domain = 'messages')
    {
        $this->get('session')
            ->getFlashBag()
            ->add(
                $type,
                $this->get('translator')->trans($transKey, $transOpts, $domain)
            );
    }
protected function addFlashMessage ( $ type , $ transKey , $ transOpts = array ( ) , $ domain = 'messages' ) { $ this -> get ( 'session' ) -> getFlashBag ( ) -> add ( $ type , $ this -> get ( 'translator' ) -> trans ( $ transKey , $ transOpts , $ domain ) ) ; }
Ajout le message flash dans la session.

@param string $type      (alert|error|info|success)
@param string $transKey  la clé de traduction
@param array  $transOpts $options de substitution
@param string $domain    domaine de traduction

@return void
Ajout le message flash dans la session .