tryDecode static method
Attempts to decode a string to a Rational.
Returns null if parsing fails or if the input is null.
Use this for user input or untrusted data sources.
Implementation
static Rational? tryDecode(String? value) => RationalParsing.tryFromString(value);