fromValue static method

FieldOptionsOptionRetention fromValue(
  1. int? value
)

Looks up a value by its proto wire int. Throws if not found.

Implementation

static FieldOptionsOptionRetention fromValue(int? value) {
  return FieldOptionsOptionRetention.values.firstWhere(
    (e) => e.value == value,
    orElse:
        () =>
            throw ItemNotFoundException(
              name: "FieldOptionsOptionRetention",
              value: value,
            ),
  );
}