protected function hasRole($role) {
		if(!$this->container->has('security.authorization_checker')) {
			throw new \LogicException('The SecurityBundle is not registered in your application.');
		}
		return false !== $this->get('security.authorization_checker')->isGranted($role);
	}
protected function hasRole($role) {
		if(!$this->container->has('security.authorization_checker')) {
			throw new \LogicException('The SecurityBundle is not registered in your application.');
		}
		return false !== $this->get('security.authorization_checker')->isGranted($role);
	}
protected function hasRole ( $ role ) { if ( ! $ this -> container -> has ( 'security.authorization_checker' ) ) { throw new \ LogicException ( 'The SecurityBundle is not registered in your application.' ) ; } return false !== $ this -> get ( 'security.authorization_checker' ) -> isGranted ( $ role ) ; }
Checks whether the current user has the specified role or not

@param string $role
@throws \LogicException
@return boolean
Checks whether the current user has the specified role or not