Might it be a good idea, in these factory functions, to check whether
the object returned is an instance of the intended class? Like, if
someone replaces all Title objects with MyTitles that *don't* extend
Title, that would cause some havoc, not least as we start adding type
hinting. It's probably best to catch that particular mistake early.
So instead of "if ($objResult === NULL)", something like:
if (!is_object($objResult) || !is_a($objResult, self::getRealClass()))
// must use is_a because instanceof doesn't work with strings