decode static method

Rational decode(
  1. String value
)

Decodes a string to a Rational.

Supports fractions, mixed numbers, integers, decimals, and scientific notation. See RationalParsing.fromString for full format details.

Throws FormatException if the string is not a valid format.

Implementation

static Rational decode(String value) => RationalParsing.fromString(value);