asString property

String? get asString

Implementation

String? get asString {
  if (value is String) {
    return value;
  }

  if (sub != null && sub!.length > 0) {
    for (var item in sub!) {
      var itemAsString = item.asString;
      if (itemAsString != null) {
        return itemAsString;
      }
    }
  }

  return null;
}