MiValue.asInt

long asInt() @safe

Returns

String value parsed as integer.

Throws

Exception if not a string or not an integer.

Example:

auto v = MiValue.fromString("42");
assert(v.asInt() == 42);