mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-12-27 09:00:28 +08:00
Made KillsTable static information class:
- Made KillsTable constructor private - Removed getter in SQLDB
This commit is contained in:
parent
2d5f9254ed
commit
edcd7bd53a
@ -76,7 +76,6 @@ public abstract class SQLDB extends AbstractDatabase {
|
||||
|
||||
private final UsersTable usersTable;
|
||||
private final UserInfoTable userInfoTable;
|
||||
private final KillsTable killsTable;
|
||||
private final SessionsTable sessionsTable;
|
||||
private final TPSTable tpsTable;
|
||||
private final ServerTable serverTable;
|
||||
@ -113,7 +112,6 @@ public abstract class SQLDB extends AbstractDatabase {
|
||||
usersTable = new UsersTable(this);
|
||||
userInfoTable = new UserInfoTable(this);
|
||||
sessionsTable = new SessionsTable(this);
|
||||
killsTable = new KillsTable(this);
|
||||
settingsTable = new SettingsTable(this);
|
||||
|
||||
fetchOps = new SQLFetchOps(this);
|
||||
@ -348,11 +346,6 @@ public abstract class SQLDB extends AbstractDatabase {
|
||||
return sessionsTable;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public KillsTable getKillsTable() {
|
||||
return killsTable;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public TPSTable getTpsTable() {
|
||||
return tpsTable;
|
||||
|
@ -20,7 +20,6 @@ import com.djrapitops.plan.data.container.PlayerKill;
|
||||
import com.djrapitops.plan.data.container.Session;
|
||||
import com.djrapitops.plan.data.store.keys.SessionKeys;
|
||||
import com.djrapitops.plan.db.DBType;
|
||||
import com.djrapitops.plan.db.SQLDB;
|
||||
import com.djrapitops.plan.db.patches.KillsOptimizationPatch;
|
||||
import com.djrapitops.plan.db.patches.KillsServerIDPatch;
|
||||
import com.djrapitops.plan.db.patches.Version10Patch;
|
||||
@ -32,9 +31,7 @@ import java.sql.SQLException;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* Table that is in charge of storing kill data for each session.
|
||||
* <p>
|
||||
* Table Name: plan_kills
|
||||
* Table information about 'plan_kills'.
|
||||
* <p>
|
||||
* Patches related to this table:
|
||||
* {@link Version10Patch}
|
||||
@ -43,7 +40,7 @@ import java.util.UUID;
|
||||
*
|
||||
* @author Rsl1122
|
||||
*/
|
||||
public class KillsTable extends Table {
|
||||
public class KillsTable {
|
||||
|
||||
public static final String TABLE_NAME = "plan_kills";
|
||||
|
||||
@ -64,8 +61,8 @@ public class KillsTable extends Table {
|
||||
+ WEAPON
|
||||
+ ") VALUES (" + SessionsTable.SELECT_SESSION_ID_STATEMENT + ", ?, ?, ?, ?, ?)";
|
||||
|
||||
public KillsTable(SQLDB db) {
|
||||
super(TABLE_NAME, db);
|
||||
private KillsTable() {
|
||||
/* Static information class */
|
||||
}
|
||||
|
||||
public static String createTableSQL(DBType dbType) {
|
||||
|
@ -26,7 +26,6 @@ public class SQLOps {
|
||||
|
||||
protected final UsersTable usersTable;
|
||||
protected final UserInfoTable userInfoTable;
|
||||
protected final KillsTable killsTable;
|
||||
protected final SessionsTable sessionsTable;
|
||||
protected final TPSTable tpsTable;
|
||||
protected final ServerTable serverTable;
|
||||
@ -37,7 +36,6 @@ public class SQLOps {
|
||||
|
||||
usersTable = db.getUsersTable();
|
||||
userInfoTable = db.getUserInfoTable();
|
||||
killsTable = db.getKillsTable();
|
||||
sessionsTable = db.getSessionsTable();
|
||||
tpsTable = db.getTpsTable();
|
||||
serverTable = db.getServerTable();
|
||||
|
Loading…
Reference in New Issue
Block a user