You are here

class CdnDomainConstraint in CDN 8.3

A CDN domain.

@Constraint( id = "CdnDomain", label = @Translation("CDN domain", context = "Validation"), )

An authority as defined in RFC3986. An authority consists of host, optional userinfo and optional port. The host can be an IP address or registered domain name.

Hierarchy

  • class \Drupal\cdn\Plugin\Validation\Constraint\CdnDomainConstraint extends \Symfony\Component\Validator\Constraint

Expanded class hierarchy of CdnDomainConstraint

See also

https://tools.ietf.org/html/rfc3986#section-3.2

1 file declares its use of CdnDomainConstraint
CdnDomainConstraintValidatorTest.php in tests/src/Unit/Plugin/Validation/Constraint/CdnDomainConstraintValidatorTest.php

File

src/Plugin/Validation/Constraint/CdnDomainConstraint.php, line 20

Namespace

Drupal\cdn\Plugin\Validation\Constraint
View source
class CdnDomainConstraint extends Constraint {
  public $message = 'The provided domain %domain is not valid. Provide a hostname like <samp>cdn.com</samp> or <samp>cdn.example.com</samp>. IP addresses and ports are also allowed.';

}

Members