public static boolean parseStringAsBoolean(String in) throws IndexParseFieldException {
  in=in.trim();
  if (in.equalsIgnoreCase("T")) {
    return true;
  }
 else   if (in.equalsIgnoreCase("TRUE")) {
    return true;
  }
 else   if (in.equalsIgnoreCase("1")) {
    return true;
  }
 else   if (in.equalsIgnoreCase("F")) {
    return false;
  }
 else   if (in.equalsIgnoreCase("FALSE")) {
    return false;
  }
 else   if (in.equalsIgnoreCase("0")) {
    return false;
  }
  throw new IndexParseFieldException(in);
}

public static boolean parseStringAsBoolean ( String in ) throws IndexParseFieldException { in = in . trim ( ) ; if ( in . equalsIgnoreCase ( "T" ) ) { return true ; } else if ( in . equalsIgnoreCase ( "TRUE" ) ) { return true ; } else if ( in . equalsIgnoreCase ( "1" ) ) { return true ; } else if ( in . equalsIgnoreCase ( "F" ) ) { return false ; } else if ( in . equalsIgnoreCase ( "FALSE" ) ) { return false ; } else if ( in . equalsIgnoreCase ( "0" ) ) { return false ; } throw new IndexParseFieldException ( in ) ; }
converts a string to a boolean .
