Hacker News new | ask | show | jobs
by SAI_Peregrinus 2158 days ago
Aah, so then you use the Builder Pattern! Instead of one constructor taking N arguments, have a constructor that takes no arguments and N function calls to initialize the constructed values. It's cleaner because it's a named pattern! /s