本文整理了Java中org.bukkit.configuration.file.YamlConfiguration.getStringList()
方法的一些代码示例,展示了YamlConfiguration.getStringList()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YamlConfiguration.getStringList()
方法的具体详情如下:
包路径:org.bukkit.configuration.file.YamlConfiguration
类名称:YamlConfiguration
方法名:getStringList
暂无
代码示例来源:origin: com.greatmancode/tools
@Override
public List<String> getStringList(String path) {
return configFile.getStringList(path);
}
}
代码示例来源:origin: DevLeoko/AdvancedBan
@Override
public List<String> getStringList(Object file, String path) {
return ((YamlConfiguration) file).getStringList(path);
}
代码示例来源:origin: BentoBoxWorld/BentoBox
private void updateAuthors(YamlConfiguration yamlConfiguration) {
List<String> list = yamlConfiguration.getStringList("meta.authors");
if (!list.isEmpty()) {
for (String author : list) {
if (!authors.contains(author)) {
authors.add(author);
}
}
}
}
}
代码示例来源:origin: garbagemule/MobArena
private String[] getLines(YamlConfiguration config, String id) {
List<String> list = config.getStringList(id);
if (list.isEmpty()) {
return null;
}
while (list.size() < 4) {
list.add("");
}
if (list.size() > 4) {
list = list.subList(0, 4);
}
return list.toArray(new String[0]);
}
代码示例来源:origin: dzikoysk/WildSkript
protected String[] get(Event event) {
String v = (String) this.value.getSingle(event);
String f = (String) this.file.getSingle(event);
if ((v == null) || (f == null)) {
return null;
}
File file = new File(f.replaceAll("/", Matcher.quoteReplacement(File.separator)));
if (!file.exists()) {
try {
file.getParentFile().mkdirs();
file.createNewFile();
} catch (IOException e) {
}
}
YamlConfiguration yml = YamlConfiguration.loadConfiguration(file);
List<String> list = yml.getStringList(v);
String[] s = new String[list.size()];
return list.toArray(s);
}
代码示例来源:origin: BigScary/GriefPrevention
List<String> builders = yaml.getStringList("Builders");
List<String> containers = yaml.getStringList("Containers");
List<String> accessors = yaml.getStringList("Accessors");
List<String> managers = yaml.getStringList("Managers");
代码示例来源:origin: mcMMO-Dev/mcMMO
for (String memberEntry : partiesFile.getStringList(partyName + ".Members")) {
String[] memberSplit = memberEntry.split("[|]");
members.put(UUID.fromString(memberSplit[0]), memberSplit[1]);
代码示例来源:origin: mcMMO-Dev/mcMMO
for (String memberName : partiesFile.getStringList(partyName + ".Members")) {
PlayerProfile memberProfile = mcMMO.getDatabaseManager().loadPlayerProfile(memberName, false);
代码示例来源:origin: filoghost/HolographicDisplays
for (String singleServer : config.getStringList(ConfigNode.BUNGEE_PINGER_SERVERS.getPath())) {
String[] nameAndAddress = singleServer.split(":", 2);
if (nameAndAddress.length < 2) {
内容来源于网络,如有侵权,请联系作者删除!