KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > antlr > FileLineFormatter


1 package antlr;
2
3 /* ANTLR Translator Generator
4  * Project led by Terence Parr at http://www.jGuru.com
5  * Software rights: http://www.antlr.org/RIGHTS.html
6  *
7  * $Id: //depot/code/org.antlr/main/main/antlr/FileLineFormatter.java#5 $
8  */

9
10 public abstract class FileLineFormatter {
11
12     private static FileLineFormatter formatter = new DefaultFileLineFormatter();
13
14     public static FileLineFormatter getFormatter() {
15         return formatter;
16     }
17
18     public static void setFormatter(FileLineFormatter f) {
19         formatter = f;
20     }
21
22     /** @param fileName the file that should appear in the prefix. (or null)
23      * @param line the line (or -1)
24      * @param column the column (or -1)
25      */

26     public abstract String JavaDoc getFormatString(String JavaDoc fileName, int line, int column);
27 }
28
Popular Tags