Use ObjectHelper notNull for parameter assertions instead of manual coded
-------------------------------------------------------------------------
Key: CAMEL-1155
URL: https://issues.apache.org/activemq/browse/CAMEL-1155
Project: Apache Camel
Issue Type: Task
Components: camel-core
Reporter: Claus Ibsen
Priority: Trivial
Fix For: 2.0.0
#1
We should encurage to reuse and use ObjectHelper.notNull for parameter
assertions
Currently we have a few places
{code}
if (paramter == null) {
throw new IllegalArgumentException("parameter is null");
}
{code}
Should be replaced with
{code}
ObjectHelper.notNull(parameter, "parameter");
{code}
#2
We could also consider to add a notEmpty method that will do a not null test
and if the type is a String do a trim size > 0 test as well.
#3
Also we should align the methods to use either *Empty* or *Blank* for such a
test method. Currently we have both combination.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.