I want to create an instance of a class and call a method on that instance, in a single line of code.
PHP won\'t allow calling a method on a regular constructor:
The naming of any method should be with intention revealing names. I can't tell what 'Foo::factory' does. Try to build to a higher level language:
User::with100StartingPoints();
This would be the same as:
$user = new User();
$user->setPointsTo(100);
You could also easily test whether User::with100StartingPoints() is equal to this.