Unformatted text preview:

1Random Access Files4/24/20072Opening Discussion■Do you have any questions about the assignment?■Comparing RMI codes.■What types of applications require random access files? Why?3Fixed Record Length Files■The simplest way to take advantage of random access files is to have files with a fixed record length. This means that all the entries in the file are the same length. In this situation you can easily treat the file just like an array and jump straight to where the data is stored to do your reads or writes.■If you have more data than you have memory on your machine this is an easy way to quickly deal with data. It also makes your program more robust against power failure.■Fixed length records lack flexibility.4Indexing into Files■If the records have variable length a slightly more complex approach is needed. Basically, direct access requires the ability to know where you are jumping to. This means you store indexes into the file in a format that you can quickly go through.■One way to do this is to stores a “array” of file positions at the front of the file. You direct access the position for a record, then jump to where it is.■Alternate data structures, such as B-trees can also be used. Some of these are covered in Data Abstraction.5Code■For the rest of the class I want to add onto the drawing program and try to get some more functionality into it.■What would you like to see added in?6Minute Essay■Next class is the last one of the semester. What would you like to see us do or talk


View Full Document

TRINITY CSCI 1321 - Random Access Files

Documents in this Course
Recursion

Recursion

11 pages

Iterators

Iterators

10 pages

Actors

Actors

9 pages

Recursion

Recursion

15 pages

Recursion

Recursion

10 pages

Threads

Threads

7 pages

Trees

Trees

11 pages

Load more
Download Random Access Files
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Random Access Files and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Random Access Files 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?