Service Locator pattern implementation written in PHP