public void Save(string path, GraphViewModel item) { if (item == null) { throw new ArgumentNullException(nameof(item)); } var csv = item.ToCsv(); File.WriteAllLines(path, csv); }
public void SaveToClipboard(GraphViewModel item) { if (item == null) { throw new ArgumentNullException(nameof(item)); } var csv = item.ToCsv(); var text = string.Join(Environment.NewLine, csv); Clipboard.SetText(text); }