Package com._1c.g5.v8.xmdb
Class DatabaseBuilder
- java.lang.Object
-
- com._1c.g5.v8.xmdb.DatabaseBuilder
-
public class DatabaseBuilder extends Object
Class to create/load XMDB databases
-
-
Constructor Summary
Constructors Constructor Description DatabaseBuilder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Database
buildDatabase()
Load or create database with current database builder state parametersstatic DatabaseBuilder
getBuilder()
DatabaseBuilder
setCacheNodeSizeRead(int cacheNodeSizeRead)
Set read node cache size (in nodes count)DatabaseBuilder
setCacheNodeSizeWrite(int cacheNodeSizeWrite)
Set write node cache size (in nodes count)DatabaseBuilder
setCacheValueSize(int cacheValueSize)
Set value cache size (in element count)DatabaseBuilder
setFilename(String filename)
Set database location in fsDatabaseBuilder
setInMemory(boolean inMemory)
Set inMemory flag (fit db completelly in memory)DatabaseBuilder
setLazySync(boolean lazySync)
Set lazy sync mode (don't sync after each index list modification)DatabaseBuilder
setObjectBatchBS(int objectBatchBS)
Set block size to batch object writingDatabaseBuilder
setOpenTest(boolean openTest)
Set strict open test modeDatabaseBuilder
setThreadSafe(boolean threadSafe)
Set thread safe flag to database
-
-
-
Method Detail
-
getBuilder
public static DatabaseBuilder getBuilder()
-
setCacheNodeSizeRead
public DatabaseBuilder setCacheNodeSizeRead(int cacheNodeSizeRead)
Set read node cache size (in nodes count)- Parameters:
cacheNodeSizeRead
- read node cache size- Returns:
- current object to chaining
-
setCacheNodeSizeWrite
public DatabaseBuilder setCacheNodeSizeWrite(int cacheNodeSizeWrite)
Set write node cache size (in nodes count)- Parameters:
cacheNodeSizeWrite
- write node cache size- Returns:
- current object to chaining
-
setCacheValueSize
public DatabaseBuilder setCacheValueSize(int cacheValueSize)
Set value cache size (in element count)- Parameters:
cacheValueSize
- value cache size- Returns:
- current object to chaining
-
setFilename
public DatabaseBuilder setFilename(String filename)
Set database location in fs- Parameters:
filename
- database location in fs- Returns:
- current object to chaining
-
setLazySync
public DatabaseBuilder setLazySync(boolean lazySync)
Set lazy sync mode (don't sync after each index list modification)- Parameters:
lazySync
- lazy sync flag- Returns:
- current object to chaining
-
setOpenTest
public DatabaseBuilder setOpenTest(boolean openTest)
Set strict open test mode- Parameters:
openTest
- strict open test flag- Returns:
- current object to chaining
-
setThreadSafe
public DatabaseBuilder setThreadSafe(boolean threadSafe)
Set thread safe flag to database- Parameters:
threadSafe
- thread safe flag- Returns:
- current object to chaining
-
setInMemory
public DatabaseBuilder setInMemory(boolean inMemory)
Set inMemory flag (fit db completelly in memory)- Parameters:
inMemory
-- Returns:
- current object to chaining
-
setObjectBatchBS
public DatabaseBuilder setObjectBatchBS(int objectBatchBS)
Set block size to batch object writing- Parameters:
objectBatchBS
-- Returns:
- current object to chaining
-
buildDatabase
public Database buildDatabase()
Load or create database with current database builder state parameters- Returns:
- database
-
-