public static History fromConfig(ConfigurationSection configurationSection) throws InvalidConfigurationException {
if (configurationSection == null) {
return null;
}
if (!configurationSection.contains("HistoryEvents")) {
throw new InvalidConfigurationException();
}
History history = new History();
List<String> list;
list = configurationSection.getStringList("HistoryEvents");
if (list != null && !list.isEmpty()) {
for (String line : list) {
history.addHistoryEvent(new HistoryEvent(line));
}
}
return history;
}
History.java 文件源码
java
阅读 63
收藏 0
点赞 0
评论 0
项目:QuestManager
作者:
评论列表
文章目录