Private Constructors

Category: PHP

Private constructors are a pattern found in object-oriented programming languages that prevents the class from being instantiated, except by itself. The first time I saw this pattern in my programming career, I was confused.

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Community Partners