harpoon.Interpret.Tree
Class UndefinedPointer

java.lang.Object
  extended by harpoon.Util.Tuple
      extended by harpoon.Interpret.Tree.UndefinedPointer
All Implemented Interfaces:
Serializable, Comparable

public class UndefinedPointer
extends Tuple

The UndefinedPointer class represents a pointer to a value for which the type is not known. It is an error to access the value of this pointer until it is converted to a pointer of another type.

Version:
$Id: UndefinedPointer.java,v 1.2 2002/02/25 21:06:01 cananian Exp $
Author:
Duncan Bryce <duncan@lcs.mit.edu>
See Also:
Serialized Form

Field Summary
static int ARRAY_PTR
           
static int CLAZ_PTR
           
static int CONST_PTR
           
static int FIELD_PTR
           
static int IFACE_PTR
           
static int STRING_PTR
           
static int UNDEF_PTR
           
 
Constructor Summary
UndefinedPointer(UndefinedRef ref, long offset)
          Class constructor
 
Method Summary
 harpoon.Interpret.Tree.Pointer add(long offset)
          Adds the specified offset to the offset of this UndefinedPointer and returns the resulting pointer.
 Object getBase()
          Returns an UndefinedRef object representing the base of this UndefinedPointer.
 long getOffset()
          Returns the offset of this UndefinedPointer.
 boolean isConst()
          Always returns false.
 boolean isDerived()
          Always returns false.
 int kind()
          Returns an integer enumeration of the kind of this Pointer.
 String toString()
          Returns a human-readable representation of this UndefinedPointer.
 
Methods inherited from class harpoon.Util.Tuple
asList, compareTo, equals, hashCode, proj
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ARRAY_PTR

public static final int ARRAY_PTR
See Also:
Constant Field Values

CLAZ_PTR

public static final int CLAZ_PTR
See Also:
Constant Field Values

CONST_PTR

public static final int CONST_PTR
See Also:
Constant Field Values

FIELD_PTR

public static final int FIELD_PTR
See Also:
Constant Field Values

IFACE_PTR

public static final int IFACE_PTR
See Also:
Constant Field Values

STRING_PTR

public static final int STRING_PTR
See Also:
Constant Field Values

UNDEF_PTR

public static final int UNDEF_PTR
See Also:
Constant Field Values
Constructor Detail

UndefinedPointer

public UndefinedPointer(UndefinedRef ref,
                        long offset)
Class constructor

Method Detail

add

public harpoon.Interpret.Tree.Pointer add(long offset)
Adds the specified offset to the offset of this UndefinedPointer and returns the resulting pointer.


getBase

public Object getBase()
Returns an UndefinedRef object representing the base of this UndefinedPointer.


getOffset

public long getOffset()
Returns the offset of this UndefinedPointer.


isConst

public boolean isConst()
Always returns false.


isDerived

public boolean isDerived()
Always returns false.


kind

public int kind()
Returns an integer enumeration of the kind of this Pointer. The enumerated values are public fields of the Pointer class.


toString

public String toString()
Returns a human-readable representation of this UndefinedPointer.

Overrides:
toString in class Tuple