201621123086 Java programming 12th Week of study summary

Source: Internet
Author: User

1. Summary of this week's study

    • Classes derived from InputStream or reader contain a basic method called Read (), which is used to read a single-byte or byte array. Similarly, any class derived from OutputStream or writer has a basic method called write (), which is used to write a single byte or an array of bytes. However, we do not usually use these methods.
    • Classes that produce input from different data sources have corresponding InputStream subclasses.
    • The BufferedReader constructor, which provides the ReadLine () method.
    • With Dateinputstream. It is a byte-oriented I/O class that must use the InputStream class
2. System-oriented integrated design-Library management system or Shopping cart 2.1 describes how to use streams and files to transform your system. What is the format of the data in the file?

I'm using BufferedWriter classes and BufferedReader classes to keep books and users ' properties separated by spaces. The data is stored in a. txt file as a string.

2.2 Brief description of what interfaces and classes are used in the file reading and writing section of the system with the stream associated with the file? Why use these interfaces with classes?
    • Read with classes, classes, File FileReader BufferedReader classes, files created through file objects, and the other two classes with the read.
    • Write files are used to BufferedWriter , OutputStreamWriter , FileOutputStream .
2.3 Read and write file-related code. Key lines need to be annotated



3. Code volume Statistics 3.1 Statistics The amount of code done this week selected: 4. Stream and Document Learning Guide 1. Character stream with text file: Use PrintWriter (write), BufferedReader (Read)

201621123086 Java programming 12th Week of study summary

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.