In this part of the code refactoring tutorial I’m going to revisit the Builder Design Pattern for a couple of reasons. First, I receive a bunch of questions about it. Secondly, in the next tutorial I’ll show you how to build composites, which were covered in the last part of the code refactoring tutorial, with the builder pattern.
The builder pattern allows you to build complex objects in a series of steps. In the video and code below, we will build sandwiches. Here is he previous tutorial on the Builder Design Pattern to help as well.
If you like videos like this, it helps to tell Google [googleplusone]
Code From the Video
Sandwich.java
SandwichBuilder.java