Example #1
0
        public Index(IIndexRepository repository)
            : base(false, null)
        {
            Guard.NotNull(repository, nameof(repository));

            this.repository = repository;
            this.dbreeze    = repository.GetDbreezeEngine();
        }
Example #2
0
        public Index(IIndexRepository repository, string name, bool multiValue, string builder, string[] dependencies = null)
            : base(multiValue, builder, dependencies)
        {
            Guard.NotNull(repository, nameof(repository));

            this.repository = repository;
            this.dbreeze    = repository.GetDbreezeEngine();
            this.Name       = name;
            this.Table      = repository.GetIndexTableName(name);

            try
            {
                this.Compile();
            }
            catch (Exception e)
            {
                throw new IndexStoreException("Could not compile index '" + name + "': " + e.Message);
            }
        }