org.jawk.intermediate
Interface Position

All Known Subinterfaces:
PositionForCompilation, PositionForInterpretation

public interface Position

Marks a position within the tuple list (queue).


Method Summary
 Address addressArg()
          Obtain the address argument for this tuple.
 java.lang.Object arg(int idx)
          Get a reference to a particular element within the tuple.
 boolean boolArg(int idx)
          Get the boolean representation for a particular element within the tuple.
 java.lang.Class classArg()
          Obtain the class argument for this tuple.
 int intArg(int idx)
          Get the integer representation for a particular element within the tuple.
 boolean isEOF()
           
 int lineNumber()
          Get the source line number for this position.
 void next()
          Advances the position to the next tuple, as ordered within the tuple list (queue).
 int opcode()
           
 

Method Detail

isEOF

boolean isEOF()
Returns:
true whether we are at the end of the tuple list, false otherwise

next

void next()
Advances the position to the next tuple, as ordered within the tuple list (queue).


opcode

int opcode()
Returns:
the opcode for the tuple at this position

intArg

int intArg(int idx)
Get the integer representation for a particular element within the tuple.

Parameters:
idx - The item to retrieve from the tuple.
Returns:
the integer representation of the item.

boolArg

boolean boolArg(int idx)
Get the boolean representation for a particular element within the tuple.

Parameters:
idx - The item to retrieve from the tuple.
Returns:
the boolean representation of the item.

arg

java.lang.Object arg(int idx)
Get a reference to a particular element within the tuple.

Parameters:
idx - The item to retrieve from the tuple.
Returns:
a reference to the item.

addressArg

Address addressArg()
Obtain the address argument for this tuple.

This is a special form in that the tuple has only the address argument, and nothing else.


classArg

java.lang.Class classArg()
Obtain the class argument for this tuple.

This is a special form in that the tuple has only the class argument, and nothing else.


lineNumber

int lineNumber()
Get the source line number for this position.