RSAKeyLength   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 5
c 1
b 0
f 0
dl 0
loc 18
rs 10

6 Methods

Rating   Name   Duplication   Size   Complexity  
bit4096() 0 6 ?
A hp$0 ➔ getValue() 0 3 1
bit2048() 0 6 ?
A hp$0 ➔ bit2048() 0 6 1
A hp$1 ➔ getValue() 0 3 1
A hp$1 ➔ bit4096() 0 6 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the LetsEncrypt ACME client.
7
 *
8
 * @author    Ivanov Aleksandr <[email protected]>
9
 * @copyright 2019-2020
10
 * @license   https://github.com/misantron/letsencrypt-client/blob/master/LICENSE MIT License
11
 */
12
13
namespace LetsEncrypt\Enum;
14
15
use Spatie\Enum\Enum;
16
17
class RSAKeyLength extends Enum
18
{
19
    public static function bit2048(): self
20
    {
21
        return new class () extends RSAKeyLength {
22
            public function getValue(): string
23
            {
24
                return '2048';
25
            }
26
        };
27
    }
28
29
    public static function bit4096(): self
30
    {
31
        return new class () extends RSAKeyLength {
32
            public function getValue(): string
33
            {
34
                return '4096';
35
            }
36
        };
37
    }
38
}
39