Symfony\Component\Form\FormConfiguration::getDefaultLocale PHP Метод

getDefaultLocale() публичный статический Метод

Returns the default locale for newly created forms.
public static getDefaultLocale ( ) : string
Результат string
    static public function getDefaultLocale()
    {
        return self::$defaultLocale;
    }

Usage Example

Пример #1
0
 /**
  * Constructor.
  *
  * @param string $name
  * @param array|object $data
  * @param ValidatorInterface $validator
  * @param array $options
  */
 public function __construct($name, $data, ValidatorInterface $validator, array $options = array())
 {
     $this->validator = $validator;
     $this->setData($data);
     if (FormConfiguration::isDefaultCsrfProtectionEnabled()) {
         $this->enableCsrfProtection();
     }
     if (FormConfiguration::getDefaultLocale() !== null) {
         $this->setLocale(FormConfiguration::getDefaultLocale());
     }
     parent::__construct($name, $options);
 }
All Usage Examples Of Symfony\Component\Form\FormConfiguration::getDefaultLocale