public void WriteXml(XmlWriter writer) { writer.WriteStartElement("main_settings"); writer.WriteAttributeIfString(ATTR.skyline_file_path, SkylineFilePath); writer.WriteAttributeIfString(ATTR.folder_to_watch, FolderToWatch); writer.WriteAttribute(ATTR.include_subfolders, IncludeSubfolders); writer.WriteAttributeIfString(ATTR.qc_file_pattern, QcFileFilter.Pattern); writer.WriteAttributeString(ATTR.file_filter_type, QcFileFilter.Name()); writer.WriteAttributeNullable(ATTR.results_window, ResultsWindow); writer.WriteAttributeIfString(ATTR.instrument_type, InstrumentType); writer.WriteAttributeNullable(ATTR.acquisition_time, AcquisitionTime); writer.WriteEndElement(); }
public override string ToString() { var sb = new StringBuilder(); sb.Append("Skyline file: ").AppendLine(SkylineFilePath); sb.Append("Folder to watch: ").AppendLine(FolderToWatch); sb.Append("Include subfolders: ").AppendLine(IncludeSubfolders.ToString()); sb.AppendLine(QcFileFilter.ToString()); sb.Append("Instrument: ").AppendLine(InstrumentType); sb.Append("Results window: ").Append(ResultsWindow.ToString()).AppendLine(" days"); sb.Append("Acquisition time: ").Append(AcquisitionTime.ToString()).AppendLine(" minutes"); return(sb.ToString()); }
public override int GetHashCode() { unchecked { var hashCode = (SkylineFilePath != null ? SkylineFilePath.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (FolderToWatch != null ? FolderToWatch.GetHashCode() : 0); hashCode = (hashCode * 397) ^ IncludeSubfolders.GetHashCode(); hashCode = (hashCode * 397) ^ (QcFileFilter != null ? QcFileFilter.GetHashCode() : 0); hashCode = (hashCode * 397) ^ ResultsWindow; hashCode = (hashCode * 397) ^ (InstrumentType != null ? InstrumentType.GetHashCode() : 0); hashCode = (hashCode * 397) ^ AcquisitionTime; hashCode = (hashCode * 397) ^ LastAcquiredFileDate.GetHashCode(); return(hashCode); } }