marks the current point in this IO stream. a buffer is created allowing the mark to be &reset until n bytes has been reached.
$handle - the handle to mark
n - the number of bytes to buffer (to allow for a reset back to this mark later) (default is a 10KB buffer)
$buffer = allocate(); writeb($buffer, "this.is.an.example"); closef($buffer); println("Read: " . readb($buffer, 4)); mark($buffer); println("Read: " . readb($buffer, 4)); reset($buffer); println("Read: " . readb($buffer, -1));
Read: this Read: .is. Read: .is.an.example