🗊 Презентация Programming Logic and Design. Chapter 7. File Handling and Applications

Нажмите для полного просмотра!
Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №1 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №2 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №3 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №4 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №5 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №6 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №7 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №8 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №9 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №10 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №11 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №12 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №13 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №14 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №15 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №16 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №17 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №18 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №19 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №20 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №21 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №22 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №23 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №24 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №25 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №26 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №27 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №28 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №29 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №30 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №31 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №32 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №33 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №34 Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №35

Содержание

Вы можете ознакомиться и скачать презентацию на тему Programming Logic and Design. Chapter 7. File Handling and Applications. Доклад-сообщение содержит 35 слайдов. Презентации для любого класса можно скачать бесплатно. Если материал и наш сайт презентаций Mypresentation Вам понравились – поделитесь им с друзьями с помощью социальных кнопок и добавьте в закладки в своем браузере.

Слайды и текст этой презентации


Слайд 1


Programming Logic and Design Seventh Edition Chapter 7 File Handling and Applications
Описание слайда:
Programming Logic and Design Seventh Edition Chapter 7 File Handling and Applications

Слайд 2


Objectives In this chapter, you will learn about: Computer files The data hierarchy Performing file operations Sequential files and control break...
Описание слайда:
Objectives In this chapter, you will learn about: Computer files The data hierarchy Performing file operations Sequential files and control break logic Merging files Master and transaction file processing Random access files

Слайд 3


Understanding Computer Files Computer file A collection of data stored on permanent storage devices such as DVDs, USB drives, and reels of magnetic...
Описание слайда:
Understanding Computer Files Computer file A collection of data stored on permanent storage devices such as DVDs, USB drives, and reels of magnetic tape Text files (numbers, names, salaries) that can be read by a text editor Binary files (images and music) File size measured in bytes Byte (one character), kilobyte (thousands of bytes), megabyte (millions of bytes), gigabyte (billions of bytes), terabyte (trillions of bytes)

Слайд 4


Understanding Computer Files (continued) Organizing files Directories and folders Organization units on storage devices Path Combination of disk...
Описание слайда:
Understanding Computer Files (continued) Organizing files Directories and folders Organization units on storage devices Path Combination of disk drive plus the complete hierarchy of directories Example: C:\Logic\SampleFiles\PayrollData.dat

Слайд 5


Understanding the Data Hierarchy Data hierarchy Describes the relationships between data components Consists of: Characters Fields Records Files
Описание слайда:
Understanding the Data Hierarchy Data hierarchy Describes the relationships between data components Consists of: Characters Fields Records Files

Слайд 6


Performing File Operations Use data files in your programs Declaring a file InputFile employeeData OutputFile updatedData Opening a file open...
Описание слайда:
Performing File Operations Use data files in your programs Declaring a file InputFile employeeData OutputFile updatedData Opening a file open employeeData "EmployeeData.dat" Reading data from a file input name from employeeData input address from employeeData input payRate from employeeData

Слайд 7


Performing File Operations (continued) Figure 7-2 Reading three data items from a storage device into memory
Описание слайда:
Performing File Operations (continued) Figure 7-2 Reading three data items from a storage device into memory

Слайд 8


Performing File Operations (continued) Writing data to a file output name, address, payRate to employeeData Closing a file Always close every file...
Описание слайда:
Performing File Operations (continued) Writing data to a file output name, address, payRate to employeeData Closing a file Always close every file you open

Слайд 9


Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №9
Описание слайда:

Слайд 10


Programming Logic and Design. Chapter 7. File Handling and Applications, слайд №10
Описание слайда:

Слайд 11


A Program that Performs File Operations Backup file A copy that is kept in case values need to be restored to their original state Called a parent...
Описание слайда:
A Program that Performs File Operations Backup file A copy that is kept in case values need to be restored to their original state Called a parent file A newly revised copy is a child file Sorting The process of placing records in order by the value in a specific field or fields

Слайд 12


Understanding Sequential Files and Control Break Logic Sequential file Records are stored one after another in some order Understanding control break...
Описание слайда:
Understanding Sequential Files and Control Break Logic Sequential file Records are stored one after another in some order Understanding control break logic A control break is a temporary detour in a program A control break program uses a change in a value to initiate special actions or processing A control break report groups similar data together Input records must be in sequential order

Слайд 13


Understanding Sequential Files and Control Break Logic (continued) Figure 7-4 A control break report with totals after each state
Описание слайда:
Understanding Sequential Files and Control Break Logic (continued) Figure 7-4 A control break report with totals after each state

Слайд 14


Understanding Sequential Files and Control Break Logic (continued) Examples of control break reports All employees listed in order by department...
Описание слайда:
Understanding Sequential Files and Control Break Logic (continued) Examples of control break reports All employees listed in order by department number, with a new page started for each department All books for sale in a bookstore listed in order by category (such as reference or self-help), with a count following each category of book All items sold in order by date of sale, with a different ink color for each new month

Слайд 15


Understanding Sequential Files and Control Break Logic (continued) Single-level control break A detour based on the value of a single variable Uses a...
Описание слайда:
Understanding Sequential Files and Control Break Logic (continued) Single-level control break A detour based on the value of a single variable Uses a control break field to hold the previous value

Слайд 16


Figure 7-5 Mainline logic and getReady() module for the program that produces clients by state report Figure 7-5 Mainline logic and getReady() module...
Описание слайда:
Figure 7-5 Mainline logic and getReady() module for the program that produces clients by state report Figure 7-5 Mainline logic and getReady() module for the program that produces clients by state report

Слайд 17


