Chapter 10. Working with Files, Streams, and Serialization
This chapter is about reading and writing to files and streams, text encoding, and serialization.
This chapter will cover the following topics:
- Managing the filesystem
- Reading and writing with streams
- Encoding text
- Serializing object graphs
Managing the filesystem
Your applications will often need to perform input and output with files and directories. The
System.IO namespace contains classes for this purpose.
In Visual Studio 2017, press Ctrl + Shift + N or choose File | New | Project....
In the New Project dialog, in the Installed | Templates list, select .NET Core. In the center list, select Console App (.NET Core), type Name as
Ch10_FileSystem, change the location to