/** * true iff model successfully written */ public bool SaveModel(string path) { if (!FileSystemOps.PathIsValid(path)) { return(false); } ImporterOps.ExportModel(path, 1); updateLog(); return(true); }
/** * true iff directory successfully changed */ public bool ChangeCWD(string newPath) { //reset if the address is obviously invalid if (!FileSystemOps.PathIsValid(newPath)) { return(false); } var newCwd = new DirectoryInfo(newPath); if (!newCwd.Exists) { return(false); } //otherwise go to where the address bar is pointing cwd = new DirectoryInfo(newPath); return(true); }