Check whether the key and its value matches definition in CameraParameter.SUPPORTED_KEYS. Args: key (Any): Key in CameraParameter. val (Any): Value to the key. Raises: KeyError: key cannot b
(self, key: Any, val: Any)
| 514 | return cam |
| 515 | |
| 516 | def validate_item(self, key: Any, val: Any) -> List: |
| 517 | """Check whether the key and its value matches definition in |
| 518 | CameraParameter.SUPPORTED_KEYS. |
| 519 | |
| 520 | Args: |
| 521 | key (Any): |
| 522 | Key in CameraParameter. |
| 523 | val (Any): |
| 524 | Value to the key. |
| 525 | |
| 526 | Raises: |
| 527 | KeyError: |
| 528 | key cannot be found in |
| 529 | CameraParameter.SUPPORTED_KEYS. |
| 530 | TypeError: |
| 531 | Value's type doesn't match definition. |
| 532 | Returns: |
| 533 | key (Any): The input key. |
| 534 | val (Any): The value casted into correct format. |
| 535 | """ |
| 536 | self.__check_key__(key) |
| 537 | formatted_val = self.__validate_value_type__(key, val) |
| 538 | return key, formatted_val |
| 539 | |
| 540 | def __check_key__(self, key: Any) -> None: |
| 541 | """Check whether the key matches definition in |
no test coverage detected