- java.lang.Object
-
- swim.db.Store
-
- swim.db.FileStore
-
public class FileStore extends Store
-
-
Constructor Summary
Constructors Constructor Description FileStore(File directory, String baseName, Stage stage)
FileStore(File basePath, Stage stage)
FileStore(String basePath, Stage stage)
FileStore(StoreContext context, File directory, String baseName, Stage stage)
FileStore(StoreContext context, File basePath, Stage stage)
FileStore(StoreContext context, String basePath, Stage stage)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
baseName()
void
close()
void
closeAsync(Cont<Store> cont)
void
commitAsync(Commit commit)
void
compactAsync(Compact compact)
Database
database()
boolean
delete()
File
directory()
boolean
isCommitting()
boolean
isCompacting()
FileStore
open()
void
openAsync(Cont<Store> cont)
void
openDatabaseAsync(Cont<Database> cont)
PageLoader
openPageLoader(TreeDelegate treeDelegate, boolean isResident)
FileZone
openZone(int zoneId)
void
openZoneAsync(int zoneId, Cont<Zone> cont)
HashGenCacheSet<Page>
pageCache()
FileZone
shiftZone()
long
size()
Stage
stage()
StoreContext
storeContext()
FileZone
zone()
FileZone
zone(int zoneId)
protected File
zoneFile(int zone)
String
zoneFileExt()
protected TreeMap<Integer,File>
zoneFiles()
-
Methods inherited from class swim.db.Store
openDatabase, settings
-
-
-
-
Constructor Detail
-
FileStore
public FileStore(StoreContext context, File directory, String baseName, Stage stage)
-
FileStore
public FileStore(StoreContext context, File basePath, Stage stage)
-
FileStore
public FileStore(StoreContext context, String basePath, Stage stage)
-
-
Method Detail
-
storeContext
public final StoreContext storeContext()
- Specified by:
storeContext
in classStore
-
directory
public final File directory()
-
baseName
public final String baseName()
-
zoneFileExt
public final String zoneFileExt()
-
pageCache
public final HashGenCacheSet<Page> pageCache()
-
isCommitting
public final boolean isCommitting()
- Specified by:
isCommitting
in classStore
-
isCompacting
public final boolean isCompacting()
- Specified by:
isCompacting
in classStore
-
open
public FileStore open() throws InterruptedException
- Specified by:
open
in classStore
- Throws:
InterruptedException
-
closeAsync
public void closeAsync(Cont<Store> cont)
- Specified by:
closeAsync
in classStore
-
close
public void close() throws InterruptedException
- Specified by:
close
in classStore
- Throws:
InterruptedException
-
delete
public boolean delete()
-
openZoneAsync
public void openZoneAsync(int zoneId, Cont<Zone> cont)
- Specified by:
openZoneAsync
in classStore
-
openZone
public FileZone openZone(int zoneId) throws InterruptedException
- Specified by:
openZone
in classStore
- Throws:
InterruptedException
-
openDatabaseAsync
public void openDatabaseAsync(Cont<Database> cont)
- Specified by:
openDatabaseAsync
in classStore
-
openPageLoader
public PageLoader openPageLoader(TreeDelegate treeDelegate, boolean isResident)
- Specified by:
openPageLoader
in classStore
-
commitAsync
public void commitAsync(Commit commit)
- Specified by:
commitAsync
in classStore
-
compactAsync
public void compactAsync(Compact compact)
- Specified by:
compactAsync
in classStore
-
zoneFile
protected File zoneFile(int zone)
-
-