enjoy 3.6 release ^_^
This commit is contained in:
@@ -73,9 +73,7 @@ public class Field extends Expr {
|
||||
if (fieldGetter.notNull()) {
|
||||
return fieldGetter.get(target, fieldName);
|
||||
}
|
||||
} catch (TemplateException e) {
|
||||
throw e;
|
||||
} catch (ParseException e) {
|
||||
} catch (TemplateException | ParseException e) {
|
||||
throw e;
|
||||
} catch (Exception e) {
|
||||
throw new TemplateException(e.getMessage(), location, e);
|
||||
|
@@ -69,9 +69,9 @@ public class FieldGetters {
|
||||
java.lang.reflect.Method[] methodArray = targetClass.getMethods();
|
||||
for (java.lang.reflect.Method method : methodArray) {
|
||||
if (method.getName().equals(getterName) && method.getParameterTypes().length == 0) {
|
||||
if (MethodKit.isForbiddenMethod(getterName)) {
|
||||
throw new RuntimeException("Forbidden method: " + getterName);
|
||||
}
|
||||
// if (MethodKit.isForbiddenMethod(getterName)) {
|
||||
// throw new RuntimeException("Forbidden method: " + getterName);
|
||||
// }
|
||||
|
||||
return new GetterMethodFieldGetter(method);
|
||||
}
|
||||
|
@@ -88,9 +88,7 @@ public class Method extends Expr {
|
||||
}
|
||||
throw new TemplateException(buildMethodNotFoundSignature("public method not found: " + target.getClass().getName() + ".", methodName, argValues), location);
|
||||
|
||||
} catch (TemplateException e) {
|
||||
throw e;
|
||||
} catch (ParseException e) {
|
||||
} catch (TemplateException | ParseException e) {
|
||||
throw e;
|
||||
} catch (InvocationTargetException e) {
|
||||
Throwable t = e.getTargetException();
|
||||
|
@@ -63,9 +63,7 @@ public class SharedMethod extends Expr {
|
||||
throw new TemplateException(Method.buildMethodNotFoundSignature("Shared method not found: ", methodName, argValues), location);
|
||||
}
|
||||
|
||||
} catch (TemplateException e) {
|
||||
throw e;
|
||||
} catch (ParseException e) {
|
||||
} catch (TemplateException | ParseException e) {
|
||||
throw e;
|
||||
} catch (Exception e) {
|
||||
throw new TemplateException(e.getMessage(), location, e);
|
||||
|
@@ -72,9 +72,7 @@ public class StaticMethod extends Expr {
|
||||
throw new TemplateException(Method.buildMethodNotFoundSignature("public static method not found: " + clazz.getName() + "::", methodName, argValues), location);
|
||||
}
|
||||
|
||||
} catch (TemplateException e) {
|
||||
throw e;
|
||||
} catch (ParseException e) {
|
||||
} catch (TemplateException | ParseException e) {
|
||||
throw e;
|
||||
} catch (Exception e) {
|
||||
throw new TemplateException(e.getMessage(), location, e);
|
||||
|
Reference in New Issue
Block a user