A parser inspired by the django orm.
| 1 | """ |
| 2 | Translator functions for the basics. |
| 3 | """ |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | """Extracts hours and minutes into separate strings""" |
| 10 | |
| 11 | |
| 12 | |
| 13 | = |
| 14 | return , |
| 15 | |
| 16 | |
| 17 | |
| 18 | """Converts hour and minute string into a time delta""" |
| 19 | , = |
| 20 | return |
| 21 | |
| 22 | |
| 23 | |
| 24 | """Converts hours and minutes to a total number of minutes""" |
| 25 | , = |
| 26 | return +*60 |
| 27 | |
| 28 | |
| 29 | |
| 30 | """Converts numbers to a phone number with country code readiness""" |
| 31 | = |
| 32 | |
| 33 | |
| 34 | |
| 35 | return + |
| 36 | |
| 37 | return + |