Code example for Locator

Methods: getColumnNumber, getLineNumber

0
        private ParseException(String message, Locator locator) {
            super(makeMessage(message, locator), locator);
        } 
 
        private static String makeMessage(String message, Locator locator) {
            return makeMessage(message, locator.getLineNumber(),
                    locator.getColumnNumber());
        } 
 
        private static String makeMessage(
                String message, int line, int column) {
            return "At line " + line + ", column "
                    + column + ": " + message;
        } 
    } 
 
    /** 
     * Opens an InputStream for the given URL. 
     */ 
    /*package*/ static InputStream openUrl(String url) throws IOException {
        try {