Class Pointer

java.lang.Object
uk.ac.bristol.star.cdf.record.Pointer

public class Pointer extends Object
Keeps track of a file offset.
Since:
18 Jun 2013
  • Constructor Summary

    Constructors
    Constructor
    Description
    Pointer(long value)
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    long
    get()
    Returns this pointer's current value.
    long
    getAndIncrement(int increment)
    Returns this pointer's current value and increments it by a given step.
    void
    set(long value)
    Sets this pointer's current value.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Pointer

      public Pointer(long value)
      Constructor.
      Parameters:
      value - initial value
  • Method Details

    • get

      public long get()
      Returns this pointer's current value.
      Returns:
      value
    • getAndIncrement

      public long getAndIncrement(int increment)
      Returns this pointer's current value and increments it by a given step.
      Parameters:
      increment - amount to increase value by
      Returns:
      pre-increment value
    • set

      public void set(long value)
      Sets this pointer's current value.
      Parameters:
      value - new value