toIntOption property

Option<int> toIntOption

Convert this String to int, returns None for invalid inputs.

Implementation

Option<int> get toIntOption => Option.fromNullable(int.tryParse(this));