/// <summary> /// Adds the datasource. /// </summary> /// <param name="sourceIndex">Index of the source.</param> /// <param name="sourceSnapshot">The source snapshot.</param> public void AddDatasource(MemoryIndex sourceIndex, Snapshot sourceSnapshot) { MemoryIndexDataSource datasource = new MemoryIndexDataSource(sourceIndex, sourceSnapshot); if (!datasources.Contains(datasource)) { datasources.Add(datasource); } }
/// <inheritdoc /> public override bool Equals(object obj) { if (base.Equals(obj)) { return(true); } MemoryIndexDataSource other = obj as MemoryIndexDataSource; if (other != null) { return(SourceIndex.Equals(other.SourceIndex) && SourceSnapshot.Equals(other.SourceSnapshot)); } else { return(false); } }