From 2fd212fe8889211c3924b5916238f31cdb05d0e0 Mon Sep 17 00:00:00 2001 From: Otavio Santana Date: Thu, 19 Dec 2024 16:23:24 +0000 Subject: [PATCH] feat: create builder to factory method Signed-off-by: Otavio Santana --- src/main/java/com/otaviojava/demos/ddd/Product.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/com/otaviojava/demos/ddd/Product.java b/src/main/java/com/otaviojava/demos/ddd/Product.java index c618520..819eb7a 100644 --- a/src/main/java/com/otaviojava/demos/ddd/Product.java +++ b/src/main/java/com/otaviojava/demos/ddd/Product.java @@ -88,4 +88,8 @@ public String toString() { ", categories=" + categories + '}'; } + + public static ProductBuilder builder() { + return new ProductBuilder(); + } }