Class MySqlStorageSupplier<K,V>
- java.lang.Object
-
- me.hsgamer.topper.agent.storage.simple.supplier.SqlStorageSupplier<K,V>
-
- me.hsgamer.topper.agent.storage.simple.supplier.MySqlStorageSupplier<K,V>
-
- All Implemented Interfaces:
DataStorageSupplier<K,V>
public class MySqlStorageSupplier<K,V> extends SqlStorageSupplier<K,V>
-
-
Field Summary
-
Fields inherited from class me.hsgamer.topper.agent.storage.simple.supplier.SqlStorageSupplier
logger
-
-
Constructor Summary
Constructors Constructor Description MySqlStorageSupplier(DatabaseSetting databaseSetting, SqlEntryConverter<K,V> converter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
flushConnection(Connection connection)
protected Connection
getConnection()
protected String
toSaveStatement(String name, String[] keyColumns, String[] valueColumns)
protected Object[]
toSaveValues(Object[] keys, Object[] values)
-
Methods inherited from class me.hsgamer.topper.agent.storage.simple.supplier.SqlStorageSupplier
getStorage
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface me.hsgamer.topper.agent.storage.simple.supplier.DataStorageSupplier
disable, enable
-
-
-
-
Constructor Detail
-
MySqlStorageSupplier
public MySqlStorageSupplier(DatabaseSetting databaseSetting, SqlEntryConverter<K,V> converter)
-
-
Method Detail
-
getConnection
protected Connection getConnection() throws SQLException
- Specified by:
getConnection
in classSqlStorageSupplier<K,V>
- Throws:
SQLException
-
flushConnection
protected void flushConnection(Connection connection)
- Specified by:
flushConnection
in classSqlStorageSupplier<K,V>
-
toSaveStatement
protected String toSaveStatement(String name, String[] keyColumns, String[] valueColumns)
- Specified by:
toSaveStatement
in classSqlStorageSupplier<K,V>
-
toSaveValues
protected Object[] toSaveValues(Object[] keys, Object[] values)
- Specified by:
toSaveValues
in classSqlStorageSupplier<K,V>
-
-