You are here

PushNotificationsTokenLanguageConstraint.php in Push Notifications 8

File

src/Plugin/Validation/Constraint/PushNotificationsTokenLanguageConstraint.php
View source
<?php

namespace Drupal\push_notifications\Plugin\Validation\Constraint;

use Symfony\Component\Validator\Constraints\Choice;

/**
 * Validate that the language code passed is valid..
 *
 * @Constraint(
 *   id = "PushNotificationsTokenLanguage",
 *   label = @Translation("Language code in token entity", context = "Validation")
 * )
 */
class PushNotificationsTokenLanguageConstraint extends Choice {
  public $message = 'The language code %value is not a valid language code.';

}

Classes

Namesort descending Description
PushNotificationsTokenLanguageConstraint Validate that the language code passed is valid..