public static <T> void isEquals( final T argument,
                                     String argumentName,
                                     final T object,
                                     String objectName ) {
        if (argument == null) {
            if (object == null) return;
            // fall through ... one is null
        } else {
            if (argument.equals(object)) return;
            // fall through ... they are not equal
        }
        if (objectName == null) objectName = getObjectName(object);
        throw new IllegalArgumentException(CommonI18n.argumentMustBeEquals.text(argumentName, objectName));
    }
public static < T > void isEquals ( final T argument , String argumentName , final T object , String objectName ) { if ( argument == null ) { if ( object == null ) return ; } else { if ( argument . equals ( object ) ) return ; } if ( objectName == null ) objectName = getObjectName ( object ) ; throw new IllegalArgumentException ( CommonI18n . argumentMustBeEquals . text ( argumentName , objectName ) ) ; }
Asserts that the specified first object is {@link Object#equals(Object) equal to} the specified second object. This method
does take null references into consideration.

@param <T>
@param argument The argument to assert equal to <code>object</code>.
@param argumentName The name that will be used within the exception message for the argument should an exception be thrown
@param object The object to assert as equal to <code>argument</code>.
@param objectName The name that will be used within the exception message for <code>object</code> should an exception be
thrown; if <code>null</code> and <code>object</code> is not <code>null</code>, <code>object.toString()</code> will
be used.
@throws IllegalArgumentException If the specified objects are not equal.