Пример #1
0
        /// <summary>
        /// Create an object using the contents of the corresponding MzIdentML object
        /// </summary>
        /// <param name="ad"></param>
        /// <param name="idata"></param>
        public AnalysisDataObj(AnalysisDataType ad, IdentDataObj idata)
            : base(idata)
        {
            SpectrumIdentificationList = new IdentDataList <SpectrumIdentificationListObj>(1);
            _proteinDetectionList      = null;

            if (ad.SpectrumIdentificationList?.Count > 0)
            {
                SpectrumIdentificationList.AddRange(ad.SpectrumIdentificationList, sil => new SpectrumIdentificationListObj(sil, IdentData));
            }
            if (ad.ProteinDetectionList != null)
            {
                _proteinDetectionList = new ProteinDetectionListObj(ad.ProteinDetectionList, IdentData);
            }
        }
Пример #2
0
        /// <summary>
        ///     Create an object using the contents of the corresponding MzIdentML object
        /// </summary>
        /// <param name="ad"></param>
        /// <param name="idata"></param>
        public AnalysisDataObj(AnalysisDataType ad, IdentDataObj idata)
            : base(idata)
        {
            _spectrumIdentificationList = null;
            _proteinDetectionList       = null;

            if (ad.SpectrumIdentificationList != null && ad.SpectrumIdentificationList.Count > 0)
            {
                SpectrumIdentificationList = new IdentDataList <SpectrumIdentificationListObj>();
                foreach (var sil in ad.SpectrumIdentificationList)
                {
                    SpectrumIdentificationList.Add(new SpectrumIdentificationListObj(sil, IdentData));
                }
            }
            if (ad.ProteinDetectionList != null)
            {
                _proteinDetectionList = new ProteinDetectionListObj(ad.ProteinDetectionList, IdentData);
            }
        }