public ValidationResult isFullyQualifiedHost(String host,Map props,IStateAccess state){
  ValidationResultStatus validRes=ValidationResultStatus.STATUS_FAILED;
  LocalizedMessage returnMessage=null;
  if ((host != null) && (host.length() > 0)) {
    if ((!host.startsWith(".")) && (!host.endsWith("."))) {
      StringTokenizer tokens=new StringTokenizer(host,".");
      if (tokens.countTokens() >= 3) {
        validRes=ValidationResultStatus.STATUS_SUCCESS;
      }
    }
  }
  if (validRes.getIntValue() == ValidationResultStatus.INT_STATUS_FAILED) {
    returnMessage=LocalizedMessage.get(LOC_VA_WRN_IN_VAL_FULLY_QUAL_HOST,new Object[]{host});
  }
  Debug.log("NetworkValidator : Is Host name : " + host + " fully "+ "qualified ? "+ validRes.isSuccessful());
  return new ValidationResult(validRes,null,returnMessage);
}

public ValidationResult isFullyQualifiedHost ( String host , Map props , IStateAccess state ) { ValidationResultStatus validRes = ValidationResultStatus . STATUS_FAILED ; LocalizedMessage returnMessage = null ; if ( ( host != null ) && ( host . length ( ) > 0 ) ) { if ( ( ! host . startsWith ( "." ) ) && ( ! host . endsWith ( "." ) ) ) { StringTokenizer tokens = new StringTokenizer ( host , "." ) ; if ( tokens . countTokens ( ) >= 3 ) { validRes = ValidationResultStatus . STATUS_SUCCESS ; } } } if ( validRes . getIntValue ( ) == ValidationResultStatus . INT_STATUS_FAILED ) { returnMessage = LocalizedMessage . get ( LOC_VA_WRN_IN_VAL_FULLY_QUAL_HOST , new Object [ ] { host } ) ; } Debug . log ( "NetworkValidator : Is Host name : " + host + " fully " + "qualified ? " + validRes . isSuccessful ( ) ) ; return new ValidationResult ( validRes , null , returnMessage ) ; }
checks whether the host name is fully qualified
