de.hunsicker.jalopy.language
Class Annotation

java.lang.Object
  |
  +--de.hunsicker.jalopy.language.Annotation

public final class Annotation
extends java.lang.Object

A class that wraps some application specific annotation data. It can be used to track the position information for things like debugger breakpoints, erroneous lines, and so on.

Since:
1.0b9
Version:
$Revision: 1.2.2.2 $
Author:
Marco Hunsicker
See Also:
JavaRecognizer.attachAnnotations(java.util.List)

Constructor Summary
Annotation(int line, java.lang.Object data)
          Creates a new Annotation object.
 
Method Summary
 java.lang.Object getData()
          Returns the application specific annotation data.
 int getLine()
          Returns the (1-based) line number where this annotation belongs.
 void setLine(int line)
          Sets the line number where this annotation belongs.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Annotation

public Annotation(int line,
                  java.lang.Object data)
Creates a new Annotation object.

Parameters:
line - the line number to which the annotation is attached.
data - the application specific annotation data.
Method Detail

getData

public java.lang.Object getData()
Returns the application specific annotation data.

Returns:
annotation data.

setLine

public void setLine(int line)
Sets the line number where this annotation belongs.

Parameters:
line - line number (>= 1).
Throws:
java.lang.IllegalArgumentException - if line < 1

getLine

public int getLine()
Returns the (1-based) line number where this annotation belongs.

Returns:
the line number where this annotation belongs (>= 1).


Copyright © 1997-2005 Jalopy. All Rights Reserved.