src/main/java/com/mxgraph/swing/handler/mxConnectionHandler.java
public String validateConnection(Object source, Object target)
	{
		if (target == null && createTarget)
		{
			return null;
		}

		if (!isValidTarget(target))
		{
			return "";
		}

		return graphComponent.getGraph().getEdgeValidationError(
				connectPreview.getPreviewState().getCell(), source, target);
	}
/**
	 * Returns the error message or an empty string if the connection for the
	 * given source target pair is not valid. Otherwise it returns null.
	 */
Returns the error message or an empty string if the connection for the
given source target pair is not valid. Otherwise it returns null.
Returns the error message or an empty string if the connection for the given source target pair is not valid . Otherwise it returns null .
public String validateConnection(Object source, Object target)
	{
		if (target == null && createTarget)
		{
			return null;
		}
		if (!isValidTarget(target))
		{
			return "";
		}
		return graphComponent.getGraph().getEdgeValidationError(
				connectPreview.getPreviewState().getCell(), source, target);
	}
public String validateConnection ( Object source , Object target ) { if ( target == null && createTarget ) { return null ; } if ( ! isValidTarget ( target ) ) { return "" ; } return graphComponent . getGraph ( ) . getEdgeValidationError ( connectPreview . getPreviewState ( ) . getCell ( ) , source , target ) ; }
Returns the error message or an empty string if the connection for the
 given source target pair is not valid.
Returns the error message or an empty string if the connection for the given source target pair is not valid .