public ElasticDbConnection(ElasticDbConnectionstring connectionstring, IEnumerable<Type> resultParsers)
        {
            foreach (var parser in resultParsers)
            {
                if (typeof(IResultParser).IsAssignableFrom(parser) == false)
                {
                    throw new ArgumentException($"Resultparser {parser.GetType().FullName} does not implement IResultParser");
                }
            }

            if (connectionstring == null)
            {
                throw new ArgumentNullException(nameof(connectionstring));
            }

            ElasticDbConnectionstring = connectionstring;
            ResultParserTypes = resultParsers;
        }
 public ElasticDbConnection(ElasticDbConnectionstring connectionstring)
     :this(connectionstring, new[] { typeof(HitsParser) })
 {
 }