protected function getInlineJavaScriptValidationCode(Field $field, $validationName, Validation $validatorConfiguration)
    {
        $javaScriptValidationName = GeneralUtility::quoteJSvalue($validationName);
        $validatorName = addslashes($validatorConfiguration->getClassName());
        $validatorConfigurationFinal = $this->getValidationConfiguration($field, $validationName, $validatorConfiguration);
        $validatorConfigurationFinal = $this->handleValidationConfiguration($validatorConfigurationFinal);

        return <<<JS
                /*
                 * Validation rule "$validationName"
                 */
                field.addValidation($javaScriptValidationName, '$validatorName', $validatorConfigurationFinal);

JS;
    }