PluginProbe ʕ •ᴥ•ʔ
WP 2FA – Two-factor authentication for WordPress / 2.4.2
WP 2FA – Two-factor authentication for WordPress v2.4.2
4.0.0 1.7.1 2.0.0 2.0.1 2.1.0 2.2.0 2.2.1 2.3.0 2.4.0 2.4.1 2.4.2 2.5.0 2.6.0 2.6.1 2.6.2 2.6.3 2.6.4 2.7.0 2.8.0 2.9.0 2.9.1 2.9.2 2.9.3 3.0.0 3.0.1 3.1.0 3.1.1 3.1.1.2 trunk 1.2.0 1.3.0 1.4.0 1.4.1 1.4.2 1.5.0 1.5.1 1.5.2 1.6.0 1.6.1 1.6.2 1.7.0
wp-2fa / vendor / endroid / qr-code / src / ErrorCorrectionLevel.php
wp-2fa / vendor / endroid / qr-code / src Last commit date
Exception 3 years ago Factory 3 years ago Writer 3 years ago ErrorCorrectionLevel.php 3 years ago LabelAlignment.php 3 years ago QrCode.php 3 years ago QrCodeInterface.php 3 years ago WriterRegistry.php 3 years ago WriterRegistryInterface.php 3 years ago
ErrorCorrectionLevel.php
38 lines
1 <?php
2
3 declare (strict_types=1);
4 /*
5 * (c) Jeroen van den Enden <info@endroid.nl>
6 *
7 * This source file is subject to the MIT license that is bundled
8 * with this source code in the file LICENSE.
9 */
10 namespace WP2FA_Vendor\Endroid\QrCode;
11
12 use WP2FA_Vendor\BaconQrCode\Common\ErrorCorrectionLevel as BaconErrorCorrectionLevel;
13 use WP2FA_Vendor\MyCLabs\Enum\Enum;
14 /**
15 * @method static ErrorCorrectionLevel LOW()
16 * @method static ErrorCorrectionLevel MEDIUM()
17 * @method static ErrorCorrectionLevel QUARTILE()
18 * @method static ErrorCorrectionLevel HIGH()
19 *
20 * @extends Enum<string>
21 * @psalm-immutable
22 */
23 class ErrorCorrectionLevel extends Enum
24 {
25 const LOW = 'low';
26 const MEDIUM = 'medium';
27 const QUARTILE = 'quartile';
28 const HIGH = 'high';
29 /**
30 * @psalm-suppress ImpureMethodCall
31 */
32 public function toBaconErrorCorrectionLevel() : BaconErrorCorrectionLevel
33 {
34 $name = \strtoupper(\substr($this->getValue(), 0, 1));
35 return BaconErrorCorrectionLevel::valueOf($name);
36 }
37 }
38