internal string Stringify(HashSet <NeoValue> seen) { if (data.Count == 0) { return("{}"); } var builder = new StringBuilder(); builder.Append("{ "); var i = 1; foreach (var mapping in data) { builder.Append(NeoValue.StringifyElement(seen, mapping.Key)); builder.Append(" = "); builder.Append(NeoValue.StringifyElement(seen, mapping.Value)); if (i < data.Count) { builder.Append(", "); } i++; } builder.Append(" }"); return(builder.ToString()); }
internal string Stringify(HashSet <NeoValue> seen) { if (data.Count == 0) { return("[]"); } var builder = new StringBuilder(); builder.Append("[ "); for (var i = 0; i < data.Count; i++) { builder.Append(NeoValue.StringifyElement(seen, data[i])); if (i + 1 < data.Count) { builder.Append(", "); } } builder.Append(" ]"); return(builder.ToString()); }