| Total Complexity | 4 |
| Total Lines | 45 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | class IntegerValue extends DecimalValue |
||
| 18 | { |
||
| 19 | /** @var string */ |
||
| 20 | public const SCHEMA_TYPE = 'integer'; |
||
| 21 | |||
| 22 | |||
| 23 | /** |
||
| 24 | * Validate the value. |
||
| 25 | * |
||
| 26 | * @param string $value |
||
| 27 | * @throws \SimpleSAML\XML\Exception\SchemaViolationException on failure |
||
| 28 | * @return void |
||
| 29 | */ |
||
| 30 | protected function validateValue(string $value): void |
||
| 33 | } |
||
| 34 | |||
| 35 | |||
| 36 | /** |
||
| 37 | * Convert from integer |
||
| 38 | * |
||
| 39 | * @param int $value |
||
| 40 | * @return static |
||
| 41 | */ |
||
| 42 | public static function fromInteger(int $value): static |
||
| 45 | } |
||
| 46 | |||
| 47 | |||
| 48 | /** |
||
| 49 | * Convert to integer |
||
| 50 | * |
||
| 51 | * @return int |
||
| 52 | */ |
||
| 53 | public function toInteger(): int |
||
| 64 |