[WIP] Added repositories and moved idPrefix and ID to base class

\cc @rmsint

This is more of an illustrative PR.

Not sure how much of this wasn't done by design, I've added the "Repositories" etc and moved the ID and idPrefix to the base objects

Some questions:

 - (general) I guess the logic was that ID generation should be delegated to the user? Why?
 - Is there an alternative to the "repository" method of ID generation, can we not get the ModelManager to *assign* an ID instead?

If the ModelManager could *assign* the ID, then we could remove the *getIdPrefix* method right? And also the easy-extends bundle would work out-of-the-box.