public void LoadReference(ushort refIndex, Action clearDataSources, PerformanceMetrics metrics = null) { if (refIndex == _currentReferenceIndex) { return; } if (refIndex == ChromosomeRenamer.UnknownReferenceIndex) { clearDataSources(); return; } var referenceData = new ReferenceNameData { ReferenceIndex = refIndex, UcscReferenceName = _compressedSequence.Renamer.UcscReferenceNames[refIndex], EnsemblReferenceName = _compressedSequence.Renamer.EnsemblReferenceNames[refIndex] }; metrics?.StartReference(referenceData.UcscReferenceName); _compressedSequenceReader.GetCompressedSequence(referenceData.EnsemblReferenceName); metrics?.StopReference(); _currentReferenceIndex = refIndex; Changed?.Invoke(this, new NewReferenceEventArgs(referenceData)); }
/// <summary> /// constructor /// </summary> public NewReferenceEventArgs(ReferenceNameData data) { Data = data; }