AztecEncodeMode.fromJson constructor

AztecEncodeMode.fromJson(
  1. dynamic data
)

Creates a AztecEncodeMode instance from a JSON representation.

Implementation

AztecEncodeMode.fromJson(dynamic data) {
  switch (data) {
    case "Auto":
    case "Bytes":
    case "ExtendedCodetext":
      _value = data;
      break;
    default:
      throw Exception('Unknown enum value to decode: $data');
  }
}