public static String fromByteArray(byte[] ba){
  if ((ba != null) && (ba.length == 16)) {
    StringBuilder result=new StringBuilder(36);
    for (int i=0; i < 16; ++i) {
      if ((i == 4) || (i == 6) || (i == 8)|| (i == 10)) {
        result.append('-');
      }
      result.append(hexChars.charAt(((ba[i] & 0xF0) >>> 4)));
      result.append(hexChars.charAt((ba[i] & 0xF)));
    }
    return result.toString();
  }
  return null;
}

public static String fromByteArray ( byte [ ] ba ) { if ( ( ba != null ) && ( ba . length == 16 ) ) { StringBuilder result = new StringBuilder ( 36 ) ; for ( int i = 0 ; i < 16 ; ++ i ) { if ( ( i == 4 ) || ( i == 6 ) || ( i == 8 ) || ( i == 10 ) ) { result . append ( '-' ) ; } result . append ( hexChars . charAt ( ( ( ba [ i ] & 0xF0 ) > > > 4 ) ) ) ; result . append ( hexChars . charAt ( ( ba [ i ] & 0xF ) ) ) ; } return result . toString ( ) ; } return null ; }
returns a uuid / guid for a given byte array .
