Ejemplo n.º 1
0
 /**
  * Constructs a new record found at the given zero-based position in the associated DBC
  */
 public function __construct(DBC $dbc, $pos)
 {
     $this->_dbc = $dbc;
     $this->_pos = $pos;
     $this->_offset = DBC::HEADER_SIZE + $pos * $dbc->getRecordSize();
     $handle = $dbc->getHandle();
     fseek($handle, $this->_offset);
     if ($dbc->getRecordSize() > 0) {
         $this->_data = fread($handle, $dbc->getRecordSize());
     }
 }