| Conditions | 2 |
| Total Lines | 18 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | |||
| 15 | @classmethod |
||
| 16 | def genpair(cls, key, optkey, values): |
||
| 17 | ''' |
||
| 18 | Extract value and options from values dict based on given key and |
||
| 19 | options-key. |
||
| 20 | |||
| 21 | :param key: value key |
||
| 22 | :type key: str |
||
| 23 | :param optkey: options key |
||
| 24 | :type optkey: str |
||
| 25 | :param values: value dictionary |
||
| 26 | :type values: dict |
||
| 27 | :returns: tuple of (key, value) |
||
| 28 | :rtype: tuple of str |
||
| 29 | ''' |
||
| 30 | return ( |
||
| 31 | cls.snake_replace(lambda x: x[0].upper(), key.replace('_', '-')), |
||
| 32 | dump_options_header(values[key], values.get(optkey, {})), |
||
| 33 | ) |
||
| 42 |