Beispiel #1
0
 public MongoFhirIndex(MongoIndexStore store, Definitions definitions)
 {
     this.definitions = definitions;
     this.indexStore  = store;
     this.indexer     = new MongoIndexer(store, definitions);
     this.searcher    = new MongoSearcher(store.Collection);
 }
Beispiel #2
0
        public static FhirIndex CreateIndex()
        {
            MongoDatabase database = MongoDbConnector.Database;
            MongoCollection <BsonDocument> collection = database.GetCollection(Spark.Search.Config.MONGOINDEXCOLLECTION);

            Definitions definitions = DefinitionsFactory.GenerateFromMetadata();
            ISearcher   searcher    = new MongoSearcher(collection);
            IIndexer    indexer     = new MongoIndexer(collection, definitions);

            FhirIndex index = new FhirIndex(definitions, indexer, searcher);

            return(index);
        }
Beispiel #3
0
 public MongoFhirIndex(MongoIndexStore indexStore, MongoIndexer indexer, MongoSearcher searcher)
 {
     _indexStore = indexStore;
     _indexer    = indexer;
     _searcher   = searcher;
 }
Beispiel #4
0
 public MongoFhirIndex(IIndexStore indexStore, MongoSearcher searcher, SparkSettings sparkSettings = null)
 {
     _indexStore     = indexStore;
     _searcher       = searcher;
     _searchSettings = sparkSettings?.Search ?? new SearchSettings();
 }