|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.google.appengine.tools.development.testing.LocalRdbmsServiceTestConfig
public class LocalRdbmsServiceTestConfig
Config for accessing the local RDBMS service in tests.
Default behavior is to configure the local service to use an in-memory
database. tearDown()
does not wipe out data or tables.
Constructor Summary | |
---|---|
LocalRdbmsServiceTestConfig()
|
Method Summary | |
---|---|
java.lang.String |
getDriverClass()
|
java.lang.String |
getJdbcConnectionStringFormat()
|
static LocalRdbmsService |
getLocalRdbmsService()
|
LocalRdbmsServiceTestConfig |
setDatabase(java.lang.String database)
Sets the database to be passed to the underlying local JDBC
driver. |
LocalRdbmsServiceTestConfig |
setDriverClass(java.lang.String driverClass)
Sets the class of the driver used by the com.google.appengine.api.rdbms.dev.LocalRdbmsServiceLocalDriver and
attempts to load driverClass in the current ClassLoader . |
LocalRdbmsServiceTestConfig |
setExtraDriverProperties(java.util.Map<java.lang.String,java.lang.String> map)
Sets Extra properties to be passed to the underlying local JDBC
driver. |
LocalRdbmsServiceTestConfig |
setJdbcConnectionStringFormat(java.lang.String jdbcConnectionStringFormat)
Sets the format of the connection string that the jdbc driver will use. |
LocalRdbmsServiceTestConfig |
setPassword(java.lang.String password)
Sets the password to be passed to the underlying local JDBC
driver. |
LocalRdbmsServiceTestConfig |
setRemoteClientFactory(java.lang.Class<? extends SqlClientFactory> remoteClientFactory)
Sets the remote client factory class. |
LocalRdbmsServiceTestConfig |
setServerType(LocalRdbmsService.ServerType serverType)
Sets the server type to either hosted or local . |
void |
setUp()
Set up the local service. |
LocalRdbmsServiceTestConfig |
setUser(java.lang.String user)
Sets the user to be passed to the underlying local JDBC
driver. |
void |
tearDown()
Tear down the local service. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LocalRdbmsServiceTestConfig()
Method Detail |
---|
public void setUp()
LocalServiceTestConfig
setUp
in interface LocalServiceTestConfig
public void tearDown()
LocalServiceTestConfig
tearDown
in interface LocalServiceTestConfig
public static LocalRdbmsService getLocalRdbmsService()
public java.lang.String getDriverClass()
public LocalRdbmsServiceTestConfig setDriverClass(java.lang.String driverClass)
com.google.appengine.api.rdbms.dev.LocalRdbmsServiceLocalDriver
and
attempts to load driverClass
in the current ClassLoader
.
driverClass
- The driver class. Must be the fully-qualified name
of a class that implements java.sql.Driver
.
this
(for chaining)
java.lang.RuntimeException
- wrapping any exceptions loading driverClass.public java.lang.String getJdbcConnectionStringFormat()
public LocalRdbmsServiceTestConfig setJdbcConnectionStringFormat(java.lang.String jdbcConnectionStringFormat)
jdbcConnectionStringFormat
- the connection string format
this
(for chaining)public LocalRdbmsServiceTestConfig setServerType(LocalRdbmsService.ServerType serverType)
hosted
or local
.
local
connections proxy the SQL Service wire format to a local
database using JDBC.
remote
connections talk over a SpeckleRpc
to a hosted
development mode Speckle instance.
serverType
- hosted or local
this
(for chaining)
java.lang.IllegalArgumentException
- if serverType is not "hosted" or "local"public LocalRdbmsServiceTestConfig setExtraDriverProperties(java.util.Map<java.lang.String,java.lang.String> map)
local
JDBC
driver.
map
- the extra driver properties.
this
(for chaining)public LocalRdbmsServiceTestConfig setDatabase(java.lang.String database)
local
JDBC
driver.
public LocalRdbmsServiceTestConfig setUser(java.lang.String user)
local
JDBC
driver.
public LocalRdbmsServiceTestConfig setPassword(java.lang.String password)
local
JDBC
driver.
public LocalRdbmsServiceTestConfig setRemoteClientFactory(java.lang.Class<? extends SqlClientFactory> remoteClientFactory)
remoteClientFactory
- the SqlClientFactory implementation.
this
(for chaining)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |