You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by kw...@apache.org on 2015/04/11 13:01:33 UTC
svn commit: r1672858 -
/sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java
Author: kwin
Date: Sat Apr 11 11:01:33 2015
New Revision: 1672858
URL: http://svn.apache.org/r1672858
Log:
fix warnings
Modified:
sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java
Modified: sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java?rev=1672858&r1=1672857&r2=1672858&view=diff
==============================================================================
--- sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java (original)
+++ sling/trunk/bundles/extensions/validation/core/src/main/java/org/apache/sling/validation/impl/util/ValidatorTypeUtil.java Sat Apr 11 11:01:33 2015
@@ -42,7 +42,7 @@ public class ValidatorTypeUtil {
type = entry.getValue();
// check if this is really the type argument defined on the interface {@link Validator}
if (entry.getKey().getGenericDeclaration() instanceof Class<?>) {
- Class clazz = (Class)entry.getKey().getGenericDeclaration();
+ Class<?> clazz = (Class<?>)entry.getKey().getGenericDeclaration();
if (clazz.equals(Validator.class)) {
// Java6 doesn't return the class for array types due to this bug: http://bugs.java.com/view_bug.do?bug_id=5041784
if (type instanceof GenericArrayType) {
@@ -50,7 +50,7 @@ public class ValidatorTypeUtil {
type = Array.newInstance((Class<?>) ((GenericArrayType)type).getGenericComponentType(), 0).getClass();
}
if (type instanceof Class<?>) {
- return (Class)type;
+ return (Class<?>)type;
}
// type may also be a parameterized type (e.g. for Collection<String>), this is not allowed!
else {