fromJson method

  1. @override
TextAlignVertical? fromJson(
  1. String? json
)

Implementation

@override
TextAlignVertical? fromJson(String? json) {
  if (json == null) return null;

  switch (json) {
    case 'bottom':
      return TextAlignVertical.bottom;

    case 'center':
      return TextAlignVertical.center;

    case 'top':
      return TextAlignVertical.top;
  }

  throw 'Unsuported_Json_Value';
}