mirror of
https://github.com/dmulloy2/ProtocolLib.git
synced 2024-11-27 21:26:17 +01:00
Continue to remove unnecessary raw types.
This commit is contained in:
parent
450fbd8e8d
commit
cc3441dfeb
@ -155,7 +155,6 @@ public class BukkitConverters {
|
||||
return null;
|
||||
|
||||
return getIgnoreNull(new EquivalentConverter<WorldType>() {
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public Object getGeneric(Class<?> genericType, WorldType specific) {
|
||||
try {
|
||||
@ -169,8 +168,7 @@ public class BukkitConverters {
|
||||
throw new FieldAccessException("Cannot find the WorldType.getType() method.", e);
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
|
||||
@Override
|
||||
public WorldType getSpecific(Object generic) {
|
||||
try {
|
||||
|
@ -133,7 +133,6 @@ public class ChunkPosition {
|
||||
*/
|
||||
public static EquivalentConverter<ChunkPosition> getConverter() {
|
||||
return new EquivalentConverter<ChunkPosition>() {
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public Object getGeneric(Class<?> genericType, ChunkPosition specific) {
|
||||
if (chunkPositionConstructor == null) {
|
||||
|
@ -49,7 +49,6 @@ public class WrappedWatchableObject {
|
||||
* @param index - the index.
|
||||
* @param value - non-null value of specific types.
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public WrappedWatchableObject(int index, Object value) {
|
||||
if (value == null)
|
||||
throw new IllegalArgumentException("Value cannot be NULL.");
|
||||
@ -296,8 +295,8 @@ public class WrappedWatchableObject {
|
||||
* @throws FieldAccessException If we're unable to use reflection.
|
||||
*/
|
||||
public WrappedWatchableObject deepClone() throws FieldAccessException {
|
||||
@SuppressWarnings("unchecked")
|
||||
WrappedWatchableObject clone = new WrappedWatchableObject(DefaultInstances.DEFAULT.getDefault(MinecraftReflection.getWatchableObjectClass()));
|
||||
WrappedWatchableObject clone = new WrappedWatchableObject(
|
||||
DefaultInstances.DEFAULT.getDefault(MinecraftReflection.getWatchableObjectClass()));
|
||||
|
||||
clone.setDirtyState(getDirtyState());
|
||||
clone.setIndex(getIndex());
|
||||
|
Loading…
Reference in New Issue
Block a user