COMP 4—Power Tools for the Mind 1 Power Tools What’s in the Box? File Management & Windows Explorer What we’ll cover for this lecture topic: – Files and file management • File types • Using files • File naming conventions • File organization/hierarchy • Future Trends – Windows Explorer (tool) Excellent tutorials! Very important concepts!
24
Embed
COMP 4—Power Tools for the Mind 1 Power Tools What’s in the Box? File Management & Windows Explorer What we’ll cover for this lecture topic: –Files and.
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
COMP 4—Power Tools for the Mind 1Power Tools
What’s in the Box?
File Management & Windows Explorer
What we’ll cover for this lecture topic:– Files and file management
Files and File Management• Soon you will learn how five different kinds of data
can be represented in a computer.• How do we organize this data? It is all just a bunch
of 0s and 1s, no?– Yes, but we logically organize these 0s and 1s into files.
• Computer files are storage containers that hold all the 0s and 1s that represent all the data that belong to a single document or to a program.– DOCUMENT files– PROGRAM files (executable / source)
• Kept track of by Operating System (OS)
File types
COMP 4—Power Tools for the Mind 3Power Tools
What’s in the Box?
• PROGRAM files (executable)– created by an programmer– called Executable files
• stored as machine code• ready to be executed by CPU (“compiled” code)• examples:
–application programs (Apps)–operating system programs (OS)–utilities (compression utility; backup utility; etc.)–some run at a user’s request; others at a program’s
request
• DOCUMENT files– created by an application program.– alphanumeric characters, numbers, pictures, sounds.
COMP 4—Power Tools for the Mind 4Power Tools
What’s in the Box?
• PROGRAM files (source)– created by an programmer– called Source files
• usually stored as a readable text file (e.g. ASCII)• need translation before they can be executed by CPU• Example source files:
–program source files• Turing (e.g. later you will write Turing programs)• Java / C / C++
–script languages
• JavaScript / VisualBasic Script
–batch files
• bunch of commands stored in a text file.• automatically-executed batch file: “autoexec.bat”
• Recall from Chapter 1-A (pp 11-13) that software also has two basic levels:– Applications software
like Word, Excel, or Quake– Systems software
the operating system
COMP 4—Power Tools for the Mind 6Power Tools
What’s in the Box?
• You turn the computer ON:– System boot-up happens …– Power reaches chips on the main
circuit (mother board).– one chip is ROM memory that
contains a bootstrap program– it instructs the processor how to
copy (e.g. load) the operating system from the disk to the main memory
OK: so what happens in storage as we use computer files?
COMP 4—Power Tools for the Mind 7Power Tools
What’s in the Box?
COMPUTER SYSTEM
Processor
Main MemoryInput Output
Auxiliary Storage- OS programs:
- Kernel (main supervisor)
- Application program loader
- Copy, Rename, Move, … routines
- APPS: Word Excel PPT Quake
- DATA files: Letter MyPic Budget
Volatile
Also provides inputs
Non-Volatile bootstrap program
Also savesoutputs
7
COMP 4—Power Tools for the Mind 8Power Tools
What’s in the Box?
• What will happen INSIDE THE BOX whenWord is launched?
– Hint: Where is the MS WORD program stored even before you switched the computer on? Where must it be stored (be copied to) so that we can use it? Why?
– Remember: electronic memory is 1,000 to 100,000 times faster than electromechanical storage.
• Next, you want to create a new text document.– What’s in memory now?– Tell the computer to Start M.S. Word.
• Other terms for Starting: Launch; Load
Proc.
Main Memory
AuxiliaryStorage
COMP 4—Power Tools for the Mind 9Power Tools
What’s in the Box?
• Exactly WHAT part of the computer system do you, the user, give this request to?
– Hint: what part of the computer system knows how to handle that request?
• In what ways can the user make that request?
Digression: What kind of file is MS Word? How do you know which apps are currently open?
Demo:Different ways to start a file.
COMP 4—Power Tools for the Mind 10Power Tools
What’s in the Box?
– SO… MS Word provides a blank document window. You enter some text.
• Where is that text being stored?• What happens if the machine freezes up (crashes)?
Proc.
Main Memory
AuxiliaryStorage
– PROTECTON ?• SAVE the document to
a floppy or to the hard-drive!
• SAVE regularly!
COMP 4—Power Tools for the Mind 11Power Tools
What’s in the Box?
– OK, so you save the text document.
Proc.
Main Memory
AuxiliaryStorage
• Which two things happens “in the box” when you Save it?
• What kind of file is it?• How many copies of that “file” are in existence at this
moment, and where are they stored?
• You make lots of changes to your document.– Where are those changes being stored?
• OK, finished with your changes. Whatare your 3 options here?• Save
– Replaces disk file with edited file.
• Just Close. Don’t save.– Why would you want to do this?
• Save As– Keep original: store newly edited file
under a different name
COMP 4—Power Tools for the Mind 12Power Tools
What’s in the Box?
– Now you want to open (in addition) a data file you saved yesterday.
• First, where is it now? What happens “in the box” when you open it? Where is it then?
– You’re finished with the first document ...• What is the minimum I should close to free main memory?• Exactly what happens “in the box” when
you only close that document?• Why not quit the application?• What is the difference between
closing a document and closinga program? Proc.
Main Memory
AuxiliaryStorage
COMP 4—Power Tools for the Mind 13Power Tools
What’s in the Box?
– You’re finished doing word processing for this computer session.
• What could you do now to free up memory? How?• Exactly what happens “in the box” when you do that?• How can you tell by looking at the desktop?
– What happens if I delete (‘recycle’) a file:• from the hard drive?
OS “moves” it to the recycle bin fromwhere can potentially be restoredlater.
• from a floppy disk?
Not moved to recycle bin. Cannoteasily be restored.
Proc.
Main Memory
AuxiliaryStorage
COMP 4—Power Tools for the Mind 14Power Tools
What’s in the Box?
– In these previous examples• Things keep moving around from one type of
MEMORY to another.
• Later, we’ll examine more closely WHY we have different types of memory, what they are, and what they are good for.
Using Files interactive lab – see Lab-03
– What happens “in the box”: save, save As, move, copy, delete, etc.
COMP 4—Power Tools for the Mind 15Power Tools
What’s in the Box?
Rules determined by the OS File naming conventions
(Win)– Windows 95/98/2000/XP:
• Up to 255 characters (including the extension). • Letters, numbers, most symbols except \ ? : “ < > |• Not case sensitive • Cannot use reserved words
– Filename extensions • Tells Windows OS what the file format is.• Some examples: (see text for more)
.exe .com --Executables that user can run
.sys .drv .dll --Executables that user cannot run
.doc .txt .xls --Text and spreadsheet file formats
.jpeg .gif .tif --Graphics file formats
.wav .mid .mp3 --Sound file formats
– Early PC days ….. Dreadful: “eight dot three”
Com1 Com2 Aux
Lpt1 Prn Nul
Folder view
UNHIDE
COMP 4—Power Tools for the Mind 16Power Tools
What’s in the Box?
File naming conventions (Others)
Again, rules determined by O.S.– Mac OS
• Up to 31 characters • Letters, numbers, most symbols except :• Case sensitive • No reserved words
– Unix• From up to 14 to 256 characters (depends on version)• Letters, numbers, most symbols except \ ? “ < > | * ! @ # $ % ^ & ( ) { }
[ ] ;– no space allowed (sort of...); confuses the command line
• Case sensitive • Reserved words depend on version
COMP 4—Power Tools for the Mind 17Power Tools
What’s in the Box?
• Traditional file organization– Early Operating systems for PCs:
• Remember what application you used; launch it first; then open data file.
• Organizing files: tendency to keep docs filed w/apps.– Is that particularly useful to USER? Why or why not?
File organization
• Document-centric file organization – Thanks to newer OSs:
• Open data file-- automatically launches app that created it.
• SO WHAT? Why is this more useful to the user?
“Documentcentricity”
Play With Extensions
COMP 4—Power Tools for the Mind 18Power Tools
What’s in the Box?
LOGICAL file storage/organization
• OS keeps a directory for each disk:
– A list of files stored on that computer disk
– Where OS keeps track of each file (fname, date,
time, size…)
– Logical view of data storage.
– Later we will look into how the OS maintains
their physical location on the disk (clusters).
COMP 4—Power Tools for the Mind 19Power Tools
What’s in the Box?
• Logical organization--way to organize &
visualize where folders and files are stored on a
disk….
– the OS helps us to do this
– incorporates a hierarchical organization….
– Metaphor: sideways tree…. (next slide)
COMP 4—Power Tools for the Mind 20Power Tools
What’s in the Box?
Metaphor: Hierarchical file org. Trunk- Root directory- Disk drive or partition. Each ID’d by letter. What’s typical?
Branches- Subdirectories (aka: Folders): Can be directly under root directory (main branch).
Can be “nested” inside other subdirectories. (branch off main branch).
Leaves - Files
File specifications (paths):
D:\Homework\Comp 4\Lab 3 D:\Letters\Family\Mom.doc File spec for John.doc?