O'Reilly logo

AdvancED ActionScript 3.0: Design Patterns by Ben Smith

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Builder Pattern

The Builder pattern separates the construction steps from the product to offer flexibility among product representations. Figure 6-4 shows the class diagram.

Image

Figure 6-4. Builder pattern class diagram

This pattern has the following parts:

  • Abstract product
  • Concrete product
  • Abstract builder
  • Concrete builder
  • Abstract director
  • Concrete director
  • Client

The pattern's benefits are as follows:

  • Very high level of control over object creation
  • Enables varying products from the same algorithms
  • Conceals the construction process from the client

A Comprehensive Look

The Builder pattern is concerned with building objects in a manner ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required