What is the advantage of a static factory class as opposed to using an instance of the same object to return this object?
For example, from the N2 CMS take a look at this code:
News News = Factory.Persister.Get (itemID);
// A news variable can set news-related properties.
Factory.Persister.Save (news);
Factory is static, and I know that there are / are factory objects, but I don't see the benefits of a static factory (which probably takes responsibility for setting up different types), as opposed to using a Newspage object for this.
thank
source
share