| Conditions | 3 |
| Paths | 3 |
| Total Lines | 18 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 27 | public function __construct($identifier, $type) |
||
| 28 | { |
||
| 29 | if (!is_string($identifier)) { |
||
| 30 | throw InvalidArgumentException::invalidType('string', 'identifier', $identifier); |
||
| 31 | } |
||
| 32 | |||
| 33 | $this->identifier = $identifier; |
||
| 34 | |||
| 35 | if (!in_array($type, [self::TYPE_GATEWAY, self::TYPE_SECOND_FACTOR_ONLY])) { |
||
| 36 | throw InvalidArgumentException::invalidType( |
||
| 37 | 'AuthnContextClassRef class constant', |
||
| 38 | 'type', |
||
| 39 | $type |
||
| 40 | ); |
||
| 41 | } |
||
| 42 | |||
| 43 | $this->type = $type; |
||
| 44 | } |
||
| 45 | |||
| 79 |