Made each DatabaseConnectors's constructors package-private

This commit is contained in:
Florian CUNY 2018-10-29 20:55:18 +01:00
parent bf506a49b2
commit 5b97d16a2d
4 changed files with 4 additions and 5 deletions

View File

@ -13,7 +13,7 @@ public class JSONDatabaseConnector implements DatabaseConnector {
private static final String JSON = ".json";
private final File dataFolder;
public JSONDatabaseConnector(BentoBox plugin) {
JSONDatabaseConnector(BentoBox plugin) {
dataFolder = new File(plugin.getDataFolder(), DATABASE_FOLDER_NAME);
}

View File

@ -18,7 +18,7 @@ public class MongoDBDatabaseConnector implements DatabaseConnector {
* Class for MySQL database connections using the settings provided
* @param dbSettings - database settings
*/
public MongoDBDatabaseConnector(DatabaseConnectionSettingsImpl dbSettings) {
MongoDBDatabaseConnector(DatabaseConnectionSettingsImpl dbSettings) {
this.dbSettings = dbSettings;
MongoCredential credential = MongoCredential.createCredential(dbSettings.getUsername(),
dbSettings.getDatabaseName(),

View File

@ -19,7 +19,7 @@ public class MySQLDatabaseConnector implements DatabaseConnector {
* Class for MySQL database connections using the settings provided
* @param dbSettings - database settings
*/
public MySQLDatabaseConnector(DatabaseConnectionSettingsImpl dbSettings) {
MySQLDatabaseConnector(DatabaseConnectionSettingsImpl dbSettings) {
this.dbSettings = dbSettings;
try {
Class.forName("com.mysql.jdbc.Driver").getDeclaredConstructor().newInstance();

View File

@ -29,8 +29,7 @@ public class YamlDatabaseConnector implements DatabaseConnector {
private final BentoBox plugin;
private final File dataFolder;
public YamlDatabaseConnector(BentoBox plugin) {
YamlDatabaseConnector(BentoBox plugin) {
this.plugin = plugin;
dataFolder = new File(plugin.getDataFolder(), DATABASE_FOLDER_NAME);
}