public void Add(DataSourceInfo dataSource, ServerDataSourceSettings serverDatasourceSettings)
        {
            string originalName = dataSource.OriginalName;

            Global.Tracer.Assert(this.m_collection[originalName] == null, "Collection already contains this data source.");
            dataSource.ThrowIfNotUsable(serverDatasourceSettings);
            this.m_collection.Add(originalName, dataSource);
            if (dataSource.NeedPrompt)
            {
                this.m_needPrompt = true;
            }
        }
 public void AddSingleIfPrompt(DataSourceInfo dataSource, ServerDataSourceSettings serverDatasourceSettings)
 {
     Global.Tracer.Assert(dataSource.OriginalName == null, "Data source has non-null name when adding single");
     if (this.m_collection.Count != 0)
     {
         throw new InternalCatalogException("Prompt collection is not empty when adding single data source");
     }
     if (dataSource.CredentialsRetrieval == DataSourceInfo.CredentialsRetrievalOption.Prompt)
     {
         dataSource.ThrowIfNotUsable(serverDatasourceSettings);
         this.m_collection.Add("", dataSource);
         if (dataSource.NeedPrompt)
         {
             this.m_needPrompt = true;
         }
     }
 }