harpoon.Tools.Annotation.Lex
Class LinePos

java.lang.Object
  extended by harpoon.Tools.Annotation.Lex.LinePos

public class LinePos
extends Object

LocPair is a line number, character position pair to denote a location in the input file.

Version:
$Id: LinePos.java,v 1.2 2002/02/25 21:08:26 cananian Exp $
Author:
C. Scott Ananian <cananian@alumni.princeton.edu>

Field Summary
 int line
          Line number in the source file.
 int pos
          Character position in the line.
 
Constructor Summary
LinePos(int line, int pos)
          Creates a LocPair.
 
Method Summary
 String toString()
          Human-readable representation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

line

public final int line
Line number in the source file. Starts at 1.


pos

public final int pos
Character position in the line. Starts at 0.

Constructor Detail

LinePos

public LinePos(int line,
               int pos)
Creates a LocPair.

Method Detail

toString

public String toString()
Human-readable representation.

Overrides:
toString in class Object