aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/core/util/reflect
diff options
context:
space:
mode:
authorDraknyte1 <Draknyte1@hotmail.com>2017-08-24 18:47:40 +1000
committerDraknyte1 <Draknyte1@hotmail.com>2017-08-24 18:47:40 +1000
commit9532786295e39c639ae40fcdaa90e5b9faf1a73f (patch)
tree749497fd09aab181b17687737ebcc2a3717202ad /src/Java/gtPlusPlus/core/util/reflect
parent7573ee56c6d8ee08319ef17ca28b46efcc5c6ed1 (diff)
parent4928538ba331e835cbe640c36d1324f375282629 (diff)
downloadGT5-Unofficial-9532786295e39c639ae40fcdaa90e5b9faf1a73f.tar.gz
GT5-Unofficial-9532786295e39c639ae40fcdaa90e5b9faf1a73f.tar.bz2
GT5-Unofficial-9532786295e39c639ae40fcdaa90e5b9faf1a73f.zip
Merge branch 'master' of https://github.com/draknyte1/GTplusplus
Diffstat (limited to 'src/Java/gtPlusPlus/core/util/reflect')
-rw-r--r--src/Java/gtPlusPlus/core/util/reflect/ClientProxyFinder.java2
-rw-r--r--src/Java/gtPlusPlus/core/util/reflect/ReflectionUtils.java4
-rw-r--r--src/Java/gtPlusPlus/core/util/reflect/ServerProxyFinder.java2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/Java/gtPlusPlus/core/util/reflect/ClientProxyFinder.java b/src/Java/gtPlusPlus/core/util/reflect/ClientProxyFinder.java
index c1d0279f72..99a9bf2fa9 100644
--- a/src/Java/gtPlusPlus/core/util/reflect/ClientProxyFinder.java
+++ b/src/Java/gtPlusPlus/core/util/reflect/ClientProxyFinder.java
@@ -12,7 +12,7 @@ public class ClientProxyFinder {
final SidedProxy sidedProxy = field.getAnnotation(SidedProxy.class);
final Object fieldValue = field.get(modInstance);
try {
- final Class clientSideClass = Class.forName(sidedProxy.clientSide());
+ final Class<?> clientSideClass = Class.forName(sidedProxy.clientSide());
if(clientSideClass.isAssignableFrom(fieldValue.getClass())) {
final Object clientProxy = clientSideClass.cast(fieldValue);
//do what you want with client proxy instance
diff --git a/src/Java/gtPlusPlus/core/util/reflect/ReflectionUtils.java b/src/Java/gtPlusPlus/core/util/reflect/ReflectionUtils.java
index c789871b6f..f88f8e32e0 100644
--- a/src/Java/gtPlusPlus/core/util/reflect/ReflectionUtils.java
+++ b/src/Java/gtPlusPlus/core/util/reflect/ReflectionUtils.java
@@ -102,7 +102,7 @@ public class ReflectionUtils {
/**
* Allows to change the state of an immutable instance. Huh?!?
*/
- public static void setFieldValue(Class clazz, String fieldName, Object newValue) throws Exception {
+ public static void setFieldValue(Class<?> clazz, String fieldName, Object newValue) throws Exception {
Field nameField = getField(clazz, fieldName);
setValue(clazz, nameField, newValue);
}
@@ -110,7 +110,7 @@ public class ReflectionUtils {
/**
* Allows to change the state of final statics. Huh?!?
*/
- public static void setDefault(Class clazz, String fieldName, Object newValue) throws Exception {
+ public static void setDefault(Class<?> clazz, String fieldName, Object newValue) throws Exception {
Field staticField = clazz.getDeclaredField(fieldName);
setValue(null, staticField, newValue);
}
diff --git a/src/Java/gtPlusPlus/core/util/reflect/ServerProxyFinder.java b/src/Java/gtPlusPlus/core/util/reflect/ServerProxyFinder.java
index 2fae02a9fd..38382b4a46 100644
--- a/src/Java/gtPlusPlus/core/util/reflect/ServerProxyFinder.java
+++ b/src/Java/gtPlusPlus/core/util/reflect/ServerProxyFinder.java
@@ -12,7 +12,7 @@ public class ServerProxyFinder {
final SidedProxy sidedProxy = field.getAnnotation(SidedProxy.class);
final Object fieldValue = field.get(modInstance);
try {
- final Class serverSideClass = Class.forName(sidedProxy.serverSide());
+ final Class<?> serverSideClass = Class.forName(sidedProxy.serverSide());
if(serverSideClass.isAssignableFrom(fieldValue.getClass())) {
final Object serverProxy = serverSideClass.cast(fieldValue);
//do what you want with server proxy instance