Figure 7-6 The produceReport() and controlBreak() modules for the program that produces clients by state Figure 7-6 The produceReport() and...
Описание слайда:
Figure 7-6 The produceReport() and controlBreak() modules for the program that produces clients by state Figure 7-6 The produceReport() and controlBreak() modules for the program that produces clients by state

Слайд 18


Understanding Sequential Files and Control Break Logic (continued) Figure 7-7 The finishUp()module for the program that produces clients by state...
Описание слайда:
Understanding Sequential Files and Control Break Logic (continued) Figure 7-7 The finishUp()module for the program that produces clients by state report

Слайд 19


Merging Sequential Files Merging files Combining two or more files while maintaining the sequential order Examples A file of current employees in ID...
Описание слайда:
Merging Sequential Files Merging files Combining two or more files while maintaining the sequential order Examples A file of current employees in ID number order, and a file of newly hired employees also in ID number order A file of parts manufactured in the Northside factory in part-number order, and a file of parts manufactured in the Southside factory also in part-number order

Слайд 20


Merging Sequential Files (continued) Two conditions required for merging files Each file has the same record layout Sorted in the same order based on...
Описание слайда:
Merging Sequential Files (continued) Two conditions required for merging files Each file has the same record layout Sorted in the same order based on the same field Ascending order (lowest to highest values) Descending order (highest to lowest values)

Слайд 21


Merging Sequential Files (continued) Figure 7-8 Sample data contained in two customer files
Описание слайда:
Merging Sequential Files (continued) Figure 7-8 Sample data contained in two customer files

Слайд 22


Mainline logic similar to other file-processing programs, except for handling two files Mainline logic similar to other file-processing programs,...
Описание слайда:
Mainline logic similar to other file-processing programs, except for handling two files Mainline logic similar to other file-processing programs, except for handling two files With two input files, must determine when both files are at eof Define a flag variable to indicate that both files have reached eof Must define two input files Read one record from each input file

Слайд 23


Figure 7-10 Mainline logic of a program that merges files Figure 7-10 Mainline logic of a program that merges files
Описание слайда:
Figure 7-10 Mainline logic of a program that merges files Figure 7-10 Mainline logic of a program that merges files

Слайд 24


Figure 7-12 Start of merging process Figure 7-12 Start of merging process
Описание слайда:
Figure 7-12 Start of merging process Figure 7-12 Start of merging process

Слайд 25


Figure 7-13 Continuation of merging process Figure 7-13 Continuation of merging process
Описание слайда:
Figure 7-13 Continuation of merging process Figure 7-13 Continuation of merging process

Слайд 26


Master and Transaction File Processing Some related files have a master-transaction relationship Master file Holds relatively permanent data...
Описание слайда:
Master and Transaction File Processing Some related files have a master-transaction relationship Master file Holds relatively permanent data Transaction file Contains temporary data to be used to update the master file Update the master file Changes to values in its fields based on transactions

Слайд 27


Master and Transaction File Processing (continued) Examples A library maintains a master file of all patrons and a transaction file with information...
Описание слайда:
Master and Transaction File Processing (continued) Examples A library maintains a master file of all patrons and a transaction file with information about each book or other items checked out A college maintains a master file of all students and a transaction file for each course registration A telephone company maintains a master file of every telephone line (number) and a transaction file with information about every call

Слайд 28


Master and Transaction File Processing (continued) Updating approaches Change information in master file Copy master file and change new version...
Описание слайда:
Master and Transaction File Processing (continued) Updating approaches Change information in master file Copy master file and change new version Begin with both files sorted in the same order on the same field

Слайд 29


Figure 7-16 The housekeeping() module for the master-transaction program, and the modules it calls Figure 7-16 The housekeeping() module for the...
Описание слайда:
Figure 7-16 The housekeeping() module for the master-transaction program, and the modules it calls Figure 7-16 The housekeeping() module for the master-transaction program, and the modules it calls

Слайд 30


Figure 7-17 The updateRecords() module for the master-transaction program Figure 7-17 The updateRecords() module for the master-transaction program
Описание слайда:
Figure 7-17 The updateRecords() module for the master-transaction program Figure 7-17 The updateRecords() module for the master-transaction program

Слайд 31


Master and Transaction File Processing (continued) Figure 7-18 Sample data for the file-matching program
Описание слайда:
Master and Transaction File Processing (continued) Figure 7-18 Sample data for the file-matching program

Слайд 32


Random Access Files Batch processing Involves performing the same tasks with many records, one after the other Uses sequential files Real-time...
Описание слайда:
Random Access Files Batch processing Involves performing the same tasks with many records, one after the other Uses sequential files Real-time applications Require that a record be accessed immediately while a client is waiting Interactive program A program in which the user makes direct requests

Слайд 33


Random Access Files (continued) Random access files Records can be located in any order Instant access files Locating a particular record directly...
Описание слайда:
Random Access Files (continued) Random access files Records can be located in any order Instant access files Locating a particular record directly Also known as direct access files

Слайд 34


Summary Computer file A collection of data stored on a nonvolatile device in a computer system Data items are stored in a hierarchy Using a data file...
Описание слайда:
Summary Computer file A collection of data stored on a nonvolatile device in a computer system Data items are stored in a hierarchy Using a data file Declare, open, read, write, close Sequential file: records stored in some order Merging files combines two or more files Maintains the same sequential order

Слайд 35


Summary Master files Hold permanent data Updated by transaction files Real-time applications Require random access files Records stored in any order...
Описание слайда:
Summary Master files Hold permanent data Updated by transaction files Real-time applications Require random access files Records stored in any order Records accessed immediately



Похожие презентации
Mypresentation.ru
Загрузить презентацию