cleanup: use implicit generic type with diamond operator
This commit is contained in:
@@ -135,7 +135,7 @@ public enum ItemFactory {
|
||||
try (ResultSet rs = ps.executeQuery()) {
|
||||
while (rs.next()) {
|
||||
Integer cid = rs.getInt("characterid");
|
||||
items.add(new Pair<Item, Integer>(loadEquipFromResultSet(rs), cid));
|
||||
items.add(new Pair<>(loadEquipFromResultSet(rs), cid));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -295,7 +295,7 @@ public enum ItemFactory {
|
||||
MapleInventoryType mit = MapleInventoryType.getByType(rs.getByte("inventorytype"));
|
||||
|
||||
if (mit.equals(MapleInventoryType.EQUIP) || mit.equals(MapleInventoryType.EQUIPPED)) {
|
||||
items.add(new Pair<Item, MapleInventoryType>(loadEquipFromResultSet(rs), mit));
|
||||
items.add(new Pair<>(loadEquipFromResultSet(rs), mit));
|
||||
} else {
|
||||
if (bundles > 0) {
|
||||
int petid = rs.getInt("petid");
|
||||
|
||||
@@ -36,8 +36,8 @@ import java.util.Map;
|
||||
*/
|
||||
public class PetDataFactory {
|
||||
private static MapleDataProvider dataRoot = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/Item.wz"));
|
||||
private static Map<String, PetCommand> petCommands = new HashMap<String, PetCommand>();
|
||||
private static Map<Integer, Integer> petHunger = new HashMap<Integer, Integer>();
|
||||
private static Map<String, PetCommand> petCommands = new HashMap<>();
|
||||
private static Map<Integer, Integer> petHunger = new HashMap<>();
|
||||
|
||||
public static PetCommand getPetCommand(int petId, int skillId) {
|
||||
PetCommand ret = petCommands.get(petId + "" + skillId);
|
||||
|
||||
Reference in New Issue
Block a user