hexToInt static method

int hexToInt(
  1. String hex
)

16进制转int

Implementation

static int hexToInt(String hex) {
  return int.tryParse(hex.replaceAll('0x', ''), radix: 16) ?? 0;
}