fromString static method

BarcodeFormat fromString(
  1. String name
)

Implementation

static BarcodeFormat fromString(String name) {
  return BarcodeFormat.values.firstWhere(
    (format) => format.name == name,
    orElse: () => BarcodeFormat.unknown,
  );
}