Assorted cleanup.

This commit is contained in:
GJ
2014-02-27 10:56:21 -05:00
parent 1d7e034d5e
commit 0056be2d5f
33 changed files with 55 additions and 187 deletions

View File

@ -44,7 +44,7 @@ public interface DatabaseManager {
/**
* Retrieve leaderboard info.
*
* @param skillName The skill to retrieve info on
* @param skill The skill to retrieve info on
* @param pageNumber Which page in the leaderboards to retrieve
* @param statsPerPage The number of stats per page
* @return the requested leaderboard information

View File

@ -814,7 +814,7 @@ public final class FlatfileDatabaseManager implements DatabaseManager {
}
}
private PlayerProfile loadFromLine(String[] character) throws Exception {
private PlayerProfile loadFromLine(String[] character) {
Map<SkillType, Integer> skills = getSkillMapFromLine(character); // Skill levels
Map<SkillType, Float> skillsXp = new HashMap<SkillType, Float>(); // Skill & XP
Map<AbilityType, Integer> skillsDATS = new HashMap<AbilityType, Integer>(); // Ability & Cooldown

View File

@ -799,7 +799,6 @@ public final class SQLDatabaseManager implements DatabaseManager {
}
ResultSet resultSet;
HashMap<Integer, ArrayList<String>> rows = new HashMap<Integer, ArrayList<String>>();
PreparedStatement statement = null;
try {
@ -811,13 +810,7 @@ public final class SQLDatabaseManager implements DatabaseManager {
resultSet = statement.executeQuery();
while (resultSet.next()) {
ArrayList<String> column = new ArrayList<String>();
for (int i = 1; i <= resultSet.getMetaData().getColumnCount(); i++) {
column.add(resultSet.getString(i));
}
rows.put(resultSet.getRow(), column);
// No reason to do anything here... we're just trying to catch exceptions
}
}
catch (SQLException ex) {