public class MySqlJdbcContext extends Object implements AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
protected Configuration |
config |
protected static JdbcConnection.ConnectionFactory |
FACTORY |
protected JdbcConnection |
jdbc |
protected org.slf4j.Logger |
logger |
protected static String |
MYSQL_CONNECTION_URL |
private Map<String,String> |
originalSystemProperties |
| Constructor and Description |
|---|
MySqlJdbcContext(Configuration config) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
Configuration |
config() |
protected String |
connectionString() |
String |
hostname() |
JdbcConnection |
jdbc() |
org.slf4j.Logger |
logger() |
String |
password() |
int |
port() |
protected Map<String,String> |
readMySqlCharsetSystemVariables(AtomicReference<String> sql)
Read the MySQL charset-related system variables.
|
protected String |
setStatementFor(Map<String,String> variables) |
protected void |
setSystemProperty(String property,
Field field,
boolean showValueInError) |
void |
shutdown() |
MySqlConnectorConfig.SecureConnectionMode |
sslMode() |
boolean |
sslModeEnabled() |
void |
start() |
String |
username() |
protected static final String MYSQL_CONNECTION_URL
protected static JdbcConnection.ConnectionFactory FACTORY
protected final org.slf4j.Logger logger
protected final Configuration config
protected final JdbcConnection jdbc
public MySqlJdbcContext(Configuration config)
public Configuration config()
public JdbcConnection jdbc()
public org.slf4j.Logger logger()
public String username()
public String password()
public String hostname()
public int port()
public MySqlConnectorConfig.SecureConnectionMode sslMode()
public boolean sslModeEnabled()
public void start()
public void shutdown()
public void close()
close in interface AutoCloseableprotected String connectionString()
protected Map<String,String> readMySqlCharsetSystemVariables(AtomicReference<String> sql)
sql - the reference that should be set to the SQL statement; may be null if not neededCopyright © 2016 JBoss by Red Hat. All rights reserved.