public static int intersect(CellRangeAddress crA, CellRangeAddress crB ){int firstRow = crB.getFirstRow();int lastRow  = crB.getLastRow();int firstCol = crB.getFirstColumn();int lastCol  = crB.getLastColumn();if (gt(crA.getFirstRow(),    lastRow) || lt(crA.getLastRow(),    firstRow) ||gt(crA.getFirstColumn(), lastCol) || lt(crA.getLastColumn(), firstCol)){return NO_INTERSECTION;}else if( contains(crA, crB) ){return INSIDE;}else if( contains(crB, crA)){return ENCLOSES;}else{return OVERLAP;}}

public static int intersect ( CellRangeAddress crA , CellRangeAddress crB ) { int firstRow = crB . getFirstRow ( ) ; int lastRow = crB . getLastRow ( ) ; int firstCol = crB . getFirstColumn ( ) ; int lastCol = crB . getLastColumn ( ) ; if ( gt ( crA . getFirstRow ( ) , lastRow ) || lt ( crA . getLastRow ( ) , firstRow ) || gt ( crA . getFirstColumn ( ) , lastCol ) || lt ( crA . getLastColumn ( ) , firstCol ) ) { return NO_INTERSECTION ; } else if ( contains ( crA , crB ) ) { return INSIDE ; } else if ( contains ( crB , crA ) ) { return ENCLOSES ; } else { return OVERLAP ; } }
public static int Intersect(CellRangeAddress crA, CellRangeAddress crB){int firstRow = crB.FirstRow;int lastRow = crB.LastRow;int firstCol = crB.FirstColumn;int lastCol = crB.LastColumn;if(gt(crA.FirstRow, lastRow) ||lt(crA.LastRow, firstRow) ||gt(crA.FirstColumn, lastCol) ||lt(crA.LastColumn, firstCol)){return NO_INTERSECTION;}else if (Contains(crA, crB)){return INSIDE;}else if (Contains(crB, crA)){return ENCLOSES;}else{return OVERLAP;}}
