public SearchClient(SearchConfig config)
        {
            Config = config;

            Engines = GetAllEngines()
                      .Where(e => Config.SearchEngines.HasFlag(e.Engine))
                      .ToArray();

            if (!Engines.Any())
            {
                throw new ArgumentException("No engines specified");
            }


            Results = new();
        }
Exemple #2
0
        public SearchClient(SearchConfig config)
        {
            Config = config;


            //Engines = GetAllEngines()
            //	.Where(e => Config.SearchEngines.HasFlag(e.Engine))
            //	.ToArray();

            //if (!Engines.Any()) {
            //	throw new SmartImageException("No engines specified");
            //}


            Results = new List <SearchResult>();
        }