IPAValidator
Validation and normalization of IPA
Loading...
Searching...
No Matches
Wikimedia\IPAValidator\Validator Class Reference

Public Member Functions

 __construct (string $ipa, bool $strip=true, bool $normalize=false, bool $google=false)
 Constructor.
 

Public Attributes

 $originalIPA
 
 $normalizedIPA
 
 $valid
 

Protected Attributes

 $ipaRegex =
 
 $stripRegex = "/[\/\[\]]/ui"
 
 $diacriticsRegex = "/[\x{0300}-\x{036f}]/ui"
 
 $strip
 
 $normalize
 
 $google
 

Constructor & Destructor Documentation

◆ __construct()

Wikimedia\IPAValidator\Validator::__construct ( string $ipa,
bool $strip = true,
bool $normalize = false,
bool $google = false )

Constructor.

Parameters
string$ipaIPA to validate
bool$stripRemove delimiters
bool$normalizeNormalize IPA
bool$googleNormalize IPA for Google TTS

The documentation for this class was generated from the following file: