mirror of
https://github.com/carm-outsource/TimeReward.git
synced 2024-09-19 19:25:49 +00:00
修改配置文件地址
This commit is contained in:
parent
1d43444080
commit
ffe2c00909
@ -7,13 +7,13 @@ import cc.carm.plugin.timereward.data.RewardContents;
|
|||||||
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
public class PluginConfig {
|
public class PluginConfig {
|
||||||
|
|
||||||
public static final ConfigValue<Boolean> DEBUG = new ConfigValue<>(
|
public static final ConfigValue<Boolean> DEBUG = new ConfigValue<>(
|
||||||
"debug", Boolean.class, false
|
"debug", Boolean.class, false
|
||||||
);
|
);
|
||||||
|
|
||||||
public static final ConfigSectionCast<HashMap<String, RewardContents>> REWARDS = new ConfigSectionCast<>(
|
public static final ConfigSectionCast<HashMap<String, RewardContents>> REWARDS = new ConfigSectionCast<>(
|
||||||
"rewards", TimeRewardAPI.getRewardManager()::readRewards, new LinkedHashMap<>()
|
"rewards", TimeRewardAPI.getRewardManager()::readRewards, new LinkedHashMap<>()
|
||||||
);
|
);
|
||||||
|
@ -5,37 +5,37 @@ import cc.carm.lib.easyplugin.configuration.values.ConfigValue;
|
|||||||
public class DBConfiguration {
|
public class DBConfiguration {
|
||||||
|
|
||||||
protected static final ConfigValue<String> DRIVER_NAME = new ConfigValue<>(
|
protected static final ConfigValue<String> DRIVER_NAME = new ConfigValue<>(
|
||||||
"storage.mysql.driver", String.class,
|
"database.driver", String.class,
|
||||||
"com.mysql.cj.jdbc.Driver"
|
"com.mysql.cj.jdbc.Driver"
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<String> HOST = new ConfigValue<>(
|
protected static final ConfigValue<String> HOST = new ConfigValue<>(
|
||||||
"storage.mysql.host", String.class,
|
"database.host", String.class,
|
||||||
"127.0.0.1"
|
"127.0.0.1"
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<Integer> PORT = new ConfigValue<>(
|
protected static final ConfigValue<Integer> PORT = new ConfigValue<>(
|
||||||
"storage.mysql.port", Integer.class,
|
"database.port", Integer.class,
|
||||||
3306
|
3306
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<String> DATABASE = new ConfigValue<>(
|
protected static final ConfigValue<String> DATABASE = new ConfigValue<>(
|
||||||
"storage.mysql.database", String.class,
|
"database.database", String.class,
|
||||||
"minecraft"
|
"minecraft"
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<String> USERNAME = new ConfigValue<>(
|
protected static final ConfigValue<String> USERNAME = new ConfigValue<>(
|
||||||
"storage.mysql.username", String.class,
|
"database.username", String.class,
|
||||||
"root"
|
"root"
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<String> PASSWORD = new ConfigValue<>(
|
protected static final ConfigValue<String> PASSWORD = new ConfigValue<>(
|
||||||
"storage.mysql.password", String.class,
|
"database.password", String.class,
|
||||||
"password"
|
"password"
|
||||||
);
|
);
|
||||||
|
|
||||||
protected static final ConfigValue<String> ADDITIONAL = new ConfigValue<>(
|
protected static final ConfigValue<String> ADDITIONAL = new ConfigValue<>(
|
||||||
"storage.mysql.additional", String.class,
|
"database.additional", String.class,
|
||||||
"?useSSL=false"
|
"?useSSL=false"
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@ -10,7 +10,6 @@ import cc.carm.plugin.timereward.configuration.PluginMessages;
|
|||||||
public class ConfigManager {
|
public class ConfigManager {
|
||||||
|
|
||||||
private FileConfig pluginConfiguration;
|
private FileConfig pluginConfiguration;
|
||||||
|
|
||||||
private MessagesConfig messageConfiguration;
|
private MessagesConfig messageConfiguration;
|
||||||
|
|
||||||
public boolean initConfig() {
|
public boolean initConfig() {
|
||||||
|
Loading…
Reference in New Issue
Block a user