Sonar fixes
- a few complexities - final method calls from ctor - raw exception throwing - useless overrides - loss of stack trace
This commit is contained in:
committed by
Artem Bilan
parent
7569d0ad79
commit
36c33bb5ab
@@ -611,7 +611,7 @@ public class JpaExecutor implements InitializingBean, BeanFactoryAware {
|
||||
catch (NumberFormatException e) {
|
||||
throw new IllegalArgumentException(
|
||||
"Value " + evaluationResult + " passed as cannot be " +
|
||||
"parsed to a number, expected to be numeric");
|
||||
"parsed to a number, expected to be numeric", e);
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -59,7 +59,7 @@ public class BeanPropertyParameterSource implements ParameterSource {
|
||||
return this.beanWrapper.getPropertyValue(paramName);
|
||||
}
|
||||
catch (NotReadablePropertyException ex) {
|
||||
throw new IllegalArgumentException(ex.getMessage());
|
||||
throw new IllegalArgumentException(ex.getMessage()); // NOSONAR - lost stack trace
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -73,13 +73,13 @@ final class ExpressionEvaluatingParameterSourceUtils {
|
||||
public static class ParameterExpressionEvaluator extends AbstractExpressionEvaluator {
|
||||
|
||||
@Override
|
||||
public StandardEvaluationContext getEvaluationContext() {
|
||||
public StandardEvaluationContext getEvaluationContext() { // NOSONAR - not useless, increases visibility
|
||||
return super.getEvaluationContext();
|
||||
}
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public Object evaluateExpression(Expression expression, Object input) {
|
||||
public Object evaluateExpression(Expression expression, Object input) { // NOSONAR - not useless, increases vis.
|
||||
return super.evaluateExpression(expression, input);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user