mirror of
https://github.com/TotalFreedomMC/TFGuilds.git
synced 2024-12-22 07:55:03 +00:00
optimize imports
This commit is contained in:
parent
16cc2c2921
commit
398cef14ec
16 changed files with 35 additions and 60 deletions
|
@ -19,6 +19,8 @@
|
|||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-codec:commons-codec:1.3" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-io:commons-io:1.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.spigotmc:spigot-api:1.16.4-R0.1-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-lang:commons-lang:2.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: com.google.guava:guava:21.0" level="project" />
|
||||
|
@ -26,6 +28,15 @@
|
|||
<orderEntry type="library" scope="PROVIDED" name="Maven: net.md-5:bungeecord-chat:1.16-R0.3" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.yaml:snakeyaml:1.26" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: me.totalfreedom:TotalFreedomMod:2020.11.5" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-io:commons-io:2.8.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.commons:commons-lang3:3.11" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-codec:commons-codec:1.15" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: me.telesphoreo:mojangson:1.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.bstats:bstats-bukkit:1.7" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: io.papermc:paperlib:1.0.5" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: me.rayzr522:jsonmessage:1.0.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.reflections:reflections:0.9.12" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.javassist:javassist:3.27.0-GA" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.maven.plugins:maven-checkstyle-plugin:3.1.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.maven:maven-artifact:3.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.maven:maven-core:3.0" level="project" />
|
||||
|
@ -55,7 +66,6 @@
|
|||
<orderEntry type="library" scope="PROVIDED" name="Maven: xml-apis:xml-apis:1.3.04" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.httpcomponents:httpclient:4.0.2" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.httpcomponents:httpcore:4.0.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-codec:commons-codec:1.3" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-validator:commons-validator:1.3.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-digester:commons-digester:1.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-logging:commons-logging:1.0.4" level="project" />
|
||||
|
@ -75,7 +85,6 @@
|
|||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.struts:struts-taglib:1.3.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.struts:struts-tiles:1.3.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.maven.doxia:doxia-integration-tools:1.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: commons-io:commons-io:1.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: org.codehaus.plexus:plexus-container-default:1.0-alpha-9" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: junit:junit:3.8.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Maven: classworlds:classworlds:1.1-alpha-2" level="project" />
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<project version="4">
|
||||
<component name="CompilerConfiguration">
|
||||
<annotationProcessing>
|
||||
<profile default="true" name="Default" enabled="true" />
|
||||
<profile name="Maven default annotation processors profile" enabled="true">
|
||||
<sourceOutputDir name="target/generated-sources/annotations" />
|
||||
<sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
|
||||
|
|
8
pom.xml
8
pom.xml
|
@ -45,6 +45,14 @@
|
|||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<version>2.3.1</version>
|
||||
<configuration>
|
||||
<outputDirectory>D:\STUFF\116test\plugins</outputDirectory>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
<resources>
|
||||
<resource>
|
||||
|
|
|
@ -14,8 +14,6 @@ import me.totalfreedom.tfguilds.sql.SQLRankData;
|
|||
import me.totalfreedom.tfguilds.sql.SQLUserData;
|
||||
import me.totalfreedom.tfguilds.sql.SQLWorldData;
|
||||
import me.totalfreedom.tfguilds.util.GLog;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.plugin.PluginManager;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
package me.totalfreedom.tfguilds.command;
|
||||
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
import me.totalfreedom.tfguilds.Common;
|
||||
import me.totalfreedom.tfguilds.guild.Guild;
|
||||
import me.totalfreedom.tfguilds.util.GUtil;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
|
@ -12,9 +13,6 @@ import org.bukkit.command.CommandSender;
|
|||
import org.bukkit.command.ConsoleCommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
public class CreateSubcommand extends Common implements CommandExecutor
|
||||
{
|
||||
@Override
|
||||
|
|
|
@ -5,7 +5,6 @@ import me.totalfreedom.tfguilds.guild.Guild;
|
|||
import me.totalfreedom.tfguilds.util.GLog;
|
||||
import me.totalfreedom.tfguilds.util.GUtil;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package me.totalfreedom.tfguilds.command;
|
||||
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
import me.totalfreedom.tfguilds.Common;
|
||||
import me.totalfreedom.tfguilds.guild.Guild;
|
||||
import me.totalfreedom.tfguilds.util.GUtil;
|
||||
|
@ -11,9 +13,6 @@ import org.bukkit.command.CommandSender;
|
|||
import org.bukkit.command.ConsoleCommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
public class RenameSubcommand extends Common implements CommandExecutor
|
||||
{
|
||||
@Override
|
||||
|
|
|
@ -3,7 +3,6 @@ package me.totalfreedom.tfguilds.command;
|
|||
import me.totalfreedom.tfguilds.Common;
|
||||
import me.totalfreedom.tfguilds.guild.Guild;
|
||||
import me.totalfreedom.tfguilds.user.User;
|
||||
import me.totalfreedom.tfguilds.util.GUtil;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.command.Command;
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
package me.totalfreedom.tfguilds.config;
|
||||
|
||||
import java.io.File;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import org.bukkit.configuration.file.YamlConfiguration;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
public class Config extends YamlConfiguration
|
||||
{
|
||||
private final TFGuilds plugin;
|
||||
|
|
|
@ -5,8 +5,8 @@ import java.util.List;
|
|||
import java.util.UUID;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import me.totalfreedom.tfguilds.Common;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import me.totalfreedom.tfguilds.config.ConfigEntry;
|
||||
import me.totalfreedom.tfguilds.util.GLog;
|
||||
import me.totalfreedom.tfguilds.util.GUtil;
|
||||
|
|
|
@ -4,29 +4,28 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.OfflinePlayer;
|
||||
|
||||
public class GuildRank
|
||||
{
|
||||
private static TFGuilds plugin = TFGuilds.getPlugin();
|
||||
private static final TFGuilds plugin = TFGuilds.getPlugin();
|
||||
|
||||
@Getter
|
||||
private String iguild;
|
||||
|
||||
// identifier
|
||||
@Getter
|
||||
private String identifier;
|
||||
private final String identifier;
|
||||
|
||||
// name
|
||||
@Getter
|
||||
private String name;
|
||||
private final String name;
|
||||
|
||||
// members of this rank
|
||||
@Getter
|
||||
private List<UUID> members;
|
||||
private final List<UUID> members;
|
||||
|
||||
public GuildRank(String iguild, String identifier, String name, List<UUID> members)
|
||||
{
|
||||
|
|
|
@ -12,8 +12,7 @@ public class SQLDatabase
|
|||
private static final String DATABASE_FILENAME = "database.db";
|
||||
private static final TFGuilds plugin = TFGuilds.getPlugin();
|
||||
|
||||
private File file;
|
||||
private Connection connection;
|
||||
private final File file;
|
||||
|
||||
public SQLDatabase()
|
||||
{
|
||||
|
|
|
@ -5,7 +5,6 @@ import java.sql.PreparedStatement;
|
|||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
|
@ -74,7 +73,7 @@ public class SQLGuildData
|
|||
List<GuildRank> ranks = new ArrayList<>();
|
||||
if (set.getString("ranks") != null)
|
||||
{
|
||||
for (String rankString : Arrays.asList(set.getString("ranks").split(",")))
|
||||
for (String rankString : set.getString("ranks").split(","))
|
||||
ranks.add(plugin.rankData.get(identifier, rankString));
|
||||
}
|
||||
String motd = set.getString("motd");
|
||||
|
@ -121,21 +120,6 @@ public class SQLGuildData
|
|||
return null;
|
||||
}
|
||||
|
||||
/*
|
||||
Guild guild = new Guild(identifier,
|
||||
name,
|
||||
owner.getName(),
|
||||
Collections.singletonList(owner.getName()),
|
||||
new ArrayList<>(),
|
||||
ChatColor.DARK_GRAY + "[" + ChatColor.GRAY + name + ChatColor.DARK_GRAY + "]",
|
||||
GuildState.INVITE_ONLY,
|
||||
new ArrayList<>(),
|
||||
null,
|
||||
null,
|
||||
System.currentTimeMillis(),
|
||||
null);
|
||||
*/
|
||||
|
||||
public Guild create(String identifier, String name, Player owner)
|
||||
{
|
||||
try (Connection connection = plugin.sql.getConnection())
|
||||
|
|
|
@ -5,16 +5,11 @@ import java.sql.PreparedStatement;
|
|||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import me.totalfreedom.tfguilds.guild.Guild;
|
||||
import me.totalfreedom.tfguilds.guild.GuildRank;
|
||||
import me.totalfreedom.tfguilds.guild.GuildState;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
public class SQLRankData
|
||||
{
|
||||
|
|
|
@ -4,20 +4,9 @@ import java.sql.Connection;
|
|||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import me.totalfreedom.tfguilds.guild.Guild;
|
||||
import me.totalfreedom.tfguilds.guild.GuildRank;
|
||||
import me.totalfreedom.tfguilds.guild.GuildState;
|
||||
import me.totalfreedom.tfguilds.user.User;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
public class SQLUserData
|
||||
{
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
package me.totalfreedom.tfguilds.sql;
|
||||
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.World;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import me.totalfreedom.tfguilds.TFGuilds;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.World;
|
||||
|
||||
public class SQLWorldData
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue