Conditions | 2 |
Paths | 2 |
Total Lines | 13 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 3 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
48 | public function __construct($confidence = self::LOW_CONFIDENCE) |
||
49 | { |
||
50 | if (!in_array($confidence, [ |
||
51 | self::VERY_HIGH_CONFIDENCE, |
||
52 | self::HIGH_CONFIDENCE, |
||
53 | self::MEDIUM_CONFIDENCE, |
||
54 | self::LOW_CONFIDENCE, |
||
55 | ]) |
||
56 | ) { |
||
57 | throw new \InvalidArgumentException('The confidence should be one of the constants defined in Guess.'); |
||
58 | } |
||
59 | $this->confidence = $confidence; |
||
60 | } |
||
61 | |||
70 |