toIntOrNull method

  1. @useResult
int? toIntOrNull()

Converts this nullable num to an int, or returns null if null.

Implementation

@useResult
int? toIntOrNull() => this?.toInt();