public void Import() { string path = Application.dataPath + "/" + name + ".json"; JSONImportExport jimp = new JSONImportExport(); MathGraph g = (MathGraph)jimp.Import(path); if (g == null) { return; } Clear(); nodes = g.nodes; foreach (Node n in nodes) { n.graph = this; } }
public void Export() { JSONImportExport jep = new JSONImportExport(); jep.Export(this, Application.dataPath + "/" + name + ".json"); }