Join David Gassner for an in-depth discussion in this video Using the exercise files, part of Java SE 8 New Features.
- View Offline
This course is accompanied by exercise files that you can use to follow along with the demonstrations. I've copied the exercise files to my desktop. But you can place them anywhere on your hard disk. The exercise files are organized by chapters, one folder for each chapter. Within each folder, you'll find ZIP files, one for each demonstration. The ZIP files are Eclipse project archives designed to be imported into Eclipse. You'll need Eclipse 4.3 or later and you'll need to have added Java 8 support if you are using 4.3 or Kepler.
I'll describe how to add that support early in the course. Once you have added Java 8 support to Eclipse, you can import these projects as you need them. To import the project, go to Eclipse's menu and select File > Import. Under General, choose Existing Project into Workspace and click Next. Choose Select archive file and Browse. And from your exercise files folder go to the folder for the chapter you're working on and choose the project you want to work with.
And then follow the rest of the prompts to import the project. You can then open the project. Open its source folder. Open its default package. And start working on the code. In addition to the starting projects for each demonstration, I've also provided finishing projects, under the solutions folder. This folder has the same set of chapters, and each of the projects within those folders has the same name, but with a suffix of _solution. In Eclipse, you can't open more than one project of the same name at the same time.
So, I've given them different names so you can open both the starting and the solution project simultaneously and look at the differences. All of the software used in this course is free. You can download Java SE 8 from Oracle, and Eclipse from the Eclipse Foundation. And again, I'll show you all of those steps as we move through the course.
- Installing Java SE 8
- Working with lambda expressions and method references
- Traversing collections with streams
- Calculating timespans with the new DateTime API