public Hash(String hashString){
  if (hashString == null) {
    throw new IllegalArgumentException("hashString must not be null");
  }
  int idx=hashString.indexOf(SEPARATOR);
  if (idx == -1) {
    throw new IllegalArgumentException("hash string must be in the " + "form of '<algorithm id>" + SEPARATOR + "<value>'");
  }
  algoId=hashString.substring(0,idx);
  hashValue=hashString.substring(idx + 1);
  verifyFields();
}

public Hash ( String hashString ) { if ( hashString == null ) { throw new IllegalArgumentException ( "hashString must not be null" ) ; } int idx = hashString . indexOf ( SEPARATOR ) ; if ( idx == - 1 ) { throw new IllegalArgumentException ( "hash string must be in the " + "form of '<algorithm id>" + SEPARATOR + "<value>'" ) ; } algoId = hashString . substring ( 0 , idx ) ; hashValue = hashString . substring ( idx + 1 ) ; verifyFields ( ) ; }
constructs a hash object from a colon - separated hash string .
