Cleaned up some code

This commit is contained in:
mathias 2021-08-19 17:11:38 +02:00
parent e8544ff761
commit 264d33db4f
No known key found for this signature in database
GPG Key ID: 8950DF62139C852A
5 changed files with 7 additions and 4 deletions

View File

@ -23,12 +23,11 @@ public class MySQLConnection {
private final String username; private final String username;
private final String password; private final String password;
private final String database; private final String database;
private final TableFactory tableFactory = new TableFactory(this);
private String tablePrefix = ""; private String tablePrefix = "";
private String tablePrefixVariable = ""; private String tablePrefixVariable = "";
private String connectString = ""; private String connectString = "";
private Connection con; private Connection con;
private final TableFactory tableFactory = new TableFactory(this);
/** /**
* Basic constructor for the connection * Basic constructor for the connection

View File

@ -8,8 +8,8 @@ import java.util.concurrent.atomic.AtomicBoolean;
public class InsertManager { public class InsertManager {
private final MySQLConnection connection; private final MySQLConnection connection;
private String tableName;
private final HashMap<String, Object> values; private final HashMap<String, Object> values;
private String tableName;
/** /**
* Basic constructor for the InsertManager * Basic constructor for the InsertManager

View File

@ -130,6 +130,7 @@ public class ResultManager {
/** /**
* Checks if the current result exists * Checks if the current result exists
*
* @return <code>true</code> if the current result exists, otherwise <code>false</code> * @return <code>true</code> if the current result exists, otherwise <code>false</code>
*/ */
public boolean exists() { public boolean exists() {

View File

@ -13,9 +13,9 @@ public class UpdateManager {
private final Logger LOG = MySQLConnection.LOG; private final Logger LOG = MySQLConnection.LOG;
private final MySQLConnection connection; private final MySQLConnection connection;
private String tableName;
private final HashMap<String, Object> whereList; private final HashMap<String, Object> whereList;
private final HashMap<String, Object> setList; private final HashMap<String, Object> setList;
private String tableName;
/** /**
* Basic constructor for the UpdateManager * Basic constructor for the UpdateManager

View File

@ -118,6 +118,7 @@ public abstract class SQLTable {
/** /**
* Gets the database selection from the current the table * Gets the database selection from the current the table
*
* @return the database selection * @return the database selection
*/ */
public DataBaseSelection select() { public DataBaseSelection select() {
@ -126,6 +127,7 @@ public abstract class SQLTable {
/** /**
* Gets the update manager of the current table * Gets the update manager of the current table
*
* @return the update manager * @return the update manager
*/ */
public UpdateManager update() { public UpdateManager update() {
@ -134,6 +136,7 @@ public abstract class SQLTable {
/** /**
* Gets the insert manager of the current table * Gets the insert manager of the current table
*
* @return the insert manager * @return the insert manager
*/ */
public InsertManager insert() { public InsertManager insert() {