isBinary property

bool get isBinary

Checks if string is binary.

Implementation

bool get isBinary => matchesRegex(r'^[0-1]+$');