org.vmmagic.unboxed
Class Offset

java.lang.Object
  extended by org.vmmagic.unboxed.Offset

public final class Offset
extends Object

Represents a pointer-sized signed integer used for describing an offset in bytes. Can be used to refer to a field in a type-unsafe way.


Constructor Summary
Offset()
           
 
Method Summary
 boolean EQ(Offset off2)
           
static Offset fromIntSignExtend(int address)
           
static Offset fromIntZeroExtend(int address)
           
 boolean isMax()
           
 boolean isZero()
           
static Offset max()
           
 Offset minus(int byteSize)
           
 Offset minus(Offset off2)
           
 boolean NE(Offset off2)
           
 Offset plus(int byteSize)
           
 boolean sGE(Offset off2)
           
 boolean sGT(Offset off2)
           
 boolean sLE(Offset off2)
           
 boolean sLT(Offset off2)
           
 int toInt()
           
 long toLong()
           
 Word toWord()
           
static Offset zero()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Offset

public Offset()
Method Detail

fromIntSignExtend

public static Offset fromIntSignExtend(int address)

fromIntZeroExtend

public static Offset fromIntZeroExtend(int address)

zero

public static Offset zero()

max

public static Offset max()

toInt

public int toInt()

toLong

public long toLong()

toWord

public Word toWord()

plus

public Offset plus(int byteSize)

minus

public Offset minus(int byteSize)

minus

public Offset minus(Offset off2)

EQ

public boolean EQ(Offset off2)

NE

public boolean NE(Offset off2)

sLT

public boolean sLT(Offset off2)

sLE

public boolean sLE(Offset off2)

sGT

public boolean sGT(Offset off2)

sGE

public boolean sGE(Offset off2)

isZero

public boolean isZero()

isMax

public boolean isMax()