import User from "./User" ; export default class UserBuilder { private name : string ; private age ? : number ; private phone ? : string ; private address ? : string ; constructor ( name ) { this . name = name ; } get Name ( ) { return this . name ; } setAge ( value ) { this . age = value ; return this ; } get Age ( ) { return this . age ; } setPhone ( value ) { this . phone = value ; return this ; } get Phone ( ) { return this . phone ; } setAddress ( value ) { this . address = value ; return this ; } get Address ( ) { return this . address ; } build ( ) { return new User ( this ) ; } }