com.clarkparsia.stardog
Interface DatabaseBuilder.MemDatabaseBuilder

All Superinterfaces:
DatabaseBuilder
Enclosing interface:
DatabaseBuilder

public static interface DatabaseBuilder.MemDatabaseBuilder
extends DatabaseBuilder

In-Memory database specific builder


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.clarkparsia.stardog.DatabaseBuilder
DatabaseBuilder.DiskDatabaseBuilder, DatabaseBuilder.MemDatabaseBuilder
 
Method Summary
 DatabaseBuilder.MemDatabaseBuilder async()
          If the database is persistent() this specifies that the persistence to disk should be done asynchronously.
 DatabaseBuilder.MemDatabaseBuilder durableTransactions(boolean theDurable)
          Specify whether or not transactions for this database should be durable.
 DatabaseBuilder.MemDatabaseBuilder persistent()
          Specify that this memory database should be persisted to disk when commits are successful.
 DatabaseBuilder.MemDatabaseBuilder reporter(PrintStream theStream)
          Sets the output used to print information messages about
 DatabaseBuilder.MemDatabaseBuilder searchable(boolean theSearchable)
          Specify whether or not the database created by this builder should be searchable via Waldo.
<V> DatabaseBuilder.MemDatabaseBuilder
set(ConfigProperty<V> theOption, V theValue)
          Set the given option on this builder
 DatabaseBuilder.MemDatabaseBuilder sync()
          The opposite of the async() option, persistence of this database will be done inside a commit so that it if fails, the transaction will fail.
 
Methods inherited from interface com.clarkparsia.stardog.DatabaseBuilder
create, create
 

Method Detail

sync

DatabaseBuilder.MemDatabaseBuilder sync()
The opposite of the async() option, persistence of this database will be done inside a commit so that it if fails, the transaction will fail. This is a safer, but slower option for commit persistence in memory databases. This is the default value for memory database persistence.

Returns:
this object

async

DatabaseBuilder.MemDatabaseBuilder async()
If the database is persistent() this specifies that the persistence to disk should be done asynchronously. That is, it is done in a separate thread from the transaction commit. This allows for faster commits since persistence does not take up time in the commit, but makes it possible that the data could be lost or the files on disk corrupted if the transaction fails.

Returns:
this object

persistent

DatabaseBuilder.MemDatabaseBuilder persistent()
Specify that this memory database should be persisted to disk when commits are successful. By default, memory indexes are NOT persistent.

Returns:
this object

durableTransactions

DatabaseBuilder.MemDatabaseBuilder durableTransactions(boolean theDurable)
Description copied from interface: DatabaseBuilder
Specify whether or not transactions for this database should be durable. The default is 'false' -- non-durable transactions.

Specified by:
durableTransactions in interface DatabaseBuilder
Parameters:
theDurable - true for durable transactions, false otherwise.
Returns:
this object.

reporter

DatabaseBuilder.MemDatabaseBuilder reporter(PrintStream theStream)
Description copied from interface: DatabaseBuilder
Sets the output used to print information messages about

Specified by:
reporter in interface DatabaseBuilder
Parameters:
theStream - the output stream to use
Returns:
this object

searchable

DatabaseBuilder.MemDatabaseBuilder searchable(boolean theSearchable)
Description copied from interface: DatabaseBuilder
Specify whether or not the database created by this builder should be searchable via Waldo. The default is 'false' -- search is not automatically enabled for a database.

Specified by:
searchable in interface DatabaseBuilder
Parameters:
theSearchable - true to be searchable, false otherwise
Returns:
this object

set

<V> DatabaseBuilder.MemDatabaseBuilder set(ConfigProperty<V> theOption,
                                           V theValue)
Description copied from interface: DatabaseBuilder
Set the given option on this builder

Specified by:
set in interface DatabaseBuilder
Type Parameters:
V - the option type
Parameters:
theOption - the option to set
theValue - the value
Returns:
this builder object


Copyright © 2010-2013 Clark & Parsia. All Rights Reserved.