static Directory guessDirectory(GraphStorage store) { if (store.getDirectory() instanceof MMapDirectory) { throw new IllegalStateException("not supported yet: mmap will overwrite existing storage at the same location"); } String location = store.getDirectory().getLocation(); boolean isStoring = ((GHDirectory) store.getDirectory()).isStoring(); return new RAMDirectory(location, isStoring); }
static Directory guessDirectory(GraphStorage store) { String location = store.getDirectory().getLocation(); Directory outdir; if (store.getDirectory() instanceof MMapDirectory) { throw new IllegalStateException("not supported yet: mmap will overwrite existing storage at the same location"); } else { boolean isStoring = ((GHDirectory) store.getDirectory()).isStoring(); outdir = new RAMDirectory(location, isStoring); } return outdir; }
static Directory guessDirectory(GraphStorage store) { if (store.getDirectory() instanceof MMapDirectory) { throw new IllegalStateException("not supported yet: mmap will overwrite existing storage at the same location"); } String location = store.getDirectory().getLocation(); boolean isStoring = ((GHDirectory) store.getDirectory()).isStoring(); return new RAMDirectory(location, isStoring); }
static Directory guessDirectory( GraphStorage store ) { String location = store.getDirectory().getLocation(); Directory outdir; if (store.getDirectory() instanceof MMapDirectory) { throw new IllegalStateException("not supported yet: mmap will overwrite existing storage at the same location"); } else { boolean isStoring = ((GHDirectory) store.getDirectory()).isStoring(); outdir = new RAMDirectory(location, isStoring); } return outdir; }