@ SuppressWarnings ( "unused" ) private static void checkNotTheSame ( byte [ ] bs , byte [ ] bytes ) { if ( bs . length == bytes . length ) { System . out . println ( "same length!" ) ; boolean same = true ; for ( int i = 0 ; i < bs . length ; i ++ ) { if ( bs [ i ] != bytes [ i ] ) { same = false ; break ; } } if ( same ) { System . out . println ( "same data!!" ) ; } else { System . out . println ( "diff data" ) ; } } else { System . out . println ( "different" ) ; } }
method useful when debugging