public bool SaveDataSingle(ISaveable saveable) { FileHelper.CreateBackFileDate(_outputFolder, saveable.GetFileName); string outputFileName = Path.Combine(_outputFolder, saveable.GetFileName); IFormatter formatter = new BinaryFormatter(); Stream stream = null; try { stream = StreamFactory.GetStream(outputFileName); if (SaveToStream(stream, formatter, saveable)) { stream.Close(); } else { return(false); } } catch { if (stream != null) { stream.Close(); } return(false); } return(true); }