Search in sources :

Example 1 with NativeLabelScanStoreExtension

use of org.neo4j.kernel.impl.api.scan.NativeLabelScanStoreExtension in project neo4j by neo4j.

the class NeoStoreDataSourceRule method nativeLabelScanStoreProvider.

public static LabelScanStoreProvider nativeLabelScanStoreProvider(File storeDir, FileSystemAbstraction fs, PageCache pageCache, Config config, LogService logService) {
    try {
        Dependencies dependencies = new Dependencies();
        dependencies.satisfyDependencies(pageCache, config, IndexStoreView.EMPTY, logService);
        KernelContext kernelContext = new SimpleKernelContext(storeDir, DatabaseInfo.COMMUNITY, dependencies);
        return (LabelScanStoreProvider) new NativeLabelScanStoreExtension().newInstance(kernelContext, DependenciesProxy.dependencies(dependencies, NativeLabelScanStoreExtension.Dependencies.class));
    } catch (Throwable e) {
        throw launderedException(e);
    }
}
Also used : LabelScanStoreProvider(org.neo4j.kernel.impl.api.scan.LabelScanStoreProvider) SimpleKernelContext(org.neo4j.kernel.impl.spi.SimpleKernelContext) NativeLabelScanStoreExtension(org.neo4j.kernel.impl.api.scan.NativeLabelScanStoreExtension) Dependencies(org.neo4j.kernel.impl.util.Dependencies) SimpleKernelContext(org.neo4j.kernel.impl.spi.SimpleKernelContext) KernelContext(org.neo4j.kernel.impl.spi.KernelContext)

Aggregations

LabelScanStoreProvider (org.neo4j.kernel.impl.api.scan.LabelScanStoreProvider)1 NativeLabelScanStoreExtension (org.neo4j.kernel.impl.api.scan.NativeLabelScanStoreExtension)1 KernelContext (org.neo4j.kernel.impl.spi.KernelContext)1 SimpleKernelContext (org.neo4j.kernel.impl.spi.SimpleKernelContext)1 Dependencies (org.neo4j.kernel.impl.util.Dependencies)1