public static spec_metadata read_spec_metadata(string url) { FileStream fs = new FileStream(@url, FileMode.Open); BinaryFormatter bf = new BinaryFormatter(); spec_metadata p = bf.Deserialize(fs) as spec_metadata; return(p); }
public static void save_spec_metadat(string url, spec_metadata temp) { FileStream fs = new FileStream(url, FileMode.Create); BinaryFormatter bf = new BinaryFormatter(); bf.Serialize(fs, temp); fs.Close(); }