protected internal override LibraryKeyProto ToLibraryKeyProto() { return(new LibraryKeyProto() { KeyType = LibraryKeyProto.Types.KeyType.PrecursorMz, PrecursorMz = Mz, RetentionTime = RetentionTime.GetValueOrDefault(), }); }
public override string ToString() { var precursor = Mz.ToString(@"0.000", CultureInfo.CurrentCulture); if (!RetentionTime.HasValue) { return(precursor); } var rt = RetentionTime.GetValueOrDefault().ToString(@"0.00", CultureInfo.CurrentCulture); return(string.Format(@"{0} ({1})", precursor, rt)); }