common
Interface ScannerWithLocInfo

All Superinterfaces:
java_cup.runtime.Scanner
All Known Implementing Classes:
BLOGLexer

public interface ScannerWithLocInfo
extends java_cup.runtime.Scanner

Extension of the Scanner interface that includes methods for getting the current file and line number.


Method Summary
 java.lang.String getCurFilename()
          Returns the name of the file being scanned.
 int getCurLineNum()
          Returns the number of the line containing the beginning of the last token matched.
 
Methods inherited from interface java_cup.runtime.Scanner
next_token
 

Method Detail

getCurFilename

java.lang.String getCurFilename()
Returns the name of the file being scanned.


getCurLineNum

int getCurLineNum()
Returns the number of the line containing the beginning of the last token matched. Line numbers are 1-based.