(cant_be_number, raw_string, convert_to, default_value, *field_names)
| 284 | return None |
| 285 | |
| 286 | def _get_field(cant_be_number, raw_string, convert_to, default_value, *field_names): |
| 287 | retval = _get_field_actual(cant_be_number, raw_string, field_names) |
| 288 | |
| 289 | # Convert the return value |
| 290 | if retval and convert_to: |
| 291 | try: |
| 292 | retval = convert_to(retval) |
| 293 | except: |
| 294 | retval = default_value |
| 295 | |
| 296 | # Return the default if there is no return value |
| 297 | if retval is None: |
| 298 | retval = default_value |
| 299 | |
| 300 | return retval |
| 301 | |
| 302 | def _get_hz_string_from_brand(processor_brand): |
| 303 | # Just return 0 if the processor brand does not have the Hz |
no test coverage detected
searching dependent graphs…