(self, pos)
Read a record.
Read a record.
Read a record .
def get(self, pos):
        """Read a record."""
        self._set_record_pos(pos)
        # exceptionally, GET is allowed if the file holding the lock is open for OUTPUT
        self._locks.try_record_access(self._number, self._recpos+1, self._recpos+1, b'R')
        if self.eof():
            contents = b'\0' * self.reclen
        else:
            with safe_io():
                contents = self._fhandle.read(self.reclen)
        # take contents and pad with NULL to required size
        self._field_file.set_buffer(contents)
        self._recpos += 1
def get ( self , pos ) : self . _set_record_pos ( pos ) # exceptionally, GET is allowed if the file holding the lock is open for OUTPUT self . _locks . try_record_access ( self . _number , self . _recpos + 1 , self . _recpos + 1 , b'R' ) if self . eof ( ) : contents = b'\0' * self . reclen else : with safe_io ( ) : contents = self . _fhandle . read ( self . reclen ) # take contents and pad with NULL to required size self . _field_file . set_buffer ( contents ) self . _recpos += 1