Package Creational.Builder
Class ConcreteBuilder
java.lang.Object
Creational.Builder.ConcreteBuilder
- All Implemented Interfaces:
Builder
Concrete implementation of the Builder interface.
Constructs a specific type of product by implementing the building steps
defined in the Builder interface.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidBuilds Part A of the product.voidBuilds Part B of the product.Retrieves the constructed product.
-
Constructor Details
-
ConcreteBuilder
public ConcreteBuilder()Constructor initializes a new Product instance.
-
-
Method Details
-
buildPartA
public void buildPartA()Builds Part A of the product. Sets Part A to a specific value defined by this builder.- Specified by:
buildPartAin interfaceBuilder
-
buildPartB
public void buildPartB()Builds Part B of the product. Sets Part B to a specific value defined by this builder.- Specified by:
buildPartBin interfaceBuilder
-
getResult
Retrieves the constructed product.
-