06 File Input and Output Flashcards
It returns the String representation of the Path, eliminating double backslashes.
String toString()
Exception that is thrown if there is an attempt to delete a file without permission.
SecurityException
What are the common characteristics of a text file and binary file?
Size
Name
Date
Time of creation
It depends on other path information.
relative path
Is a collection of fields that contain data about an entity. It is grouped to create files.
record
Method that writes a single character.
write(int c)
Method that skips the specified number of characters.
skip(long n)
Storage that is permanent. It is saved on a disk.
Non-volatile Storage
Method that flushes the stream.
flush()
It is a complete path; it does not require any other information to locate a file on a system.
absolute path
It returns the name in position of the Path specified by the integer parameter.
Path getName(int)
When each record in a file is accessed one after another in the order in which it was stored, the data file is used as a ________ .
sequential access file
Method that can be used to remove a file without encountering an exception if the file does not exist.
deleteIfExists()
It is being used when a Java program stores a value in a variable.
Random Access Memory (RAM)
Exception that is thrown if there is an attempt to delete a directory that has files.
DirectoryNotEmptyException
What are the Path methods? (4)
String toString()
Path getFileName()
int getNameCount()
Path getName(int)
Exception that is thrown if there is an attempt to delete a file that does not exist.
NoSuchFileException
It is a memory location into which you can write data, which you can read again later.
buffer
It performs operations on files and directories , such as determining their attributes, creating input and output streams, and deleting them.
Files class
Argument that opens the file if it exists or creates a new file if it hasn’t existed yet.
CREATE
What two (2) arguments that the readAttributes() method take?
Path object and BasicFileAttributes.class
What are the IO Classes? (10)
InputStream
FileInputStream
BufferedInputStream
OutputStream
FileOutputStream
BufferedOutputStream
PrintStream
Reader
BufferedReader
BufferedWriter
It is the flow of data.
stream
It is the smallest useful piece of data.
character